1. 21 Feb, 2019 2 commits
  2. 19 Feb, 2019 9 commits
  3. 18 Feb, 2019 1 commit
    • Josh Holmer's avatar
      Fixes for speed-test option (#1013) · 9e4ea86a
      Josh Holmer authored
      Defaults block size to 16x16
      Allows specifying multiple settings at once (space separated)
      Uses low_latency setting specified on CLI during speed-test
  4. 17 Feb, 2019 1 commit
  5. 16 Feb, 2019 4 commits
  6. 15 Feb, 2019 7 commits
  7. 14 Feb, 2019 6 commits
    • Thomas Daede's avatar
    • Vladimir Kazakov's avatar
    • Romain Vimont's avatar
      Adapt Pixel trait for convert_slice_2d() · a99da119
      Romain Vimont authored
      Since Pixel is only implemented for u8 and u16 types, it is always
      possible to cast a Pixel to an integral primitive type. However, the
      compiler could not know this, because in theory any other type could
      also implement the Pixel trait.
      To enforce this restriction, make the (main) integral primitive types
      implement CastForPrimitive<T> for any T which implements Pixel. That
      way, the compiler knows that a Pixel (whatever its concrete type) can
      always be cast to an integer.
      Then, rewrite the constraints on convert_slice_2d() to use
      CastFromPrimitive, so that callers need not to add redundant constraints
      if T implements Pixel.
    • Romain Vimont's avatar
      Improve generic usage of Pixel trait · 93c3d989
      Romain Vimont authored
      In order to use either u8 or u16 for plane components, a Pixel trait
      regroups several "capabilities" that a generic pixel type must support,
      through trait inheritance.
      That way, a generic function can just use the Pixel type, without
      listing them all:
          fn f<T: Pixel>(...) { ... }
      However, trait inheritance cannot express constraints about T for other
      types (like "i32: AsPrimitive<T>"). As a consequence, callers had to
      specify these additional constraints manually:
              T: Pixel,
              i32: AsPrimitive<T>,
              u32: AsPrimitive<T>,
      This is redundant, because if T is a Pixel, then i32 and u32 necessarily
      implement AsPrimitive<T> (since Pixel is only implemented for u8 and
      To express these relationships, create a new trait,
      CastFromPrimitive<T>, representing the inverse of AsPrimitive<T>.
      This paves the way to make Plane (and many other structures) generic
      over the pixel type conveniently.
    • Vittorio Giovara's avatar
    • Vittorio Giovara's avatar
  8. 13 Feb, 2019 8 commits
  9. 12 Feb, 2019 2 commits