tiny_gltf 2.5.0.3 → 2.5.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4e2ee4a6a043835d7b6861e5cb4e0e56ea750c9d7678246ed2f614189c045ccf
4
- data.tar.gz: 8b904768a8c1d19cca92ccb58f669679520e12ebce7571610e3c1bb3fdc75d07
3
+ metadata.gz: 9ad90a4d6c11611a96a653381f3fb7be97404e15277c4bb7ff0c5b2198a8bd9b
4
+ data.tar.gz: 721183c44bbfdb60bf65a889e1f51e219ac0b3f28dfaec32c210ffc621323421
5
5
  SHA512:
6
- metadata.gz: 7e693521d50716b62e729061072e6925a3881b1366cfe45c5e8e1cf40246df244543daf74aedcca84c32731e0a55b2a859c1e1ae8239d0e104ca97a20a674a82
7
- data.tar.gz: 5ad2e959862525c34dd1027da96e8c7f43bfe28a50da2059ec3b3b144e111669f9b271611bba74f49c71362b1b63fa1291485223fdab08adcdc1da3e1cdf9805
6
+ metadata.gz: 5b26aa5d43dff78bfa18dc7b91034506a75fbfcd7f3fb8cc6c0373e5400b62e1187fed83486efd595f7750a4be9227cf6c4060086a8f65c0b29583d43d7e0c81
7
+ data.tar.gz: 313a7ce33ceb3a2b881d908687d75d4ce8b2861ad4f0dbe3245bde5336b6daa95705ab89bb97801d40875e763dc311a838889b291ea9fa8954f7a2308267a3ae
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- tiny_gltf (2.5.0.3)
4
+ tiny_gltf (2.5.0.5)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -30,4 +30,4 @@ DEPENDENCIES
30
30
  yard (~> 0.9)
31
31
 
32
32
  BUNDLED WITH
33
- 2.2.0.rc.1
33
+ 2.5.17
@@ -10,8 +10,17 @@ VALUE rLight_new(const Light *light, VALUE rmodel) {
10
10
 
11
11
  rb_ivar_set(rlight, rb_intern("@model"), rmodel);
12
12
  rb_ivar_set(rlight, rb_intern("@name"), rb_str_new2(light->name.c_str()));
13
- rb_ivar_set(rlight, rb_intern("@type"), rb_intern(light->type.c_str()));
13
+ rb_ivar_set(rlight, rb_intern("@type"), ID2SYM(rb_intern(light->type.c_str())));
14
14
  rb_ivar_set(rlight, rb_intern("@color"), rcolor);
15
+ rb_ivar_set(rlight, rb_intern("@intensity"), DBL2NUM(light->intensity));
16
+ rb_ivar_set(rlight, rb_intern("@range"), DBL2NUM(light->range));
17
+ if (light->type == "spot") {
18
+ rb_ivar_set(rlight, rb_intern("@inner_cone_angle"), DBL2NUM(light->spot.innerConeAngle));
19
+ rb_ivar_set(rlight, rb_intern("@outer_cone_angle"), DBL2NUM(light->spot.outerConeAngle));
20
+ } else {
21
+ rb_ivar_set(rlight, rb_intern("@inner_cone_angle"), DBL2NUM(0));
22
+ rb_ivar_set(rlight, rb_intern("@outer_cone_angle"), DBL2NUM(0));
23
+ }
15
24
 
16
25
  return rlight;
17
26
  }
@@ -1,3 +1,3 @@
1
1
  module TinyGLTF
2
- VERSION = "2.5.0.3"
2
+ VERSION = "2.5.0.5"
3
3
  end
data/lib/tiny_gltf.rb CHANGED
@@ -335,6 +335,10 @@ module TinyGLTF
335
335
  attr_inspectable :name
336
336
  attr_inspectable :color
337
337
  attr_inspectable :type
338
+ attr_inspectable :intensity
339
+ attr_inspectable :range
340
+ attr_inspectable :inner_cone_angle
341
+ attr_inspectable :outer_cone_angle
338
342
  end
339
343
 
340
344
  class Primitive
@@ -356,7 +360,7 @@ module TinyGLTF
356
360
  attr_inspectable :extras
357
361
 
358
362
  def indices
359
- model.accessors[indices_index]
363
+ indices_index && model.accessors[indices_index]
360
364
  end
361
365
 
362
366
  def accessors
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tiny_gltf
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.5.0.3
4
+ version: 2.5.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Colin MacKenzie IV
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-03-16 00:00:00.000000000 Z
11
+ date: 2024-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -183,7 +183,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
183
183
  - !ruby/object:Gem::Version
184
184
  version: '0'
185
185
  requirements: []
186
- rubygems_version: 3.3.7
186
+ rubygems_version: 3.5.0.dev
187
187
  signing_key:
188
188
  specification_version: 4
189
189
  summary: Provides a Ruby extension for TinyGLTF, a C++ glTF 2.0 library.