Sha256: cb0499f2e48e4caf2170ce6de38aa3d5133557ff29b572233f8d5c2d296097ab

Contents?: true

Size: 368 Bytes

Versions: 2

Compression:

Stored size: 368 Bytes

Contents

# Flips the comp being exported horizontally
class Tracksperanto::Middleware::Flip < Tracksperanto::Middleware::Base
  
  attr_accessor :enabled
  
  def start_export(w, h)
    @w, @h = w, h
    super
  end
  
  def export_point(frame, float_x, float_y, float_residual)
    x = @enabled ? (@w - float_x) : float_x
    super(frame, x, float_y, float_residual)
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
tracksperanto-2.0.1 lib/middleware/flip.rb
tracksperanto-2.0.0 lib/middleware/flip.rb