lib/middleware/base.rb in tracksperanto-1.1.1 vs lib/middleware/base.rb in tracksperanto-1.2.0
- old
+ new
@@ -1,9 +1,14 @@
+# The base middleware class works just like a Tracksperanto::Export::Base, but it only wraps another exporting object and does not get registered on it's own
+# as an export format. Middleware can be used to massage the tracks being exported in various interesting ways - like moving the coordinates, clipping the keyframes,
+# scaling the whole export or even reversing the trackers to go backwards
class Tracksperanto::Middleware::Base
include Tracksperanto::Casts
+ include Tracksperanto::BlockInit
- def initialize(exporter)
+ def initialize(exporter, *args_for_block_init)
@exporter = exporter
+ super(*args_for_block_init)
end
# Called on export start
def start_export( img_width, img_height)
@exporter.start_export(img_width, img_height)
\ No newline at end of file