tracksperanto 2.4.1 → 2.5.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.yardopts +6 -0
- data/History.txt +8 -0
- data/Manifest.txt +1 -4
- data/Rakefile +7 -6
- data/bin/tracksperanto +27 -21
- data/lib/export/pfmatchit.rb +7 -3
- data/lib/export/pftrack_5.rb +5 -0
- data/lib/import/shake_grammar/lexer.rb +1 -1
- data/lib/pipeline/base.rb +5 -1
- data/lib/tracksperanto.rb +1 -1
- data/test/export/samples/ref_PFMatchit.2dt +39 -39
- data/test/export/test_pfmatchit_export.rb +2 -2
- data/test/import/test_shake_lexer.rb +5 -0
- data/test/test_cli.rb +2 -2
- data/test/test_pipeline.rb +2 -1
- metadata +19 -36
- data/lib/export/pftrack_2011.rb +0 -30
- data/lib/tracksperanto/pbar.rb +0 -13
- data/test/export/samples/ref_PFTrack2011.txt +0 -54
- data/test/export/test_pftrack2011_export.rb +0 -19
data/.yardopts
ADDED
data/History.txt
CHANGED
@@ -1,3 +1,11 @@
|
|
1
|
+
=== 2.5.0 / 2011-14-06
|
2
|
+
|
3
|
+
* No status display in the progress bar. It was an annoyance.
|
4
|
+
* There are still crashes with flexmocks in tests, relevant flexmock issues filed upstream
|
5
|
+
* Fix Ruby 1.9 compatibility (but the situation will get better since it's now the primary version)
|
6
|
+
* Use update_hints gem for version checks
|
7
|
+
* PFTrack 2011 and PFMAtchit actually use the same format, so we don't need to have 2 modules for them
|
8
|
+
|
1
9
|
=== 2.4.0 / 2011-19-05
|
2
10
|
|
3
11
|
* Added an official PFTrack 2011 exporter that is verified
|
data/Manifest.txt
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
.yardopts
|
1
2
|
DEVELOPER_DOCS.rdoc
|
2
3
|
History.txt
|
3
4
|
MIT_LICENSE.txt
|
@@ -16,7 +17,6 @@ lib/export/mux.rb
|
|
16
17
|
lib/export/nuke_script.rb
|
17
18
|
lib/export/pfmatchit.rb
|
18
19
|
lib/export/pftrack.rb
|
19
|
-
lib/export/pftrack_2011.rb
|
20
20
|
lib/export/pftrack_5.rb
|
21
21
|
lib/export/shake_text.rb
|
22
22
|
lib/export/syntheyes.rb
|
@@ -58,7 +58,6 @@ lib/tracksperanto/ext_io.rb
|
|
58
58
|
lib/tracksperanto/flame_builder.rb
|
59
59
|
lib/tracksperanto/format_detector.rb
|
60
60
|
lib/tracksperanto/keyframe.rb
|
61
|
-
lib/tracksperanto/pbar.rb
|
62
61
|
lib/tracksperanto/progressive_io.rb
|
63
62
|
lib/tracksperanto/returning.rb
|
64
63
|
lib/tracksperanto/safety.rb
|
@@ -72,7 +71,6 @@ test/export/samples/ref_Mayalive_CustomAspect.txt
|
|
72
71
|
test/export/samples/ref_NukeScript.nk
|
73
72
|
test/export/samples/ref_PFMatchit.2dt
|
74
73
|
test/export/samples/ref_PFTrack.2dt
|
75
|
-
test/export/samples/ref_PFTrack2011.txt
|
76
74
|
test/export/samples/ref_PFTrack5.2dt
|
77
75
|
test/export/samples/ref_ShakeText.txt
|
78
76
|
test/export/samples/ref_Syntheyes.txt
|
@@ -90,7 +88,6 @@ test/export/test_maya_live_export.rb
|
|
90
88
|
test/export/test_mux.rb
|
91
89
|
test/export/test_nuke_export.rb
|
92
90
|
test/export/test_pfmatchit_export.rb
|
93
|
-
test/export/test_pftrack2011_export.rb
|
94
91
|
test/export/test_pftrack5_export.rb
|
95
92
|
test/export/test_pftrack_export.rb
|
96
93
|
test/export/test_shake_export.rb
|
data/Rakefile
CHANGED
@@ -3,24 +3,21 @@ require './lib/tracksperanto'
|
|
3
3
|
|
4
4
|
begin
|
5
5
|
require 'hoe'
|
6
|
-
# Disable spurious warnings when running tests, ActiveMagic cannot stand -w
|
7
|
-
Hoe::RUBY_FLAGS.replace ENV['RUBY_FLAGS'] || "-I#{%w(lib test).join(File::PATH_SEPARATOR)}" +
|
8
|
-
(Hoe::RUBY_DEBUG ? " #{RUBY_DEBUG}" : '')
|
9
6
|
|
10
7
|
Hoe.spec('tracksperanto') do | p |
|
11
8
|
p.readme_file = 'README.rdoc'
|
12
9
|
p.extra_rdoc_files = FileList['*.rdoc'] + FileList['*.txt']
|
13
10
|
p.version = Tracksperanto::VERSION
|
14
11
|
|
15
|
-
p.extra_deps = {"progressbar" => ">=0"}
|
12
|
+
p.extra_deps = {"progressbar" => ">=0", "update_hints" => ">=0" }
|
16
13
|
p.extra_dev_deps = {"flexmock" => ">=0"}
|
17
14
|
p.rubyforge_name = 'guerilla-di'
|
18
15
|
p.developer('Julik Tarkhanov', 'me@julik.nl')
|
19
16
|
p.clean_globs = %w( **/.DS_Store coverage.info **/*.rbc .idea .yardoc)
|
20
17
|
end
|
21
18
|
rescue LoadError
|
19
|
+
|
22
20
|
$stderr.puts "Meta-operations on this package require Hoe"
|
23
|
-
task :default => [ :test ]
|
24
21
|
|
25
22
|
require 'rake/testtask'
|
26
23
|
desc "Run all tests"
|
@@ -29,4 +26,8 @@ rescue LoadError
|
|
29
26
|
t.pattern = 'test/**/test_*.rb'
|
30
27
|
t.verbose = true
|
31
28
|
end
|
32
|
-
|
29
|
+
|
30
|
+
task :default => [ :test ]
|
31
|
+
end
|
32
|
+
|
33
|
+
|
data/bin/tracksperanto
CHANGED
@@ -14,22 +14,7 @@ require File.dirname(__FILE__) + '/../lib/tracksperanto' unless defined?(Tracksp
|
|
14
14
|
require 'optparse'
|
15
15
|
require 'rubygems'
|
16
16
|
require 'progressbar'
|
17
|
-
require "
|
18
|
-
require "open-uri"
|
19
|
-
require "timeout"
|
20
|
-
require File.dirname(__FILE__) + '/../lib/tracksperanto/pbar'
|
21
|
-
|
22
|
-
def version_check(version_present)
|
23
|
-
begin
|
24
|
-
version_info = open("http://rubygems.org/api/v1/gems/tracksperanto.xml").string.scan(/<version>(.+)<\/version>/).to_s
|
25
|
-
int_available, int_present = [version_info, version_present].map{|v| v.scan(/(\d+)/).to_s.to_i }
|
26
|
-
if int_available > int_present
|
27
|
-
puts "Your version of Tracksperanto is probably out of date (the current version is #{version_info}, but you have #{Tracksperanto::VERSION})."
|
28
|
-
puts "Please consider updating (run 'gem update tracksperanto')"
|
29
|
-
end
|
30
|
-
rescue Exception
|
31
|
-
end
|
32
|
-
end
|
17
|
+
require "update_hints"
|
33
18
|
|
34
19
|
def disclaimer
|
35
20
|
"Please consider a small donation to keep Tracksperanto going. http://guerilla-di.org/source-and-license/\n"+
|
@@ -51,6 +36,20 @@ def mw(name, option, default_value = nil)
|
|
51
36
|
end
|
52
37
|
end
|
53
38
|
|
39
|
+
def list_exporters
|
40
|
+
puts "The following export modules are available:"
|
41
|
+
Tracksperanto.exporters.each do | exporter |
|
42
|
+
puts "\t#{exporter.const_name.downcase} - #{exporter.human_name}"
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
def list_importers
|
47
|
+
puts "The following import modules are available:"
|
48
|
+
Tracksperanto.importers.each do | importer |
|
49
|
+
puts "\t#{importer.const_name.downcase} - #{importer.human_name}"
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
54
53
|
class CodeLoaded < RuntimeError; end
|
55
54
|
|
56
55
|
op.banner = "Usage: tracksperanto -f ShakeScript -w 1920 -h 1080 /Films/Blockbuster/Shots/001/script.shk"
|
@@ -60,6 +59,7 @@ op.on("--code PATH_TO_SCRIPT", String, "Load custom Ruby code into tracksperanto
|
|
60
59
|
raise CodeLoaded
|
61
60
|
end
|
62
61
|
end
|
62
|
+
|
63
63
|
op.on(" -f", "--from TRANSLATOR", String, "Use the specific import translator") { |f| options[:importer] = f }
|
64
64
|
op.on(" -w", "--width WIDTH_IN_PIXELS", Integer, "Absolute input comp width in pixels (will try to autodetect)") { |w| options[:width] = w }
|
65
65
|
op.on(" -h", "--height HEIGHT_IN_PIXELS", Integer, "Absolute input comp height in pixels (will try to autodetect)") {|w| options[:height] = w }
|
@@ -78,12 +78,17 @@ op.on(" -p", "--prefix PREFIX", String, "A prefix to prepend to tracker names in
|
|
78
78
|
op.on("--lerp", "Linearly interpolate missing keyframes", &mw("Lerp", :enabled, true))
|
79
79
|
op.on("--flip", "Flip the comp horizontally", &mw("Flip", :enabled, true))
|
80
80
|
op.on("--flop", "Flop the comp vertically", &mw("Flop", :enabled, true))
|
81
|
-
|
81
|
+
op.on("--list-exporters", "Show available export modules") do
|
82
|
+
list_exporters; exit(0)
|
83
|
+
end
|
84
|
+
op.on("--list-importers", "Show available import modules") do
|
85
|
+
list_importers; exit(0)
|
86
|
+
end
|
82
87
|
op.on("--version", "Show the version and exit") do |v|
|
83
88
|
puts "Tracksperanto v.#{Tracksperanto::VERSION} running on Ruby #{RUBY_VERSION} on #{RUBY_PLATFORM}"
|
84
89
|
puts "Copyright 2008-#{Time.now.year} by Guerilla-DI (Julik Tarkhanov and contributors)"
|
85
90
|
puts disclaimer
|
86
|
-
version_check()
|
91
|
+
UpdateHints.version_check("tracksperanto", Tracksperanto::VERSION, STDOUT)
|
87
92
|
exit(0)
|
88
93
|
end
|
89
94
|
|
@@ -105,11 +110,12 @@ unless File.exist?(input_file)
|
|
105
110
|
exit(-1)
|
106
111
|
end
|
107
112
|
|
108
|
-
pbar =
|
109
|
-
|
113
|
+
pbar = ProgressBar.new("Converting", 100, $stderr)
|
114
|
+
progress = lambda{|percent,message| pbar.set(percent) }
|
115
|
+
pipe = Tracksperanto::Pipeline::Base.new(:progress_block => progress, :middleware_tuples => $middlewares)
|
110
116
|
pipe.exporters = [Tracksperanto.get_exporter(writer_class_name)] if writer_class_name
|
111
117
|
pipe.run(input_file, options)
|
112
118
|
pbar.finish
|
113
119
|
|
114
120
|
puts disclaimer
|
115
|
-
version_check(Tracksperanto::VERSION)
|
121
|
+
UpdateHints.version_check("tracksperanto", Tracksperanto::VERSION, STDOUT)
|
data/lib/export/pfmatchit.rb
CHANGED
@@ -4,11 +4,11 @@ class Tracksperanto::Export::PFMatchit < Tracksperanto::Export::Base
|
|
4
4
|
KEYFRAME_TEMPLATE = "%s %.3f %.3f %.3f"
|
5
5
|
|
6
6
|
def self.desc_and_extension
|
7
|
-
"
|
7
|
+
"pftrack_2011_pfmatchit.txt"
|
8
8
|
end
|
9
9
|
|
10
10
|
def self.human_name
|
11
|
-
"PFMatchit
|
11
|
+
"PFTrack2011/PFMatchit .txt file (single camera)"
|
12
12
|
end
|
13
13
|
|
14
14
|
def start_tracker_segment(tracker_name)
|
@@ -35,13 +35,17 @@ class Tracksperanto::Export::PFMatchit < Tracksperanto::Export::Base
|
|
35
35
|
|
36
36
|
def export_point(frame, abs_float_x, abs_float_y, float_residual)
|
37
37
|
@frame_count += 1
|
38
|
-
line = KEYFRAME_TEMPLATE % [frame, abs_float_x, abs_float_y, float_residual / 8]
|
38
|
+
line = KEYFRAME_TEMPLATE % [frame_number(frame), abs_float_x, abs_float_y, float_residual / 8]
|
39
39
|
@tracker_io.write(line)
|
40
40
|
@tracker_io.write(linebreak)
|
41
41
|
end
|
42
42
|
|
43
43
|
private
|
44
44
|
|
45
|
+
def frame_number(tracksperanto_frame)
|
46
|
+
tracksperanto_frame + 1
|
47
|
+
end
|
48
|
+
|
45
49
|
def linebreak
|
46
50
|
"\n"
|
47
51
|
end
|
data/lib/export/pftrack_5.rb
CHANGED
@@ -15,6 +15,11 @@ class Tracksperanto::Export::PFTrack5 < Tracksperanto::Export::PFMatchit
|
|
15
15
|
"Primary".inspect
|
16
16
|
end
|
17
17
|
|
18
|
+
# PFT5 frames are zero-based
|
19
|
+
def frame_number(tracksperanto_frame)
|
20
|
+
tracksperanto_frame
|
21
|
+
end
|
22
|
+
|
18
23
|
# PFT5 wants CRLF
|
19
24
|
def linebreak
|
20
25
|
"\r\n"
|
@@ -140,7 +140,7 @@ module Tracksperanto::ShakeGrammar
|
|
140
140
|
# Since we can have two-word pointers as typedefs (char *) we only use the last
|
141
141
|
# part of the thing as varname. Nodes return the :image type implicitly.
|
142
142
|
varname_re = /\w+$/
|
143
|
-
varname = var_specifier.scan(varname_re).
|
143
|
+
varname = var_specifier.scan(varname_re).flatten.join
|
144
144
|
typedef = var_specifier.gsub(varname_re, '').strip
|
145
145
|
typedef = :image if typedef.empty?
|
146
146
|
|
data/lib/pipeline/base.rb
CHANGED
@@ -13,7 +13,11 @@ module Tracksperanto::Pipeline
|
|
13
13
|
end
|
14
14
|
|
15
15
|
class NoTrackersRecoveredError < RuntimeError
|
16
|
-
def message;
|
16
|
+
def message;
|
17
|
+
"Could not recover any non-empty trackers from this file.\n" +
|
18
|
+
"Wrong import format maybe?\n" +
|
19
|
+
"Note that PFTrack will only export trackers from the solved segment of the shot.";
|
20
|
+
end
|
17
21
|
end
|
18
22
|
|
19
23
|
# The base pipeline is the whole process of track conversion from start to finish. The pipeline object organizes the import formats, scans them,
|
data/lib/tracksperanto.rb
CHANGED
@@ -3,52 +3,52 @@
|
|
3
3
|
"Parabolic_1_from_top_left"
|
4
4
|
1
|
5
5
|
19
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
6
|
+
1 0.000 1080.000 0.000
|
7
|
+
2 96.000 874.800 0.006
|
8
|
+
3 192.000 691.200 0.012
|
9
|
+
4 288.000 529.200 0.018
|
10
|
+
5 384.000 388.800 0.024
|
11
|
+
6 480.000 270.000 0.030
|
12
|
+
7 576.000 172.800 0.036
|
13
|
+
8 672.000 97.200 0.042
|
14
|
+
9 768.000 43.200 0.048
|
15
|
+
10 864.000 10.800 0.054
|
16
|
+
13 1152.000 43.200 0.071
|
17
|
+
14 1248.000 97.200 0.077
|
18
|
+
15 1344.000 172.800 0.083
|
19
|
+
16 1440.000 270.000 0.089
|
20
|
+
17 1536.000 388.800 0.095
|
21
|
+
18 1632.000 529.200 0.101
|
22
|
+
19 1728.000 691.200 0.107
|
23
|
+
20 1824.000 874.800 0.113
|
24
|
+
21 1920.000 1080.000 0.119
|
25
25
|
|
26
26
|
|
27
27
|
"Parabolic_2_from_bottom_right"
|
28
28
|
1
|
29
29
|
19
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
30
|
+
1 1920.000 0.000 0.000
|
31
|
+
2 1824.000 205.200 0.006
|
32
|
+
3 1728.000 388.800 0.012
|
33
|
+
4 1632.000 550.800 0.018
|
34
|
+
5 1536.000 691.200 0.024
|
35
|
+
6 1440.000 810.000 0.030
|
36
|
+
7 1344.000 907.200 0.036
|
37
|
+
8 1248.000 982.800 0.042
|
38
|
+
9 1152.000 1036.800 0.048
|
39
|
+
10 1056.000 1069.200 0.054
|
40
|
+
13 768.000 1036.800 0.071
|
41
|
+
14 672.000 982.800 0.077
|
42
|
+
15 576.000 907.200 0.083
|
43
|
+
16 480.000 810.000 0.089
|
44
|
+
17 384.000 691.200 0.095
|
45
|
+
18 288.000 550.800 0.101
|
46
|
+
19 192.000 388.800 0.107
|
47
|
+
20 96.000 205.200 0.113
|
48
|
+
21 0.000 0.000 0.119
|
49
49
|
|
50
50
|
|
51
51
|
"SingleFrame"
|
52
52
|
1
|
53
53
|
1
|
54
|
-
|
54
|
+
1 970.000 550.000 0.000
|
@@ -4,8 +4,8 @@ class PFMatchitExportTest < Test::Unit::TestCase
|
|
4
4
|
include ParabolicTracks
|
5
5
|
|
6
6
|
def test_desc_and_ext
|
7
|
-
assert_equal "PFMatchit
|
8
|
-
assert_equal "
|
7
|
+
assert_equal "PFTrack2011/PFMatchit .txt file (single camera)", Tracksperanto::Export::PFMatchit.human_name
|
8
|
+
assert_equal "pftrack_2011_pfmatchit.txt", Tracksperanto::Export::PFMatchit.desc_and_extension
|
9
9
|
end
|
10
10
|
|
11
11
|
P = File.dirname(__FILE__) + "/samples/ref_PFMatchit.2dt"
|
@@ -171,6 +171,11 @@ class ShakeLexerTest < Test::Unit::TestCase
|
|
171
171
|
assert_equal :funcall, tree[2][0]
|
172
172
|
end
|
173
173
|
|
174
|
+
def test_parse_simple_varassign
|
175
|
+
s = parse 'Foo = 1;'
|
176
|
+
assert_equal [[:assign, [:vardef, :image, "Foo"], 1]], s, "Note that the variable name should be escaped properly"
|
177
|
+
end
|
178
|
+
|
174
179
|
def test_parse_varassign
|
175
180
|
s = parse 'Foo = Blur(Foo, 1, 2, 3); 1'
|
176
181
|
assert_equal [[:assign, [:vardef, :image, "Foo"], [:funcall, "Blur", [:atom, "Foo"], 1, 2, 3]], 1], s
|
data/test/test_cli.rb
CHANGED
@@ -50,8 +50,8 @@ class CliTest < Test::Unit::TestCase
|
|
50
50
|
assert_equal 0, status, "Should exit with a normal status"
|
51
51
|
fs = %w(. ..
|
52
52
|
flm.stabilizer flm_3de_v3.txt flm_3de_v4.txt flm_boujou_text.txt flm_flame.stabilizer
|
53
|
-
flm_matchmover.rz2 flm_mayalive.txt flm_nuke.nk
|
54
|
-
flm_pftrack_v5.2dt
|
53
|
+
flm_matchmover.rz2 flm_mayalive.txt flm_nuke.nk flm_pftrack_2011_pfmatchit.txt flm_pftrack_v4.2dt
|
54
|
+
flm_pftrack_v5.2dt flm_shake_trackers.txt flm_syntheyes_2dt.txt
|
55
55
|
)
|
56
56
|
|
57
57
|
assert_same_set fs, Dir.entries(TEMP_DIR)
|
data/test/test_pipeline.rb
CHANGED
@@ -87,8 +87,9 @@ class PipelineTest < Test::Unit::TestCase
|
|
87
87
|
def test_run_with_overridden_importer_and_no_size
|
88
88
|
FileUtils.cp("./import/samples/shake_script/four_tracks_in_one_stabilizer.shk", "./input.shk")
|
89
89
|
pipeline = Tracksperanto::Pipeline::Base.new
|
90
|
+
num_exporters = Tracksperanto.exporters.length
|
90
91
|
assert_nothing_raised { pipeline.run("./input.shk", :importer => "Syntheyes", :width => 720, :height => 576) }
|
91
|
-
assert_equal
|
92
|
+
assert_equal num_exporters, Dir.glob("./input_*").length, "#{num_exporters} files should be present for the input and outputs"
|
92
93
|
end
|
93
94
|
|
94
95
|
def test_run_with_overridden_importer_and_size_for_file_that_would_be_recognized_differently
|
metadata
CHANGED
@@ -1,13 +1,8 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tracksperanto
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash: 29
|
5
4
|
prerelease:
|
6
|
-
|
7
|
-
- 2
|
8
|
-
- 4
|
9
|
-
- 1
|
10
|
-
version: 2.4.1
|
5
|
+
version: 2.5.0
|
11
6
|
platform: ruby
|
12
7
|
authors:
|
13
8
|
- Julik Tarkhanov
|
@@ -15,8 +10,7 @@ autorequire:
|
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
12
|
|
18
|
-
date: 2011-
|
19
|
-
default_executable:
|
13
|
+
date: 2011-06-14 00:00:00 Z
|
20
14
|
dependencies:
|
21
15
|
- !ruby/object:Gem::Dependency
|
22
16
|
name: progressbar
|
@@ -26,42 +20,42 @@ dependencies:
|
|
26
20
|
requirements:
|
27
21
|
- - ">="
|
28
22
|
- !ruby/object:Gem::Version
|
29
|
-
hash: 3
|
30
|
-
segments:
|
31
|
-
- 0
|
32
23
|
version: "0"
|
33
24
|
type: :runtime
|
34
25
|
version_requirements: *id001
|
35
26
|
- !ruby/object:Gem::Dependency
|
36
|
-
name:
|
27
|
+
name: update_hints
|
37
28
|
prerelease: false
|
38
29
|
requirement: &id002 !ruby/object:Gem::Requirement
|
39
30
|
none: false
|
40
31
|
requirements:
|
41
32
|
- - ">="
|
42
33
|
- !ruby/object:Gem::Version
|
43
|
-
hash: 3
|
44
|
-
segments:
|
45
|
-
- 0
|
46
34
|
version: "0"
|
47
|
-
type: :
|
35
|
+
type: :runtime
|
48
36
|
version_requirements: *id002
|
49
37
|
- !ruby/object:Gem::Dependency
|
50
|
-
name:
|
38
|
+
name: flexmock
|
51
39
|
prerelease: false
|
52
40
|
requirement: &id003 !ruby/object:Gem::Requirement
|
53
41
|
none: false
|
54
42
|
requirements:
|
55
43
|
- - ">="
|
56
44
|
- !ruby/object:Gem::Version
|
57
|
-
|
58
|
-
segments:
|
59
|
-
- 2
|
60
|
-
- 9
|
61
|
-
- 1
|
62
|
-
version: 2.9.1
|
45
|
+
version: "0"
|
63
46
|
type: :development
|
64
47
|
version_requirements: *id003
|
48
|
+
- !ruby/object:Gem::Dependency
|
49
|
+
name: hoe
|
50
|
+
prerelease: false
|
51
|
+
requirement: &id004 !ruby/object:Gem::Requirement
|
52
|
+
none: false
|
53
|
+
requirements:
|
54
|
+
- - ">="
|
55
|
+
- !ruby/object:Gem::Version
|
56
|
+
version: 2.9.4
|
57
|
+
type: :development
|
58
|
+
version_requirements: *id004
|
65
59
|
description: Tracksperanto is a universal 2D-track translator between many apps.
|
66
60
|
email:
|
67
61
|
- me@julik.nl
|
@@ -76,6 +70,7 @@ extra_rdoc_files:
|
|
76
70
|
- DEVELOPER_DOCS.rdoc
|
77
71
|
- README.rdoc
|
78
72
|
files:
|
73
|
+
- .yardopts
|
79
74
|
- DEVELOPER_DOCS.rdoc
|
80
75
|
- History.txt
|
81
76
|
- MIT_LICENSE.txt
|
@@ -94,7 +89,6 @@ files:
|
|
94
89
|
- lib/export/nuke_script.rb
|
95
90
|
- lib/export/pfmatchit.rb
|
96
91
|
- lib/export/pftrack.rb
|
97
|
-
- lib/export/pftrack_2011.rb
|
98
92
|
- lib/export/pftrack_5.rb
|
99
93
|
- lib/export/shake_text.rb
|
100
94
|
- lib/export/syntheyes.rb
|
@@ -136,7 +130,6 @@ files:
|
|
136
130
|
- lib/tracksperanto/flame_builder.rb
|
137
131
|
- lib/tracksperanto/format_detector.rb
|
138
132
|
- lib/tracksperanto/keyframe.rb
|
139
|
-
- lib/tracksperanto/pbar.rb
|
140
133
|
- lib/tracksperanto/progressive_io.rb
|
141
134
|
- lib/tracksperanto/returning.rb
|
142
135
|
- lib/tracksperanto/safety.rb
|
@@ -150,7 +143,6 @@ files:
|
|
150
143
|
- test/export/samples/ref_NukeScript.nk
|
151
144
|
- test/export/samples/ref_PFMatchit.2dt
|
152
145
|
- test/export/samples/ref_PFTrack.2dt
|
153
|
-
- test/export/samples/ref_PFTrack2011.txt
|
154
146
|
- test/export/samples/ref_PFTrack5.2dt
|
155
147
|
- test/export/samples/ref_ShakeText.txt
|
156
148
|
- test/export/samples/ref_Syntheyes.txt
|
@@ -168,7 +160,6 @@ files:
|
|
168
160
|
- test/export/test_mux.rb
|
169
161
|
- test/export/test_nuke_export.rb
|
170
162
|
- test/export/test_pfmatchit_export.rb
|
171
|
-
- test/export/test_pftrack2011_export.rb
|
172
163
|
- test/export/test_pftrack5_export.rb
|
173
164
|
- test/export/test_pftrack_export.rb
|
174
165
|
- test/export/test_shake_export.rb
|
@@ -258,7 +249,6 @@ files:
|
|
258
249
|
- test/test_tracker.rb
|
259
250
|
- test/test_tracksperanto.rb
|
260
251
|
- .gemtest
|
261
|
-
has_rdoc: true
|
262
252
|
homepage: http://guerilla-di.org/tracksperanto
|
263
253
|
licenses: []
|
264
254
|
|
@@ -273,23 +263,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
273
263
|
requirements:
|
274
264
|
- - ">="
|
275
265
|
- !ruby/object:Gem::Version
|
276
|
-
hash: 3
|
277
|
-
segments:
|
278
|
-
- 0
|
279
266
|
version: "0"
|
280
267
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
281
268
|
none: false
|
282
269
|
requirements:
|
283
270
|
- - ">="
|
284
271
|
- !ruby/object:Gem::Version
|
285
|
-
hash: 3
|
286
|
-
segments:
|
287
|
-
- 0
|
288
272
|
version: "0"
|
289
273
|
requirements: []
|
290
274
|
|
291
275
|
rubyforge_project: guerilla-di
|
292
|
-
rubygems_version: 1.
|
276
|
+
rubygems_version: 1.8.5
|
293
277
|
signing_key:
|
294
278
|
specification_version: 3
|
295
279
|
summary: Tracksperanto is a universal 2D-track translator between many apps.
|
@@ -303,7 +287,6 @@ test_files:
|
|
303
287
|
- test/export/test_mux.rb
|
304
288
|
- test/export/test_nuke_export.rb
|
305
289
|
- test/export/test_pfmatchit_export.rb
|
306
|
-
- test/export/test_pftrack2011_export.rb
|
307
290
|
- test/export/test_pftrack5_export.rb
|
308
291
|
- test/export/test_pftrack_export.rb
|
309
292
|
- test/export/test_shake_export.rb
|
data/lib/export/pftrack_2011.rb
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
# Export for PFTrack .2dt files for version 2011
|
2
|
-
class Tracksperanto::Export::PFTrack2011 < Tracksperanto::Export::PFMatchit
|
3
|
-
|
4
|
-
def self.desc_and_extension
|
5
|
-
"pftrack_2011.txt"
|
6
|
-
end
|
7
|
-
|
8
|
-
def self.human_name
|
9
|
-
"PFTrack 2011 .txt file (single camera)"
|
10
|
-
end
|
11
|
-
|
12
|
-
def export_point(frame, abs_float_x, abs_float_y, float_residual)
|
13
|
-
@frame_count += 1
|
14
|
-
# PFTrack 2011 wants one-based frames
|
15
|
-
line = KEYFRAME_TEMPLATE % [frame + 1, abs_float_x, abs_float_y, float_residual / 8]
|
16
|
-
@tracker_io.write(line)
|
17
|
-
@tracker_io.write(linebreak)
|
18
|
-
end
|
19
|
-
|
20
|
-
private
|
21
|
-
|
22
|
-
def camera_name
|
23
|
-
"1"
|
24
|
-
end
|
25
|
-
|
26
|
-
# PFT2011 wants \n
|
27
|
-
def linebreak
|
28
|
-
"\n"
|
29
|
-
end
|
30
|
-
end
|
data/lib/tracksperanto/pbar.rb
DELETED
@@ -1,13 +0,0 @@
|
|
1
|
-
# We make use of the implementation details of the progress bar to also show our current status
|
2
|
-
class Tracksperanto::PBar < ::ProgressBar
|
3
|
-
|
4
|
-
def fmt_title
|
5
|
-
"%20s" % @title
|
6
|
-
end
|
7
|
-
|
8
|
-
def set_with_message(pcnt, message)
|
9
|
-
@title = message
|
10
|
-
set(pcnt)
|
11
|
-
end
|
12
|
-
|
13
|
-
end
|
@@ -1,54 +0,0 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
"Parabolic_1_from_top_left"
|
4
|
-
1
|
5
|
-
19
|
6
|
-
1 0.000 1080.000 0.000
|
7
|
-
2 96.000 874.800 0.006
|
8
|
-
3 192.000 691.200 0.012
|
9
|
-
4 288.000 529.200 0.018
|
10
|
-
5 384.000 388.800 0.024
|
11
|
-
6 480.000 270.000 0.030
|
12
|
-
7 576.000 172.800 0.036
|
13
|
-
8 672.000 97.200 0.042
|
14
|
-
9 768.000 43.200 0.048
|
15
|
-
10 864.000 10.800 0.054
|
16
|
-
13 1152.000 43.200 0.071
|
17
|
-
14 1248.000 97.200 0.077
|
18
|
-
15 1344.000 172.800 0.083
|
19
|
-
16 1440.000 270.000 0.089
|
20
|
-
17 1536.000 388.800 0.095
|
21
|
-
18 1632.000 529.200 0.101
|
22
|
-
19 1728.000 691.200 0.107
|
23
|
-
20 1824.000 874.800 0.113
|
24
|
-
21 1920.000 1080.000 0.119
|
25
|
-
|
26
|
-
|
27
|
-
"Parabolic_2_from_bottom_right"
|
28
|
-
1
|
29
|
-
19
|
30
|
-
1 1920.000 0.000 0.000
|
31
|
-
2 1824.000 205.200 0.006
|
32
|
-
3 1728.000 388.800 0.012
|
33
|
-
4 1632.000 550.800 0.018
|
34
|
-
5 1536.000 691.200 0.024
|
35
|
-
6 1440.000 810.000 0.030
|
36
|
-
7 1344.000 907.200 0.036
|
37
|
-
8 1248.000 982.800 0.042
|
38
|
-
9 1152.000 1036.800 0.048
|
39
|
-
10 1056.000 1069.200 0.054
|
40
|
-
13 768.000 1036.800 0.071
|
41
|
-
14 672.000 982.800 0.077
|
42
|
-
15 576.000 907.200 0.083
|
43
|
-
16 480.000 810.000 0.089
|
44
|
-
17 384.000 691.200 0.095
|
45
|
-
18 288.000 550.800 0.101
|
46
|
-
19 192.000 388.800 0.107
|
47
|
-
20 96.000 205.200 0.113
|
48
|
-
21 0.000 0.000 0.119
|
49
|
-
|
50
|
-
|
51
|
-
"SingleFrame"
|
52
|
-
1
|
53
|
-
1
|
54
|
-
1 970.000 550.000 0.000
|
@@ -1,19 +0,0 @@
|
|
1
|
-
require File.expand_path(File.dirname(__FILE__)) + '/../helper'
|
2
|
-
|
3
|
-
class PFTrack2011ExportTest < Test::Unit::TestCase
|
4
|
-
include ParabolicTracks
|
5
|
-
|
6
|
-
def test_human_name
|
7
|
-
assert_equal "PFTrack 2011 .txt file (single camera)", Tracksperanto::Export::PFTrack2011.human_name
|
8
|
-
end
|
9
|
-
|
10
|
-
def test_desc_and_ext
|
11
|
-
assert_equal "pftrack_2011.txt", Tracksperanto::Export::PFTrack2011.desc_and_extension
|
12
|
-
end
|
13
|
-
|
14
|
-
P = File.dirname(__FILE__) + "/samples/ref_PFTrack2011.txt"
|
15
|
-
|
16
|
-
def test_export_output_written
|
17
|
-
ensure_same_output Tracksperanto::Export::PFTrack2011, P
|
18
|
-
end
|
19
|
-
end
|