class Tracksperanto::Export::Boujou

Export for 2d3d boujou

Constants

DATETIME_FORMAT
POINT_T
PREAMBLE

Public Class Methods

desc_and_extension() click to toggle source
# File lib/export/boujou.rb, line 4
def self.desc_and_extension
  "boujou_text.txt"
end
human_name() click to toggle source
# File lib/export/boujou.rb, line 8
def self.human_name
  "boujou feature tracks"
end

Public Instance Methods

export_point(frame, abs_float_x, abs_float_y, float_residual) click to toggle source
# File lib/export/boujou.rb, line 29
def export_point(frame, abs_float_x, abs_float_y, float_residual)
  height_inv = @height - abs_float_y
  # Frames in Boujou are likely to start from 0
  @io.puts(POINT_T % [@tracker_name, frame, abs_float_x, height_inv + 1])
end
start_export( img_width, img_height) click to toggle source
# File lib/export/boujou.rb, line 20
def start_export( img_width, img_height)
  @height = img_height
  @io.puts(PREAMBLE % Time.now.strftime(DATETIME_FORMAT))
end
start_tracker_segment(tracker_name) click to toggle source
# File lib/export/boujou.rb, line 25
def start_tracker_segment(tracker_name)
  @tracker_name = tracker_name
end