Files
image_processing/lib/image_processing.rb
T
Janko Marohnić 01f856a29e Make the pipeline object accessible to processors
In certain cases processors need to know the source/destination format,
e.g. when they need to perform different operations for different
formats. So we refactor the pipeline class and initialize processors
with it.

With this we also create a separate Builder class, whose sole purpose is
to build options and call the pipeline with those options. This is an
improvement, because previously the Pipeline class was also acting like
a builder by including Chainable. This was making the Pipeline class
difficult to change, as Chainable#method_missing was swallowing any
typos. It was also making it impossible to refactor, because we would
risk the new methods clashing with VIPS/ImageMagick operation names.
2018-03-28 13:13:56 +02:00

13 lines
341 B
Ruby

require "image_processing/chainable"
require "image_processing/builder"
require "image_processing/pipeline"
require "image_processing/processor"
require "image_processing/version"
module ImageProcessing
Error = Class.new(StandardError)
autoload :MiniMagick, 'image_processing/mini_magick'
autoload :Vips, 'image_processing/vips'
end