1. 13 7月, 2021 1 次提交
  2. 12 7月, 2021 11 次提交
  3. 10 7月, 2021 4 次提交
  4. 09 7月, 2021 3 次提交
  5. 08 7月, 2021 8 次提交
  6. 07 7月, 2021 13 次提交
    • F
      stb_truetype: Add protoype for stbtt_FindSVGDoc · 315e979f
      Fabian Giesen 提交于
      Fixes issue #979.
    • F
      stb_c_lexer: Move token enum defn to header portion · 8af4d409
      Fabian Giesen 提交于
      Required some tinkering, hope I didn't mess the logic up.
      This now requires the config section to be set for the header
      file, and different sites that include it should agree on what
      the values are. This is kind of iffy but hard to avoid.
      Fixes issue #647.
    • F
      stb_truetype: Change spelling of fallthrough comment · afc9c16b
      Fabian Giesen 提交于
      To pacify GCC warnings at -Wimplicit-fallthrough=4. Why the
      all-caps version works and the others don't, I'm not sure; the
      GCC manual page lists regular expressions that GCC is checking for
      but does not say which regular expression syntax variant it's using,
      whether it's looking for a substring match or a full match for
      the comment, and what exactly the text being matched against is
      for a single-line comment. Sigh.
      Fixes issue #507.
    • F
      stb_sprintf: PUBLICDEC on declarations, as intended · 46c259ff
      Fabian Giesen 提交于
      The code was using PUBLICDEF on both declarations and
      Fixes issue #458.
    • F
      stb_truetype: GPOS handling formatting changes · 9fe3b4bb
      Fabian Giesen 提交于
      Was using 4-character spaces and otherwise formatted unlike the
      rest of the code, fix this. Also get rid of the outer switch in
      GetGlyphGPOSInfoAdvance with just one case; just use an if.
      No behavioral changes.
    • F
      stb_truetype: GPOS parsing fixes · 1252a3e6
      Fabian Giesen 提交于
      Glyphs not assigned a glyph class should default to class 0 as
      per the OpenType spec. Also, change the code to treat malformed
      data as an error to be handled, not an assert, and change the
      way the version checking works.
      Fixes the issue mentioned in PR #1035. Also, this part of the
      code is indented incorrectly; will fix that in a subsequent
    • F
      stb_truetype: GCC warning fix · e5905054
      Fabian Giesen 提交于
      GCC warns about a potentially uninitialized variable here. It's
      not (or at least I don't see how), but fix it anyway.
    • A
      Store uncompressed if compression was worse · db6e91b7
      Andrew Kensler 提交于
      If the data was uncompressible and this deflate implementation expanded
      by more than the overhead of simply storing it uncompressed, fall back
      to deflate's uncompressed storage mode.  This bounds the maximum deflated
      size at the original size plus an overhead of 6 fixed bytes with another
      5 bytes per 32767 byte block.
      Fixes issue #948.
    • F
      stb_image_resize: Remove ill-advised asserts. · 14c224c8
      Fabian Giesen 提交于
      These mostly add very little and have caused problems for people,
      nor does it make sense to require this when the underlying
      computations are performed in floating-point arithmetic depending
      on ratios of user-passed in image dimensions.
      Arbitrary absolute epsilons here would just be garbage; we could
      try and compute desired relative error bounds based on the
      determined scale values, but this still leaves the questions of
      what purpose this would even serve, which is unclear.
      Leave the filter kernel asserts as comment for documentation
      of what the behavior would be with exact math, but don't actually
      bother asserting here.
      Fixes issue #736.
    • F
      stb_divide: Update changelog · e7f9f92c
      Fabian Giesen 提交于
    • F
    • F
      stb_divide: Fix integer overflow issues · c38ec91d
      Fabian Giesen 提交于
      We've established the signs of values before so we can carefully
      jiggle the expressions to be guaranteed overflow-free; the tests
      for <0 here were meant to check if the value was "still negative",
      i.e. if the sum did not underflow below INT_MIN, and we can
      rewrite that using algebra to be overflow-free.
      We need an extra case in the Euclidean dvision for
      INT_MIN / INT_MIN which is a bit annoying but trivial; finally,
      for two's complement platforms, note that abs(x) = (x > 0) ? x : -x
      does not work (since for x=INT_MIN, -x still gives INT_MIN),
      but the equivalent formulation for _negative_ absolute value
      (x < 0) ? x : -x is always in range and overflow-free, so
      rewrite the relevant expressions using that negative absolute
      value instead.
      Fixes issue #741.
    • S