Commits on Jun 19, 2016
  1. Update CHANGELOG.

    committed Jun 19, 2016
  2. Bump to version 1.3.6

    committed Jun 19, 2016
  3. Merge pull request #111 from wvanbergen/fix_reading_streams_with_trai…

    …ling_bytes
    
    Fix reading streams with trailing data
    committed on GitHub Jun 19, 2016
  4. Stop reading from a stream after the IEND chunk has been seen, instea…

    …d of until EOF. This prevents a stream with trailing data to raise an exception failed error.
    committed Jun 19, 2016
Commits on Apr 13, 2016
  1. Merge pull request #109 from jeremyevans/master

    Work with ruby 2.3's --enable-frozen-string-literal
    committed Apr 13, 2016
Commits on Apr 12, 2016
  1. @jeremyevans

    Work with ruby 2.3's --enable-frozen-string-literal

    These changes are the minimal ones necessary to allow Rodauth's specs
    to pass. There may well be other changes that are required.
    jeremyevans committed Apr 12, 2016
Commits on Dec 16, 2015
Commits on Oct 29, 2015
  1. @lencioni

    Clean up readme a bit

    Linkifying some URLs and some other small punctuation, formatting, and
    grammar tweaks.
    lencioni committed Oct 29, 2015
  2. @lencioni

    Fix filesize benchmark

    This benchmark was broken since f050b85 which removed the
    clock_stubbed.png file. I decided to fix this by changing the reference
    to a file that currently exists.
    lencioni committed Oct 29, 2015
  3. @lencioni

    Fix heading in readme

    When I converted this document from rdoc to markdown, I missed this
    heading.
    lencioni committed Oct 29, 2015
  4. @lencioni

    Merge pull request #104 from lencioni/markdown

    Convert readme from rdoc to markdown
    lencioni committed Oct 29, 2015
Commits on Oct 28, 2015
  1. @lencioni

    Update year in LICENSE

    It is almost 2016.
    lencioni committed Oct 28, 2015
  2. @lencioni

    Convert readme from rdoc to markdown

    This allows us to have syntax highlighting when viewing this document on
    GitHub. I believe that this will also work for the rdoc.info site.
    lencioni committed Oct 28, 2015
  3. Bump version to 1.3.5

    committed Oct 28, 2015
  4. @lencioni

    Use SVG for build status badge in README

    Since SVG is vector format, it will look much better, especially on
    higher density displays.
    lencioni committed Oct 28, 2015
  5. Merge pull request #103 from lencioni/zlib

    Microoptimize ImageData.combine_chunks
    committed Oct 28, 2015
  6. @lencioni

    Microoptimize ImageData.combine_chunks

    When doing some memory profiling, I noticed that this line was
    allocating by far the most memory in my application. Looking for a way
    to bring this down a little, I discovered that we can avoid building and
    joining our own array here by just pushing onto the stream directly.
    
    Using memory_profiler in my application, this appears to bring memory
    allocation down from 1,158,307,467 bytes (499,055 objects) to
    1,154,056,455 bytes (498,849 objects), which is a difference of
    4,251,012 bytes (roughly 4 MiB). While not the juicy win I'd really like
    to see here, it seems like a simple enough change for the payoff.
    
    I did see slightly worse memory usage for the smallest of images due to
    the overhead of allocating the memory for instantiating the
    Zlib::Inflate class, but I think this is a worthwhile tradeoff.
    lencioni committed Oct 28, 2015
  7. Merge pull request #102 from lencioni/croptimization

    Optimize crop! when only cropping top/bottom
    committed Oct 28, 2015
  8. @lencioni

    Optimize crop! when only cropping top/bottom

    I am working on a project where cropping performance is critical. There
    are some situations where we only need to crop to the tops and/or
    bottoms of images and I noticed an opportunity to take a shortcut to get
    some perf gains.
    
    I generated the cropped_height.png reference image by running
    operations.png through imagemagick with the following command:
    
      convert operations.png -crop 16x8+0+5 cropped_height.png
    
    I tested the performance improvement in a little benchmark:
    
    ```
    require 'benchmark'
    
    pixels = []
    width = 2000
    height = 2000
    (width * height).times { pixels << rand }
    
    crop_opts = [0, 100, 2000, 1000]
    x, y, crop_width, crop_height = crop_opts
    
    n = 10
    Benchmark.bmbm do |b|
      b.report('baseline:') do
        n.times do
          new_pixels = []
          for cy in 0...crop_height do
            new_pixels.concat pixels.slice((cy + y) * width + x, crop_width)
          end
        end
      end
    
      b.report('optimized:') do
        n.times do
          pixels.slice(y * width, width * crop_height)
        end
      end
    end
    ```
    
    The results of this show very good improvement:
    
    Rehearsal ---------------------------------------------
    baseline:   0.080000   0.070000   0.150000 (  0.144634)
    optimized:  0.000000   0.000000   0.000000 (  0.000006)
    ------------------------------------ total: 0.150000sec
    
                    user     system      total        real
    baseline:   0.050000   0.070000   0.120000 (  0.126334)
    optimized:  0.000000   0.000000   0.000000 (  0.000008)
    lencioni committed Oct 28, 2015
  9. @lencioni

    Organize #crop! spec examples

    I am about to modify the behavior of crop! so that it takes an optimized
    path when it doesn't need to crop the width of the image. Before I do
    this, I want to organize these specs a little better to make the diff of
    the addition of my new specs easier to see.
    lencioni committed Oct 28, 2015
  10. Merge pull request #101 from lencioni/rspec-warning

    Expect ChunkyPNG::CRCMismatch in datastream spec
    committed Oct 28, 2015
  11. @lencioni

    Expect ChunkyPNG::CRCMismatch in datastream spec

    When running RSpec, I noticed the following warning:
    
    > WARNING: Using the `raise_error` matcher without providing a specific
    > error or message risks false positives, since `raise_error` will match
    > when Ruby raises a `NoMethodError`, `NameError` or `ArgumentError`,
    > potentially allowing the expectation to pass without even executing
    > the method you are intending to call. Instead consider providing a
    > specific error class or message. This message can be supressed by
    > setting:
    > `RSpec::Expectations.configuration.warn_about_potential_false_positives
    > = false`. Called from
    > /path/to/chunky_png/spec/chunky_png/datastream_spec.rb:13:in `block
    > (3 levels) in <top (required)>'.
    
    I noticed that it was raising a `ChunkyPNG::CRCMismatch` error, so I
    decided it would be best to just include that detail in the matcher.
    lencioni committed Oct 28, 2015
Commits on Aug 31, 2015
  1. Merge pull request #100 from DarkElement2/patch-1

    Update rmagick.rb
    committed Aug 31, 2015
  2. @Dark-Element

    Update rmagick.rb

    Fixed Warning:[rake --prereqs] /usr/local/rvm/gems/ruby-2.2.3/gems/activesupport-4.1.1/lib/active_support/values/time_zone.rb:285: warning: circular argument reference - now [DEPRECATION] requiring "RMagick" is deprecated. Use "rmagick" instead
    Dark-Element committed Aug 31, 2015
Commits on Aug 12, 2015
  1. Merge pull request #97 from wvanbergen/improve_error_message_for_shor…

    …t_streams
    
    Add spec for streams that are too short
    committed Aug 12, 2015
Commits on Jul 25, 2015
  1. Merge pull request #95 from tweksteen/master

    Fix encoding of to_blob
    committed Jul 25, 2015
Commits on Jul 20, 2015
  1. @tweksteen

    Fix encoding of to_blob

    tweksteen committed Jul 20, 2015
Commits on May 28, 2015
  1. Merge pull request #91 from wvanbergen/update_travis_matrix

    Update Travis CI matrix
    committed May 28, 2015
  2. Update Travis CI matrix

    committed May 28, 2015
Commits on Apr 26, 2015
  1. Merge pull request #88 from jhamon/fix-360-hue-bug

    Fix Color#from_hsl, Color#from_hsv error when hue is 360
    committed Apr 26, 2015
Commits on Apr 15, 2015
  1. @jhamon

    Fix Color#from_hsl, Color#from_hsv error when hue is 360

    Changing the private method `Color#cylindrical_to_cubic` to use an inclusive
    rather than exclusive range fixes the NilClass error reported in Issue #85
    without changing the public API.
    jhamon committed Apr 14, 2015
Commits on Feb 16, 2015