flame_channel_parser 4.2.0 → 4.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +23 -0
- data/Gemfile +0 -3
- data/History.txt +5 -0
- data/lib/builder.rb +1 -0
- data/lib/channel.rb +1 -0
- data/lib/extractor.rb +2 -2
- data/lib/flame_channel_parser/version.rb +2 -1
- data/lib/flame_channel_parser.rb +1 -0
- data/lib/framecurve_writers/base.rb +1 -0
- data/lib/framecurve_writers/batch_timewarp.rb +3 -2
- data/lib/framecurve_writers/kronos.rb +1 -0
- data/lib/framecurve_writers/softfx_timewarp.rb +1 -0
- data/lib/inspector.rb +1 -0
- data/lib/interpolator.rb +1 -0
- data/lib/key.rb +1 -0
- data/lib/parser.rb +1 -0
- data/lib/segments.rb +1 -0
- data/lib/timewarp_extractor.rb +1 -0
- data/lib/xml_parser.rb +1 -0
- data/test/test_batch_timewarp_writer.rb +0 -2
- data/test/test_flame_builder.rb +1 -1
- data/test/test_flame_channel_parser.rb +1 -1
- data/test/test_inspector.rb +2 -2
- metadata +2 -3
- data/.autotest +0 -23
- data/.travis.yml +0 -9
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5310312580c16476d46b962fedb4517abefcffa77462be460e8a5368b277941a
|
|
4
|
+
data.tar.gz: 25b0cb4de7e741fb58589ef030e38c7cea6bb811784b33993b8a9e82604acbc2
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 00acdb63e9791ef57d05023fb1235dcaabe7c6fdf15f0e1f82182e03cbdbf9579fe24a1c3e08a57480abcf20fba600399b3c206262591f3381c738534bb4520a
|
|
7
|
+
data.tar.gz: e9908c6a1cb2d07e40ee9a1539bc9463d03ee0870f2ebe66330bf075adc0a63de5099e9891b2fd20bd949492464fe033b392d4c0817de7d49ac73e6437307d28
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
- push
|
|
5
|
+
- pull_request
|
|
6
|
+
|
|
7
|
+
jobs:
|
|
8
|
+
test:
|
|
9
|
+
name: Ruby ${{ matrix.ruby }}
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
strategy:
|
|
12
|
+
fail-fast: false
|
|
13
|
+
matrix:
|
|
14
|
+
ruby:
|
|
15
|
+
- '2.6'
|
|
16
|
+
- '4.0'
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
- uses: ruby/setup-ruby@v1
|
|
20
|
+
with:
|
|
21
|
+
ruby-version: ${{ matrix.ruby }}
|
|
22
|
+
bundler-cache: true
|
|
23
|
+
- run: bundle exec rake test
|
data/Gemfile
CHANGED
data/History.txt
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
=== 4.2.1 / 2026-10-02
|
|
2
|
+
|
|
3
|
+
* Work with frozen string literals, add frozen_string_literal magic comments to all library files
|
|
4
|
+
* Fix the Regexp flags in the Batch timewarp writer (an Array of flags was taken as "ignore case")
|
|
5
|
+
|
|
1
6
|
=== 4.2.0 / 2026-10-02
|
|
2
7
|
|
|
3
8
|
* Make parsing, interpolation and Builder usable from within Ractors (Ruby 4.0+)
|
data/lib/builder.rb
CHANGED
data/lib/channel.rb
CHANGED
data/lib/extractor.rb
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
1
2
|
# shareable_constant_value: literal
|
|
2
3
|
# Extracts and bakes a specific animation channel to a given buffer, one string per frame
|
|
3
4
|
class FlameChannelParser::Extractor
|
|
@@ -105,8 +106,7 @@ class FlameChannelParser::Extractor
|
|
|
105
106
|
end
|
|
106
107
|
|
|
107
108
|
def compose_channel_not_found_message(for_channel, other_channels)
|
|
108
|
-
message = "Channel #{for_channel.inspect} not found in this setup (set the channel with the :channel option). Found other channels though
|
|
109
|
-
message << "\n"
|
|
109
|
+
message = "Channel #{for_channel.inspect} not found in this setup (set the channel with the :channel option). Found other channels though:\n"
|
|
110
110
|
message += other_channels.map{|c| "\t%s\n" % c.path }.join
|
|
111
111
|
end
|
|
112
112
|
|
data/lib/flame_channel_parser.rb
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
1
2
|
# shareable_constant_value: literal
|
|
2
3
|
# Writes out a Batch timewarp node setup
|
|
3
4
|
class FlameChannelParser::FramecurveWriters::BatchTimewarp < FlameChannelParser::FramecurveWriters::SoftfxTimewarp
|
|
@@ -14,7 +15,7 @@ class FlameChannelParser::FramecurveWriters::BatchTimewarp < FlameChannelParser:
|
|
|
14
15
|
yield(w)
|
|
15
16
|
keys = w.keys
|
|
16
17
|
|
|
17
|
-
keys_data = ''
|
|
18
|
+
keys_data = +''
|
|
18
19
|
keys.each_with_index do | k, idx |
|
|
19
20
|
keys_data << templatize(TEMPLATE_KEY, :frame => k[0].to_i, :value => k[1].to_f, :idx => idx)
|
|
20
21
|
end
|
|
@@ -32,7 +33,7 @@ class FlameChannelParser::FramecurveWriters::BatchTimewarp < FlameChannelParser:
|
|
|
32
33
|
t = File.read(file)
|
|
33
34
|
hash.each_pair do | pattern, value |
|
|
34
35
|
p = Regexp.escape('$%s' % pattern)
|
|
35
|
-
handle = Regexp.new(p,
|
|
36
|
+
handle = Regexp.new(p, Regexp::MULTILINE | Regexp::EXTENDED)
|
|
36
37
|
t.gsub!(handle, value.to_s)
|
|
37
38
|
end
|
|
38
39
|
raise "Not all substitutions done" if t.include?('$')
|
data/lib/inspector.rb
CHANGED
data/lib/interpolator.rb
CHANGED
data/lib/key.rb
CHANGED
data/lib/parser.rb
CHANGED
data/lib/segments.rb
CHANGED
data/lib/timewarp_extractor.rb
CHANGED
data/lib/xml_parser.rb
CHANGED
|
@@ -10,8 +10,6 @@ class TestBatchTimewarpWriter < Test::Unit::TestCase
|
|
|
10
10
|
key_writer.key(19, 102)
|
|
11
11
|
end
|
|
12
12
|
|
|
13
|
-
File.open(File.dirname(__FILE__) + "/timewarp_export_samples/BatchTW.timewarp_node", "wb"){|f| f.write(buf.string) }
|
|
14
|
-
|
|
15
13
|
assert_same_buffer File.open(File.dirname(__FILE__) + "/timewarp_export_samples/BatchTW.timewarp_node"), buf
|
|
16
14
|
end
|
|
17
15
|
|
data/test/test_flame_builder.rb
CHANGED
|
@@ -29,7 +29,7 @@ class TestFlameChannelParser < Test::Unit::TestCase
|
|
|
29
29
|
end
|
|
30
30
|
|
|
31
31
|
def test_parsing_kronos_with_reports
|
|
32
|
-
logging_console = ""
|
|
32
|
+
logging_console = +""
|
|
33
33
|
data = File.open(File.dirname(__FILE__) + "/snaps/TW_TEST.F_Kronos")
|
|
34
34
|
parser = FlameChannelParser::Parser.new
|
|
35
35
|
parser.logger_proc = lambda do | log_message |
|
data/test/test_inspector.rb
CHANGED
|
@@ -12,7 +12,7 @@ class TestInspector < Test::Unit::TestCase
|
|
|
12
12
|
channels = FlameChannelParser.parse(data)
|
|
13
13
|
|
|
14
14
|
inspector = FlameChannelParser::Inspector.new(channels)
|
|
15
|
-
output = ''
|
|
15
|
+
output = +''
|
|
16
16
|
|
|
17
17
|
inspector.pretty_print(StringIO.new(output))
|
|
18
18
|
|
|
@@ -27,7 +27,7 @@ class TestInspector < Test::Unit::TestCase
|
|
|
27
27
|
channels = FlameChannelParser.parse(data)
|
|
28
28
|
|
|
29
29
|
inspector = FlameChannelParser::Inspector.new(channels)
|
|
30
|
-
output = ''
|
|
30
|
+
output = +''
|
|
31
31
|
|
|
32
32
|
inspector.pretty_print(StringIO.new(output))
|
|
33
33
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: flame_channel_parser
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 4.2.
|
|
4
|
+
version: 4.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Julik Tarkhanov
|
|
@@ -124,9 +124,8 @@ extensions: []
|
|
|
124
124
|
extra_rdoc_files:
|
|
125
125
|
- README.md
|
|
126
126
|
files:
|
|
127
|
-
- ".
|
|
127
|
+
- ".github/workflows/ci.yml"
|
|
128
128
|
- ".gitignore"
|
|
129
|
-
- ".travis.yml"
|
|
130
129
|
- Gemfile
|
|
131
130
|
- History.txt
|
|
132
131
|
- README.md
|
data/.autotest
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
# -*- ruby -*-
|
|
2
|
-
|
|
3
|
-
require 'autotest/restart'
|
|
4
|
-
|
|
5
|
-
# Autotest.add_hook :initialize do |at|
|
|
6
|
-
# at.extra_files << "../some/external/dependency.rb"
|
|
7
|
-
#
|
|
8
|
-
# at.libs << ":../some/external"
|
|
9
|
-
#
|
|
10
|
-
# at.add_exception 'vendor'
|
|
11
|
-
#
|
|
12
|
-
# at.add_mapping(/dependency.rb/) do |f, _|
|
|
13
|
-
# at.files_matching(/test_.*rb$/)
|
|
14
|
-
# end
|
|
15
|
-
#
|
|
16
|
-
# %w(TestA TestB).each do |klass|
|
|
17
|
-
# at.extra_class_map[klass] = "test/test_misc.rb"
|
|
18
|
-
# end
|
|
19
|
-
# end
|
|
20
|
-
|
|
21
|
-
# Autotest.add_hook :run_command do |at|
|
|
22
|
-
# system "rake build"
|
|
23
|
-
# end
|