blender-python-stubs 5.1.0.0__tar.gz → 5.1.0.2__tar.gz
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.
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/PKG-INFO +8 -5
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/README.md +6 -3
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bmesh/types/__init__.pyi +182 -138
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/__init__.pyi +1 -0
- blender_python_stubs-5.1.0.2/bpy/msgbus/__init__.pyi +30 -0
- blender_python_stubs-5.1.0.2/bpy/ops/__init__.pyi +81726 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/types/__init__.pyi +3800 -1339
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/anim_utils/__init__.pyi +2 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/types/__init__.pyi +109 -52
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/types/__init__.pyi +24 -8
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/idprop/types/__init__.pyi +14 -0
- blender_python_stubs-5.1.0.2/mathutils/__init__.pyi +3320 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/pyproject.toml +2 -2
- blender_python_stubs-5.1.0.0/bpy/ops/__init__.pyi +0 -195
- blender_python_stubs-5.1.0.0/mathutils/__init__.pyi +0 -2280
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/.gitignore +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/.python-version +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/LICENSE +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/aud/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/aud/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bl_math/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bl_math/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/blf/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/blf/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bmesh/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bmesh/geometry/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bmesh/ops/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bmesh/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bmesh/utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/app/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/path/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/props/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/utils/previews/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy/utils/toolsystem/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/asset_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/bmesh_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/id_map_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/image_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/io_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/keyconfig_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/mesh_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/node_shader_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/node_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/object_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/bpy_extras/view3d_utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/chainingiterators/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/functions/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/predicates/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/shaders/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/freestyle/utils/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/capabilities/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/compute/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/matrix/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/platform/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/select/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/shader/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/state/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu/texture/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu_extras/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu_extras/batch/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu_extras/presets/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/gpu_extras/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/idprop/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/idprop/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/imbuf/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/imbuf/py.typed +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/imbuf/types/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/mathutils/bvhtree/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/mathutils/geometry/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/mathutils/interpolate/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/mathutils/kdtree/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/mathutils/noise/__init__.pyi +0 -0
- {blender_python_stubs-5.1.0.0 → blender_python_stubs-5.1.0.2}/mathutils/py.typed +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: blender-python-stubs
|
|
3
|
-
Version: 5.1.0.
|
|
3
|
+
Version: 5.1.0.2
|
|
4
4
|
Summary: Type stubs for Blender 5.1 Python API
|
|
5
5
|
Project-URL: Homepage, https://git.autourdeminuit.com/autour_de_minuit/blender-python-stubs
|
|
6
6
|
Project-URL: Issues, https://git.autourdeminuit.com/autour_de_minuit/blender-python-stubs/issues
|
|
@@ -10,7 +10,7 @@ Author-email: Autour de Minuit <tech@autourdeminuit.com>
|
|
|
10
10
|
License-Expression: MIT
|
|
11
11
|
License-File: LICENSE
|
|
12
12
|
Keywords: autocomplete,blender,bpy,stubs,typing
|
|
13
|
-
Classifier: Development Status ::
|
|
13
|
+
Classifier: Development Status :: 4 - Beta
|
|
14
14
|
Classifier: Intended Audience :: Developers
|
|
15
15
|
Classifier: Programming Language :: Python :: 3
|
|
16
16
|
Classifier: Topic :: Multimedia :: Graphics :: 3D Modeling
|
|
@@ -21,9 +21,11 @@ Description-Content-Type: text/markdown
|
|
|
21
21
|
|
|
22
22
|
# blender-python-stubs
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
[](https://pypi.org/project/blender-python-stubs/)
|
|
25
25
|
|
|
26
|
-
|
|
26
|
+
Strict type stubs for Blender 5.1 Python API.
|
|
27
|
+
|
|
28
|
+
Provides autocomplete, type checking, and inline documentation for `bpy`, `mathutils`, `bmesh`, `gpu`, `freestyle`, and all other Blender Python modules. Generated stubs pass [basedpyright](https://docs.basedpyright.com) `all` mode with 0 errors and use zero `typing.Any`.
|
|
27
29
|
|
|
28
30
|
## Installation
|
|
29
31
|
|
|
@@ -47,7 +49,8 @@ pip install "blender-python-stubs>=5.1,<5.2"
|
|
|
47
49
|
```python
|
|
48
50
|
import bpy
|
|
49
51
|
|
|
50
|
-
obj
|
|
52
|
+
obj = bpy.context.active_object
|
|
53
|
+
assert obj is not None
|
|
51
54
|
obj.location.x = 1.0
|
|
52
55
|
|
|
53
56
|
bpy.data.objects.new("Cube", bpy.data.meshes.new("Mesh"))
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
# blender-python-stubs
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://pypi.org/project/blender-python-stubs/)
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Strict type stubs for Blender 5.1 Python API.
|
|
6
|
+
|
|
7
|
+
Provides autocomplete, type checking, and inline documentation for `bpy`, `mathutils`, `bmesh`, `gpu`, `freestyle`, and all other Blender Python modules. Generated stubs pass [basedpyright](https://docs.basedpyright.com) `all` mode with 0 errors and use zero `typing.Any`.
|
|
6
8
|
|
|
7
9
|
## Installation
|
|
8
10
|
|
|
@@ -26,7 +28,8 @@ pip install "blender-python-stubs>=5.1,<5.2"
|
|
|
26
28
|
```python
|
|
27
29
|
import bpy
|
|
28
30
|
|
|
29
|
-
obj
|
|
31
|
+
obj = bpy.context.active_object
|
|
32
|
+
assert obj is not None
|
|
30
33
|
obj.location.x = 1.0
|
|
31
34
|
|
|
32
35
|
bpy.data.objects.new("Cube", bpy.data.meshes.new("Mesh"))
|
|
@@ -84,46 +84,51 @@ class BMEdge:
|
|
|
84
84
|
|
|
85
85
|
To ensure the value is up to date - see :meth:`BMElemSeq.index_update`."""
|
|
86
86
|
|
|
87
|
-
|
|
88
|
-
|
|
87
|
+
@property
|
|
88
|
+
def is_boundary(self) -> bool:
|
|
89
|
+
"""True when this edge is at the boundary of a face (read-only).
|
|
89
90
|
|
|
90
|
-
:type: bool"""
|
|
91
|
+
:type: bool"""
|
|
91
92
|
|
|
92
|
-
|
|
93
|
-
|
|
93
|
+
@property
|
|
94
|
+
def is_contiguous(self) -> bool:
|
|
95
|
+
"""True when this edge is manifold, between two faces with the same winding (read-only).
|
|
94
96
|
|
|
95
|
-
:type: bool"""
|
|
97
|
+
:type: bool"""
|
|
96
98
|
|
|
97
|
-
|
|
98
|
-
|
|
99
|
+
@property
|
|
100
|
+
def is_convex(self) -> bool:
|
|
101
|
+
"""True when this edge joins two convex faces, depends on a valid face normal (read-only).
|
|
99
102
|
|
|
100
|
-
:type: bool"""
|
|
103
|
+
:type: bool"""
|
|
101
104
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
:type: bool"""
|
|
105
|
+
@property
|
|
106
|
+
def is_manifold(self) -> bool:
|
|
107
|
+
"""True when this edge is manifold (read-only).
|
|
106
108
|
|
|
109
|
+
:type: bool"""
|
|
107
110
|
is_valid: bool
|
|
108
111
|
"""True when this element is valid (hasn't been freed or removed).
|
|
109
112
|
|
|
110
113
|
:type: bool"""
|
|
111
114
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
:type: bool"""
|
|
115
|
+
@property
|
|
116
|
+
def is_wire(self) -> bool:
|
|
117
|
+
"""True when this edge is not connected to any faces (read-only).
|
|
116
118
|
|
|
117
|
-
|
|
118
|
-
"""Faces connected to this edge, (read-only).
|
|
119
|
+
:type: bool"""
|
|
119
120
|
|
|
120
|
-
|
|
121
|
+
@property
|
|
122
|
+
def link_faces(self) -> BMElemSeq[BMFace]:
|
|
123
|
+
"""Faces connected to this edge, (read-only).
|
|
121
124
|
|
|
122
|
-
|
|
123
|
-
"""Loops connected to this edge, (read-only).
|
|
125
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMFace`]"""
|
|
124
126
|
|
|
125
|
-
|
|
127
|
+
@property
|
|
128
|
+
def link_loops(self) -> BMElemSeq[BMLoop]:
|
|
129
|
+
"""Loops connected to this edge, (read-only).
|
|
126
130
|
|
|
131
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMLoop`]"""
|
|
127
132
|
seam: bool
|
|
128
133
|
"""Seam for UV unwrapping.
|
|
129
134
|
|
|
@@ -144,10 +149,11 @@ class BMEdge:
|
|
|
144
149
|
|
|
145
150
|
:type: bool"""
|
|
146
151
|
|
|
147
|
-
|
|
148
|
-
|
|
152
|
+
@property
|
|
153
|
+
def verts(self) -> BMElemSeq[BMVert]:
|
|
154
|
+
"""Verts this edge uses (always 2), (read-only).
|
|
149
155
|
|
|
150
|
-
:type: :class:`BMElemSeq`\\ [:class:`BMVert`]"""
|
|
156
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMVert`]"""
|
|
151
157
|
|
|
152
158
|
def __delitem__(self, key: int | slice) -> None:
|
|
153
159
|
"""Delete self[key]."""
|
|
@@ -214,10 +220,11 @@ class BMEdge:
|
|
|
214
220
|
def __iter__(self) -> Iterator[object]: ...
|
|
215
221
|
|
|
216
222
|
class BMEdgeSeq:
|
|
217
|
-
|
|
218
|
-
|
|
223
|
+
@property
|
|
224
|
+
def layers(self) -> BMLayerAccessEdge:
|
|
225
|
+
"""custom-data layers (read-only).
|
|
219
226
|
|
|
220
|
-
:type: :class:`BMLayerAccessEdge`"""
|
|
227
|
+
:type: :class:`BMLayerAccessEdge`"""
|
|
221
228
|
|
|
222
229
|
def __contains__(self, key: object, /) -> bool:
|
|
223
230
|
"""Return bool(key in self)."""
|
|
@@ -280,10 +287,11 @@ class BMEditSelIter:
|
|
|
280
287
|
"""Implement iter(self)."""
|
|
281
288
|
|
|
282
289
|
class BMEditSelSeq:
|
|
283
|
-
|
|
284
|
-
|
|
290
|
+
@property
|
|
291
|
+
def active(self) -> BMVert | BMEdge | BMFace | None:
|
|
292
|
+
"""The last selected element or None (read-only).
|
|
285
293
|
|
|
286
|
-
:type: :class:`BMVert` | :class:`BMEdge` | :class:`BMFace` | None"""
|
|
294
|
+
:type: :class:`BMVert` | :class:`BMEdge` | :class:`BMFace` | None"""
|
|
287
295
|
|
|
288
296
|
def __contains__(self, key: object, /) -> bool:
|
|
289
297
|
"""Return bool(key in self)."""
|
|
@@ -352,11 +360,11 @@ class BMElemSeq(Generic[_T]):
|
|
|
352
360
|
class BMFace:
|
|
353
361
|
"""The BMesh face with 3 or more sides"""
|
|
354
362
|
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
:type: :class:`BMElemSeq`\\ [:class:`BMEdge`]"""
|
|
363
|
+
@property
|
|
364
|
+
def edges(self) -> BMElemSeq[BMEdge]:
|
|
365
|
+
"""Edges of this face, (read-only).
|
|
359
366
|
|
|
367
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMEdge`]"""
|
|
360
368
|
hide: bool
|
|
361
369
|
"""Hidden state of this element.
|
|
362
370
|
|
|
@@ -380,20 +388,24 @@ class BMFace:
|
|
|
380
388
|
|
|
381
389
|
:type: bool"""
|
|
382
390
|
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
:type: :class:`BMElemSeq`\\ [:class:`BMLoop`]"""
|
|
391
|
+
@property
|
|
392
|
+
def loops(self) -> BMElemSeq[BMLoop]:
|
|
393
|
+
"""Loops of this face, (read-only).
|
|
387
394
|
|
|
395
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMLoop`]"""
|
|
388
396
|
material_index: int
|
|
389
397
|
"""The face's material index.
|
|
390
398
|
|
|
391
399
|
:type: int"""
|
|
392
400
|
|
|
393
|
-
|
|
394
|
-
|
|
401
|
+
@property
|
|
402
|
+
def normal(self) -> mathutils.Vector:
|
|
403
|
+
"""The normal for this face as a 3D, wrapped vector.
|
|
404
|
+
|
|
405
|
+
:type: :class:`mathutils.Vector`"""
|
|
395
406
|
|
|
396
|
-
|
|
407
|
+
@normal.setter
|
|
408
|
+
def normal(self, value: mathutils.Vector | Sequence[float]) -> None: ...
|
|
397
409
|
|
|
398
410
|
select: bool
|
|
399
411
|
"""Selected state of this element.
|
|
@@ -415,10 +427,11 @@ class BMFace:
|
|
|
415
427
|
|
|
416
428
|
:type: bool"""
|
|
417
429
|
|
|
418
|
-
|
|
419
|
-
|
|
430
|
+
@property
|
|
431
|
+
def verts(self) -> BMElemSeq[BMVert]:
|
|
432
|
+
"""Verts of this face, (read-only).
|
|
420
433
|
|
|
421
|
-
:type: :class:`BMElemSeq`\\ [:class:`BMVert`]"""
|
|
434
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMVert`]"""
|
|
422
435
|
|
|
423
436
|
def __delitem__(self, key: int | slice) -> None:
|
|
424
437
|
"""Delete self[key]."""
|
|
@@ -515,10 +528,11 @@ class BMFaceSeq:
|
|
|
515
528
|
|
|
516
529
|
:type: :class:`BMFace` | None"""
|
|
517
530
|
|
|
518
|
-
|
|
519
|
-
|
|
531
|
+
@property
|
|
532
|
+
def layers(self) -> BMLayerAccessFace:
|
|
533
|
+
"""custom-data layers (read-only).
|
|
520
534
|
|
|
521
|
-
:type: :class:`BMLayerAccessFace`"""
|
|
535
|
+
:type: :class:`BMLayerAccessFace`"""
|
|
522
536
|
|
|
523
537
|
def __contains__(self, key: object, /) -> bool:
|
|
524
538
|
"""Return bool(key in self)."""
|
|
@@ -759,15 +773,17 @@ class BMLayerAccessVert:
|
|
|
759
773
|
class BMLayerCollection(Generic[_T]):
|
|
760
774
|
"""Gives access to a collection of custom-data layers of the same type and behaves like Python dictionaries, except for the ability to do list like index access."""
|
|
761
775
|
|
|
762
|
-
|
|
763
|
-
|
|
776
|
+
@property
|
|
777
|
+
def active(self) -> BMLayerItem | None:
|
|
778
|
+
"""The active layer of this type (read-only).
|
|
764
779
|
|
|
765
|
-
:type: :class:`BMLayerItem` | None"""
|
|
780
|
+
:type: :class:`BMLayerItem` | None"""
|
|
766
781
|
|
|
767
|
-
|
|
768
|
-
|
|
782
|
+
@property
|
|
783
|
+
def is_singleton(self) -> bool:
|
|
784
|
+
"""True if there can exist only one layer of this type (read-only).
|
|
769
785
|
|
|
770
|
-
:type: bool"""
|
|
786
|
+
:type: bool"""
|
|
771
787
|
|
|
772
788
|
def __contains__(self, key: object, /) -> bool:
|
|
773
789
|
"""Return bool(key in self)."""
|
|
@@ -821,10 +837,11 @@ class BMLayerCollection(Generic[_T]):
|
|
|
821
837
|
class BMLayerItem:
|
|
822
838
|
"""Exposes a single custom data layer, its main purpose is for use as an item accessor to custom-data when used with vert/edge/face/loop data."""
|
|
823
839
|
|
|
824
|
-
|
|
825
|
-
|
|
840
|
+
@property
|
|
841
|
+
def name(self) -> str:
|
|
842
|
+
"""The layer's unique name (read-only).
|
|
826
843
|
|
|
827
|
-
:type: str"""
|
|
844
|
+
:type: str"""
|
|
828
845
|
|
|
829
846
|
def copy_from(self, other: BMLayerItem, /) -> None:
|
|
830
847
|
"""Copy data from another layer.
|
|
@@ -835,16 +852,17 @@ class BMLayerItem:
|
|
|
835
852
|
class BMLoop:
|
|
836
853
|
"""This is normally accessed from :class:`BMFace.loops` where each face loop represents a corner of the face."""
|
|
837
854
|
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
:type: :class:`BMEdge`"""
|
|
855
|
+
@property
|
|
856
|
+
def edge(self) -> BMEdge:
|
|
857
|
+
"""The loop's edge (between this loop and the next), (read-only).
|
|
842
858
|
|
|
843
|
-
|
|
844
|
-
"""The face this loop belongs to (read-only).
|
|
859
|
+
:type: :class:`BMEdge`"""
|
|
845
860
|
|
|
846
|
-
|
|
861
|
+
@property
|
|
862
|
+
def face(self) -> BMFace:
|
|
863
|
+
"""The face this loop belongs to (read-only).
|
|
847
864
|
|
|
865
|
+
:type: :class:`BMFace`"""
|
|
848
866
|
index: int
|
|
849
867
|
"""Index of this element.
|
|
850
868
|
|
|
@@ -858,41 +876,45 @@ class BMLoop:
|
|
|
858
876
|
|
|
859
877
|
To ensure the value is up to date - see :meth:`BMElemSeq.index_update`."""
|
|
860
878
|
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
:type: bool"""
|
|
879
|
+
@property
|
|
880
|
+
def is_convex(self) -> bool:
|
|
881
|
+
"""True when this loop is at the convex corner of a face, depends on a valid face normal (read-only).
|
|
865
882
|
|
|
883
|
+
:type: bool"""
|
|
866
884
|
is_valid: bool
|
|
867
885
|
"""True when this element is valid (hasn't been freed or removed).
|
|
868
886
|
|
|
869
887
|
:type: bool"""
|
|
870
888
|
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
:type: :class:`BMLoop`"""
|
|
889
|
+
@property
|
|
890
|
+
def link_loop_next(self) -> BMLoop:
|
|
891
|
+
"""The next face corner (read-only).
|
|
875
892
|
|
|
876
|
-
|
|
877
|
-
"""The previous face corner (read-only).
|
|
893
|
+
:type: :class:`BMLoop`"""
|
|
878
894
|
|
|
879
|
-
|
|
895
|
+
@property
|
|
896
|
+
def link_loop_prev(self) -> BMLoop:
|
|
897
|
+
"""The previous face corner (read-only).
|
|
880
898
|
|
|
881
|
-
|
|
882
|
-
"""The next loop around the edge (read-only).
|
|
899
|
+
:type: :class:`BMLoop`"""
|
|
883
900
|
|
|
884
|
-
|
|
901
|
+
@property
|
|
902
|
+
def link_loop_radial_next(self) -> BMLoop:
|
|
903
|
+
"""The next loop around the edge (read-only).
|
|
885
904
|
|
|
886
|
-
|
|
887
|
-
"""The previous loop around the edge (read-only).
|
|
905
|
+
:type: :class:`BMLoop`"""
|
|
888
906
|
|
|
889
|
-
|
|
907
|
+
@property
|
|
908
|
+
def link_loop_radial_prev(self) -> BMLoop:
|
|
909
|
+
"""The previous loop around the edge (read-only).
|
|
890
910
|
|
|
891
|
-
|
|
892
|
-
"""Loops connected to this loop, (read-only).
|
|
911
|
+
:type: :class:`BMLoop`"""
|
|
893
912
|
|
|
894
|
-
|
|
913
|
+
@property
|
|
914
|
+
def link_loops(self) -> BMElemSeq[BMLoop]:
|
|
915
|
+
"""Loops connected to this loop, (read-only).
|
|
895
916
|
|
|
917
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMLoop`]"""
|
|
896
918
|
tag: bool
|
|
897
919
|
"""Generic attribute scripts can use for own logic
|
|
898
920
|
|
|
@@ -908,10 +930,11 @@ class BMLoop:
|
|
|
908
930
|
|
|
909
931
|
:type: bool"""
|
|
910
932
|
|
|
911
|
-
|
|
912
|
-
|
|
933
|
+
@property
|
|
934
|
+
def vert(self) -> BMVert:
|
|
935
|
+
"""The loop's vertex (read-only).
|
|
913
936
|
|
|
914
|
-
:type: :class:`BMVert`"""
|
|
937
|
+
:type: :class:`BMVert`"""
|
|
915
938
|
|
|
916
939
|
def __delitem__(self, key: int | slice) -> None:
|
|
917
940
|
"""Delete self[key]."""
|
|
@@ -966,10 +989,11 @@ class BMLoop:
|
|
|
966
989
|
def __iter__(self) -> Iterator[object]: ...
|
|
967
990
|
|
|
968
991
|
class BMLoopSeq:
|
|
969
|
-
|
|
970
|
-
|
|
992
|
+
@property
|
|
993
|
+
def layers(self) -> BMLayerAccessLoop:
|
|
994
|
+
"""custom-data layers (read-only).
|
|
971
995
|
|
|
972
|
-
:type: :class:`BMLayerAccessLoop`"""
|
|
996
|
+
:type: :class:`BMLayerAccessLoop`"""
|
|
973
997
|
|
|
974
998
|
class BMLoopUV:
|
|
975
999
|
pin_uv: bool
|
|
@@ -977,18 +1001,26 @@ class BMLoopUV:
|
|
|
977
1001
|
|
|
978
1002
|
:type: bool"""
|
|
979
1003
|
|
|
980
|
-
|
|
981
|
-
|
|
1004
|
+
@property
|
|
1005
|
+
def uv(self) -> mathutils.Vector:
|
|
1006
|
+
"""Loop UV (as a 2D Vector).
|
|
1007
|
+
|
|
1008
|
+
:type: :class:`mathutils.Vector`"""
|
|
982
1009
|
|
|
983
|
-
|
|
1010
|
+
@uv.setter
|
|
1011
|
+
def uv(self, value: mathutils.Vector | Sequence[float]) -> None: ...
|
|
984
1012
|
|
|
985
1013
|
class BMVert:
|
|
986
1014
|
"""The BMesh vertex type"""
|
|
987
1015
|
|
|
988
|
-
|
|
989
|
-
|
|
1016
|
+
@property
|
|
1017
|
+
def co(self) -> mathutils.Vector:
|
|
1018
|
+
"""The coordinates for this vertex as a 3D, wrapped vector.
|
|
990
1019
|
|
|
991
|
-
:type: :class:`mathutils.Vector`"""
|
|
1020
|
+
:type: :class:`mathutils.Vector`"""
|
|
1021
|
+
|
|
1022
|
+
@co.setter
|
|
1023
|
+
def co(self, value: mathutils.Vector | Sequence[float]) -> None: ...
|
|
992
1024
|
|
|
993
1025
|
hide: bool
|
|
994
1026
|
"""Hidden state of this element.
|
|
@@ -1008,45 +1040,54 @@ class BMVert:
|
|
|
1008
1040
|
|
|
1009
1041
|
To ensure the value is up to date - see :meth:`BMElemSeq.index_update`."""
|
|
1010
1042
|
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
:type: bool"""
|
|
1043
|
+
@property
|
|
1044
|
+
def is_boundary(self) -> bool:
|
|
1045
|
+
"""True when this vertex is connected to boundary edges (read-only).
|
|
1015
1046
|
|
|
1016
|
-
|
|
1017
|
-
"""True when this vertex is manifold (read-only).
|
|
1047
|
+
:type: bool"""
|
|
1018
1048
|
|
|
1019
|
-
|
|
1049
|
+
@property
|
|
1050
|
+
def is_manifold(self) -> bool:
|
|
1051
|
+
"""True when this vertex is manifold (read-only).
|
|
1020
1052
|
|
|
1053
|
+
:type: bool"""
|
|
1021
1054
|
is_valid: bool
|
|
1022
1055
|
"""True when this element is valid (hasn't been freed or removed).
|
|
1023
1056
|
|
|
1024
1057
|
:type: bool"""
|
|
1025
1058
|
|
|
1026
|
-
|
|
1027
|
-
|
|
1059
|
+
@property
|
|
1060
|
+
def is_wire(self) -> bool:
|
|
1061
|
+
"""True when this vertex is not connected to any faces (read-only).
|
|
1028
1062
|
|
|
1029
|
-
:type: bool"""
|
|
1063
|
+
:type: bool"""
|
|
1064
|
+
|
|
1065
|
+
@property
|
|
1066
|
+
def link_edges(self) -> BMElemSeq[BMEdge]:
|
|
1067
|
+
"""Edges connected to this vertex (read-only).
|
|
1030
1068
|
|
|
1031
|
-
|
|
1032
|
-
"""Edges connected to this vertex (read-only).
|
|
1069
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMEdge`]"""
|
|
1033
1070
|
|
|
1034
|
-
|
|
1071
|
+
@property
|
|
1072
|
+
def link_faces(self) -> BMElemSeq[BMFace]:
|
|
1073
|
+
"""Faces connected to this vertex (read-only).
|
|
1035
1074
|
|
|
1036
|
-
|
|
1037
|
-
"""Faces connected to this vertex (read-only).
|
|
1075
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMFace`]"""
|
|
1038
1076
|
|
|
1039
|
-
|
|
1077
|
+
@property
|
|
1078
|
+
def link_loops(self) -> BMElemSeq[BMLoop]:
|
|
1079
|
+
"""Loops that use this vertex (read-only).
|
|
1040
1080
|
|
|
1041
|
-
|
|
1042
|
-
"""Loops that use this vertex (read-only).
|
|
1081
|
+
:type: :class:`BMElemSeq`\\ [:class:`BMLoop`]"""
|
|
1043
1082
|
|
|
1044
|
-
|
|
1083
|
+
@property
|
|
1084
|
+
def normal(self) -> mathutils.Vector:
|
|
1085
|
+
"""The normal for this vertex as a 3D, wrapped vector.
|
|
1045
1086
|
|
|
1046
|
-
|
|
1047
|
-
"""The normal for this vertex as a 3D, wrapped vector.
|
|
1087
|
+
:type: :class:`mathutils.Vector`"""
|
|
1048
1088
|
|
|
1049
|
-
|
|
1089
|
+
@normal.setter
|
|
1090
|
+
def normal(self, value: mathutils.Vector | Sequence[float]) -> None: ...
|
|
1050
1091
|
|
|
1051
1092
|
select: bool
|
|
1052
1093
|
"""Selected state of this element.
|
|
@@ -1120,10 +1161,11 @@ class BMVert:
|
|
|
1120
1161
|
def __iter__(self) -> Iterator[object]: ...
|
|
1121
1162
|
|
|
1122
1163
|
class BMVertSeq:
|
|
1123
|
-
|
|
1124
|
-
|
|
1164
|
+
@property
|
|
1165
|
+
def layers(self) -> BMLayerAccessVert:
|
|
1166
|
+
"""custom-data layers (read-only).
|
|
1125
1167
|
|
|
1126
|
-
:type: :class:`BMLayerAccessVert`"""
|
|
1168
|
+
:type: :class:`BMLayerAccessVert`"""
|
|
1127
1169
|
|
|
1128
1170
|
def __contains__(self, key: object, /) -> bool:
|
|
1129
1171
|
"""Return bool(key in self)."""
|
|
@@ -1180,16 +1222,17 @@ class BMVertSeq:
|
|
|
1180
1222
|
class BMesh:
|
|
1181
1223
|
"""The BMesh data structure"""
|
|
1182
1224
|
|
|
1183
|
-
|
|
1184
|
-
|
|
1225
|
+
@property
|
|
1226
|
+
def edges(self) -> BMEdgeSeq:
|
|
1227
|
+
"""This mesh's edge sequence (read-only).
|
|
1185
1228
|
|
|
1186
|
-
:type: :class:`BMEdgeSeq`"""
|
|
1229
|
+
:type: :class:`BMEdgeSeq`"""
|
|
1187
1230
|
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
:type: :class:`BMFaceSeq`"""
|
|
1231
|
+
@property
|
|
1232
|
+
def faces(self) -> BMFaceSeq:
|
|
1233
|
+
"""This mesh's face sequence (read-only).
|
|
1192
1234
|
|
|
1235
|
+
:type: :class:`BMFaceSeq`"""
|
|
1193
1236
|
is_valid: bool
|
|
1194
1237
|
"""True when this element is valid (hasn't been freed or removed).
|
|
1195
1238
|
|
|
@@ -1200,15 +1243,15 @@ class BMesh:
|
|
|
1200
1243
|
|
|
1201
1244
|
:type: bool"""
|
|
1202
1245
|
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
:type: :class:`BMLoopSeq`
|
|
1246
|
+
@property
|
|
1247
|
+
def loops(self) -> BMLoopSeq:
|
|
1248
|
+
"""This mesh's loops (read-only).
|
|
1207
1249
|
|
|
1208
|
-
|
|
1250
|
+
:type: :class:`BMLoopSeq`
|
|
1209
1251
|
|
|
1210
|
-
|
|
1252
|
+
.. note::
|
|
1211
1253
|
|
|
1254
|
+
Loops must be accessed via faces, this is only exposed for layer access."""
|
|
1212
1255
|
select_history: BMEditSelSeq
|
|
1213
1256
|
"""Sequence of selected items (the last is displayed as active).
|
|
1214
1257
|
|
|
@@ -1224,10 +1267,11 @@ class BMesh:
|
|
|
1224
1267
|
|
|
1225
1268
|
:type: bool"""
|
|
1226
1269
|
|
|
1227
|
-
|
|
1228
|
-
|
|
1270
|
+
@property
|
|
1271
|
+
def verts(self) -> BMVertSeq:
|
|
1272
|
+
"""This mesh's vert sequence (read-only).
|
|
1229
1273
|
|
|
1230
|
-
:type: :class:`BMVertSeq`"""
|
|
1274
|
+
:type: :class:`BMVertSeq`"""
|
|
1231
1275
|
|
|
1232
1276
|
def calc_loop_triangles(self) -> list[tuple[BMLoop, BMLoop, BMLoop]]:
|
|
1233
1277
|
"""Calculate triangle tessellation from quads/ngons."""
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
from collections.abc import Callable
|
|
2
|
+
from typing import Literal
|
|
3
|
+
import bpy.types
|
|
4
|
+
|
|
5
|
+
def clear_by_owner(owner: object, /) -> None:
|
|
6
|
+
"""Clear all subscribers using this owner.
|
|
7
|
+
|
|
8
|
+
:param owner: The owner handle passed to :func:`subscribe_rna`.
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
def publish_rna(
|
|
12
|
+
*,
|
|
13
|
+
key: bpy.types.Property | bpy.types.Struct | tuple[bpy.types.Struct, str] | object,
|
|
14
|
+
) -> None:
|
|
15
|
+
""":param key: Represents the type of data being subscribed to
|
|
16
|
+
|
|
17
|
+
Arguments include
|
|
18
|
+
- A property instance.
|
|
19
|
+
- A struct type.
|
|
20
|
+
- A tuple representing a (struct, property name) pair.
|
|
21
|
+
"""
|
|
22
|
+
|
|
23
|
+
def subscribe_rna(
|
|
24
|
+
*,
|
|
25
|
+
key: bpy.types.Property | bpy.types.Struct | tuple[bpy.types.Struct, str] | object,
|
|
26
|
+
owner: object,
|
|
27
|
+
args: tuple[object, ...],
|
|
28
|
+
notify: Callable[..., None],
|
|
29
|
+
options: set[Literal["PERSISTENT"]] = ...,
|
|
30
|
+
) -> None: ...
|