spiro 0.0.2 → 0.0.3
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/ext/spiro/spiro.c +3 -2
- data/lib/spiro/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ee3407c84146c03c8d578b5f088d5c59b4e42b3d
|
4
|
+
data.tar.gz: bc746ad74c9db0ea5bd3034a187c3837e5c51538
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 081feb3bc4c8d0bea7f10a3a317e77a99f75295b8a9cfeffc56a5a9546b18840fd0d454f9b8e8122955c00a70be31967860aa3d20ece33ceb6ddf4eb497e4ce3
|
7
|
+
data.tar.gz: 493f4dc5dd4501d1150c8368e56891442f05a60c18262893e1c19097b84d0b919585d19ff2f08e7bc6e417854f05d5f35e53ca21176e48727b9d18b0f79f2bbd
|
data/ext/spiro/spiro.c
CHANGED
@@ -56,7 +56,8 @@ static VALUE spiros_to_splines(VALUE mod, VALUE spirosValue, VALUE closedValue)
|
|
56
56
|
|
57
57
|
// Take Ruby array of points and turn into Spiro C struct array
|
58
58
|
spiro_cp spiros[RARRAY_LEN(spirosValue)];
|
59
|
-
|
59
|
+
int i;
|
60
|
+
for (i = 0; i != RARRAY_LEN(spirosValue); i++) {
|
60
61
|
VALUE nodeValue = rb_ary_entry(spirosValue, i);
|
61
62
|
// Validate node is an array and length 3 (x, y, type)
|
62
63
|
Check_Type(nodeValue, T_ARRAY);
|
@@ -91,7 +92,7 @@ static VALUE spiros_to_splines(VALUE mod, VALUE spirosValue, VALUE closedValue)
|
|
91
92
|
VALUE splinesValue = rb_ary_new();
|
92
93
|
// Free memory from the custom struct
|
93
94
|
bezctx_rb_close(bc);
|
94
|
-
for (
|
95
|
+
for (i = 0; i < splines.used; i++) {
|
95
96
|
VALUE x = rb_float_new(splines.array[i].x);
|
96
97
|
VALUE y = rb_float_new(splines.array[i].y);
|
97
98
|
VALUE ty = spline_type_to_sym(splines.array[i].ty);
|
data/lib/spiro/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: spiro
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Raph Levien
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2015-09-
|
13
|
+
date: 2015-09-25 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: bundler
|