ncca-ngl 0.2.4__py3-none-any.whl → 0.2.5__py3-none-any.whl

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.
ncca/ngl/vec2.py CHANGED
@@ -5,6 +5,8 @@ Simple float only Vec2 class for 3D graphics, very similar to the pyngl ones
5
5
  import ctypes
6
6
  import math
7
7
 
8
+ import numpy as np
9
+
8
10
  from .util import clamp
9
11
 
10
12
 
@@ -74,7 +76,7 @@ class Vec2:
74
76
  Raises:
75
77
  ValueError: If v is not a float or int.
76
78
  """
77
- if not isinstance(v, (int, float)):
79
+ if not isinstance(v, (int, float, np.float32)):
78
80
  raise ValueError("need float or int")
79
81
  else:
80
82
  setattr(self, name, v)
ncca/ngl/vec3.py CHANGED
@@ -73,7 +73,7 @@ class Vec3:
73
73
  Raises:
74
74
  ValueError: If v is not a float or int.
75
75
  """
76
- if not isinstance(v, (int, float)):
76
+ if not isinstance(v, (int, float, np.float32)):
77
77
  raise ValueError("need float or int")
78
78
  else:
79
79
  setattr(self, name, v)
ncca/ngl/vec4.py CHANGED
@@ -33,7 +33,7 @@ class Vec4:
33
33
  Raises:
34
34
  ValueError: If v is not a float or int.
35
35
  """
36
- if not isinstance(v, (int, float)):
36
+ if not isinstance(v, (int, float, np.float32)):
37
37
  raise ValueError("need float or int")
38
38
  else:
39
39
  setattr(self, name, v)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: ncca-ngl
3
- Version: 0.2.4
3
+ Version: 0.2.5
4
4
  Summary: A Python version of the NGL graphics library.
5
5
  Author: Jon Macey
6
6
  Author-email: Jon Macey <jmacey@bournemouth.ac.uk>
@@ -54,12 +54,12 @@ ncca/ngl/texture.py,sha256=OgBBEItgUDohCsVWgmjEWcQWBJaXl9w070PTOOywPx4,2303
54
54
  ncca/ngl/transform.py,sha256=_PibgtFoU_exfvQUWucmts0WF5OreSTNbftvSa3zT8g,2938
55
55
  ncca/ngl/util.py,sha256=8jp5vTVuGfVHMSktFEubtoaQ8SvLIQtM2UNbUeMTOFk,4372
56
56
  ncca/ngl/vao_factory.py,sha256=v87VfrUMaoqcsE-CS9kM7h5Fyk_e0LGl_iA6xqaomPg,930
57
- ncca/ngl/vec2.py,sha256=XLDBdSS2uqJbDG4gl1bL2YR79fl77bQeu98OEMQMVCQ,10204
57
+ ncca/ngl/vec2.py,sha256=ggrBtJK77c9d_JnN6eik50kZAa1zjudWhll6_5afkFo,10236
58
58
  ncca/ngl/vec2_array.py,sha256=7QRgXh75fORsmNnSnNxNQWk6_rnDgfmRX3tmJZ4ES9E,3420
59
- ncca/ngl/vec3.py,sha256=NAiwdosG5ONcdGBBQGCfnskMdj7MH3eGagavjaU1SyI,12263
59
+ ncca/ngl/vec3.py,sha256=N_-LvP0nB0CQrZWG7TJntUl6QDHzIVLP-J1w8wPZTM0,12275
60
60
  ncca/ngl/vec3_array.py,sha256=fLRC8k0TwcaU7CnR2GmJ0prud4dcvvUX0JTbQH_2W3Y,3535
61
- ncca/ngl/vec4.py,sha256=rkowZkxacU9l0piLnsEYdgMn94gdkYUzipcn4i8lES0,6739
61
+ ncca/ngl/vec4.py,sha256=mLl23D-3yAxh7GsP44ilRto-PMqIDxJjcZpNl2MyqGQ,6751
62
62
  ncca/ngl/vec4_array.py,sha256=PSJXfG0g2AT4oQCLHiVAP6EC5n7vMXRQy0N1rGvv1iw,3426
63
- ncca_ngl-0.2.4.dist-info/WHEEL,sha256=eh7sammvW2TypMMMGKgsM83HyA_3qQ5Lgg3ynoecH3M,79
64
- ncca_ngl-0.2.4.dist-info/METADATA,sha256=fl3kZoMULNeTS--RhNPD-hM6v3uWQ76LpLHm9fcO_9U,1596
65
- ncca_ngl-0.2.4.dist-info/RECORD,,
63
+ ncca_ngl-0.2.5.dist-info/WHEEL,sha256=eh7sammvW2TypMMMGKgsM83HyA_3qQ5Lgg3ynoecH3M,79
64
+ ncca_ngl-0.2.5.dist-info/METADATA,sha256=-oJBR9uyewb9MnPn6ifLU6eqp3TBukVUP1zWfeGRo50,1596
65
+ ncca_ngl-0.2.5.dist-info/RECORD,,