fake-bpy-module 20240417__py3-none-any.whl → 20240419__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.

Potentially problematic release.


This version of fake-bpy-module might be problematic. Click here for more details.

Files changed (139) hide show
  1. _bpy_internal/__init__.pyi +4 -0
  2. _bpy_internal/freedesktop/__init__.pyi +88 -0
  3. _bpy_internal/freedesktop/py.typed +0 -0
  4. _bpy_internal/py.typed +0 -0
  5. aud/__init__.pyi +121 -48
  6. bgl/__init__.pyi +2443 -1265
  7. bl_math/__init__.pyi +19 -3
  8. bl_operators/geometry_nodes/__init__.pyi +13 -0
  9. bl_ui/properties_data_light/__init__.pyi +337 -0
  10. blf/__init__.pyi +63 -13
  11. bmesh/__init__.pyi +13 -0
  12. bmesh/geometry/__init__.pyi +5 -0
  13. bmesh/ops/__init__.pyi +157 -68
  14. bmesh/types/__init__.pyi +109 -62
  15. bmesh/utils/__init__.pyi +11 -2
  16. bpy/__init__.pyi +7 -0
  17. bpy/app/__init__.pyi +13 -0
  18. bpy/app/handlers/__init__.pyi +41 -0
  19. bpy/app/icons/__init__.pyi +4 -2
  20. bpy/app/timers/__init__.pyi +38 -2
  21. bpy/app/translations/__init__.pyi +58 -0
  22. bpy/msgbus/__init__.pyi +46 -0
  23. bpy/ops/__init__.pyi +151 -0
  24. bpy/ops/action/__init__.pyi +76 -76
  25. bpy/ops/anim/__init__.pyi +104 -104
  26. bpy/ops/armature/__init__.pyi +96 -96
  27. bpy/ops/asset/__init__.pyi +32 -32
  28. bpy/ops/boid/__init__.pyi +16 -16
  29. bpy/ops/brush/__init__.pyi +18 -18
  30. bpy/ops/buttons/__init__.pyi +12 -12
  31. bpy/ops/cachefile/__init__.pyi +10 -10
  32. bpy/ops/camera/__init__.pyi +4 -4
  33. bpy/ops/clip/__init__.pyi +184 -184
  34. bpy/ops/cloth/__init__.pyi +2 -2
  35. bpy/ops/collection/__init__.pyi +18 -18
  36. bpy/ops/console/__init__.pyi +42 -42
  37. bpy/ops/constraint/__init__.pyi +36 -36
  38. bpy/ops/curve/__init__.pyi +102 -102
  39. bpy/ops/curves/__init__.pyi +54 -54
  40. bpy/ops/cycles/__init__.pyi +6 -6
  41. bpy/ops/dpaint/__init__.pyi +10 -10
  42. bpy/ops/ed/__init__.pyi +24 -24
  43. bpy/ops/export_anim/__init__.pyi +2 -2
  44. bpy/ops/export_mesh/__init__.pyi +2 -2
  45. bpy/ops/export_scene/__init__.pyi +7 -7
  46. bpy/ops/file/__init__.pyi +80 -80
  47. bpy/ops/fluid/__init__.pyi +28 -28
  48. bpy/ops/font/__init__.pyi +46 -46
  49. bpy/ops/geometry/__init__.pyi +20 -20
  50. bpy/ops/gizmogroup/__init__.pyi +4 -4
  51. bpy/ops/gpencil/__init__.pyi +300 -300
  52. bpy/ops/graph/__init__.pyi +130 -130
  53. bpy/ops/grease_pencil/__init__.pyi +112 -112
  54. bpy/ops/image/__init__.pyi +92 -92
  55. bpy/ops/import_anim/__init__.pyi +2 -2
  56. bpy/ops/import_curve/__init__.pyi +2 -2
  57. bpy/ops/import_mesh/__init__.pyi +2 -2
  58. bpy/ops/import_scene/__init__.pyi +6 -6
  59. bpy/ops/info/__init__.pyi +14 -14
  60. bpy/ops/lattice/__init__.pyi +16 -16
  61. bpy/ops/marker/__init__.pyi +22 -22
  62. bpy/ops/mask/__init__.pyi +78 -78
  63. bpy/ops/material/__init__.pyi +6 -6
  64. bpy/ops/mball/__init__.pyi +16 -16
  65. bpy/ops/mesh/__init__.pyi +326 -326
  66. bpy/ops/nla/__init__.pyi +80 -80
  67. bpy/ops/node/__init__.pyi +202 -202
  68. bpy/ops/object/__init__.pyi +509 -500
  69. bpy/ops/outliner/__init__.pyi +138 -138
  70. bpy/ops/paint/__init__.pyi +104 -104
  71. bpy/ops/paintcurve/__init__.pyi +16 -16
  72. bpy/ops/palette/__init__.pyi +14 -14
  73. bpy/ops/particle/__init__.pyi +72 -72
  74. bpy/ops/pose/__init__.pyi +78 -78
  75. bpy/ops/poselib/__init__.pyi +18 -18
  76. bpy/ops/preferences/__init__.pyi +76 -76
  77. bpy/ops/ptcache/__init__.pyi +14 -14
  78. bpy/ops/render/__init__.pyi +24 -24
  79. bpy/ops/rigidbody/__init__.pyi +26 -26
  80. bpy/ops/scene/__init__.pyi +78 -78
  81. bpy/ops/screen/__init__.pyi +78 -78
  82. bpy/ops/script/__init__.pyi +6 -6
  83. bpy/ops/sculpt/__init__.pyi +62 -62
  84. bpy/ops/sculpt_curves/__init__.pyi +8 -8
  85. bpy/ops/sequencer/__init__.pyi +170 -170
  86. bpy/ops/sound/__init__.pyi +14 -14
  87. bpy/ops/spreadsheet/__init__.pyi +8 -8
  88. bpy/ops/surface/__init__.pyi +12 -12
  89. bpy/ops/text/__init__.pyi +86 -86
  90. bpy/ops/text_editor/__init__.pyi +2 -2
  91. bpy/ops/texture/__init__.pyi +8 -8
  92. bpy/ops/transform/__init__.pyi +54 -54
  93. bpy/ops/ui/__init__.pyi +64 -64
  94. bpy/ops/uilist/__init__.pyi +6 -6
  95. bpy/ops/uv/__init__.pyi +98 -98
  96. bpy/ops/view2d/__init__.pyi +28 -28
  97. bpy/ops/view3d/__init__.pyi +134 -134
  98. bpy/ops/wm/__init__.pyi +224 -224
  99. bpy/ops/workspace/__init__.pyi +14 -14
  100. bpy/ops/world/__init__.pyi +2 -2
  101. bpy/path/__init__.pyi +6 -0
  102. bpy/props/__init__.pyi +141 -29
  103. bpy/types/__init__.pyi +101517 -5027
  104. bpy/utils/__init__.pyi +18 -3
  105. bpy/utils/previews/__init__.pyi +15 -0
  106. bpy/utils/units/__init__.pyi +11 -3
  107. bpy_extras/__init__.pyi +19 -0
  108. bpy_extras/asset_utils/__init__.pyi +5 -0
  109. {fake_bpy_module-20240417.dist-info → fake_bpy_module-20240419.dist-info}/METADATA +1 -1
  110. {fake_bpy_module-20240417.dist-info → fake_bpy_module-20240419.dist-info}/RECORD +139 -135
  111. {fake_bpy_module-20240417.dist-info → fake_bpy_module-20240419.dist-info}/top_level.txt +1 -0
  112. freestyle/__init__.pyi +18 -0
  113. freestyle/chainingiterators/__init__.pyi +20 -5
  114. freestyle/functions/__init__.pyi +151 -155
  115. freestyle/predicates/__init__.pyi +53 -46
  116. freestyle/shaders/__init__.pyi +91 -32
  117. freestyle/types/__init__.pyi +362 -120
  118. freestyle/utils/ContextFunctions/__init__.pyi +32 -7
  119. freestyle/utils/__init__.pyi +13 -1
  120. gpu/__init__.pyi +225 -0
  121. gpu/capabilities/__init__.pyi +37 -15
  122. gpu/matrix/__init__.pyi +7 -1
  123. gpu/platform/__init__.pyi +5 -0
  124. gpu/select/__init__.pyi +5 -0
  125. gpu/shader/__init__.pyi +77 -0
  126. gpu/state/__init__.pyi +15 -4
  127. gpu/texture/__init__.pyi +5 -0
  128. gpu/types/__init__.pyi +91 -33
  129. gpu_extras/__init__.pyi +15 -0
  130. gpu_extras/presets/__init__.pyi +16 -4
  131. imbuf/__init__.pyi +13 -0
  132. imbuf/types/__init__.pyi +20 -5
  133. mathutils/__init__.pyi +349 -227
  134. mathutils/bvhtree/__init__.pyi +21 -8
  135. mathutils/geometry/__init__.pyi +23 -9
  136. mathutils/interpolate/__init__.pyi +5 -0
  137. mathutils/kdtree/__init__.pyi +19 -5
  138. mathutils/noise/__init__.pyi +87 -41
  139. {fake_bpy_module-20240417.dist-info → fake_bpy_module-20240419.dist-info}/WHEEL +0 -0
bmesh/types/__init__.pyi CHANGED
@@ -1,3 +1,24 @@
1
+ """
2
+
3
+ --------------------
4
+
5
+
6
+ --------------------
7
+
8
+
9
+ --------------------
10
+
11
+
12
+ --------------------
13
+
14
+
15
+ --------------------
16
+
17
+
18
+ --------------------
19
+
20
+ """
21
+
1
22
  import typing
2
23
  import bpy.types
3
24
  import mathutils
@@ -11,11 +32,12 @@ class BMDeformVert:
11
32
  """Clears all weights."""
12
33
  ...
13
34
 
14
- def get(self, key, default=None):
35
+ def get(self, key: int, default=None):
15
36
  """Returns the deform weight matching the key or default
16
37
  when not found (matches Python's dictionary function of the same name).
17
38
 
18
39
  :param key: The key associated with deform weight.
40
+ :type key: int
19
41
  :param default: Optional argument for the value to return if
20
42
  key is not found.
21
43
  """
@@ -29,7 +51,7 @@ class BMDeformVert:
29
51
  """
30
52
  ...
31
53
 
32
- def keys(self):
54
+ def keys(self) -> typing.List[int]:
33
55
  """Return the group indices used by this vertex
34
56
  (matching Python's dict.keys() functionality).
35
57
 
@@ -38,7 +60,7 @@ class BMDeformVert:
38
60
  """
39
61
  ...
40
62
 
41
- def values(self) -> typing.List[int]:
63
+ def values(self) -> typing.List[float]:
42
64
  """Return the weights of the deform vertex
43
65
  (matching Python's dict.values() functionality).
44
66
 
@@ -56,8 +78,11 @@ class BMEdge:
56
78
  :type: bool
57
79
  """
58
80
 
59
- index: typing.Any
60
- """ Index of this element."""
81
+ index: int
82
+ """ Index of this element.
83
+
84
+ :type: int
85
+ """
61
86
 
62
87
  is_boundary: bool
63
88
  """ True when this edge is at the boundary of a face (read-only).
@@ -137,34 +162,37 @@ class BMEdge:
137
162
  :type: typing.Union[typing.List[BMVert], BMElemSeq]
138
163
  """
139
164
 
140
- def calc_face_angle(self, fallback: typing.Any = None) -> typing.Any:
165
+ def calc_face_angle(self, fallback: typing.Any = None) -> float:
141
166
  """
142
167
 
143
168
  :param fallback: return this when the edge doesn't have 2 faces
144
169
  (instead of raising a `ValueError`).
145
170
  :type fallback: typing.Any
146
171
  :return: The angle between 2 connected faces in radians.
172
+ :rtype: float
147
173
  """
148
174
  ...
149
175
 
150
- def calc_face_angle_signed(self, fallback: typing.Any = None) -> typing.Any:
176
+ def calc_face_angle_signed(self, fallback: typing.Any = None) -> float:
151
177
  """
152
178
 
153
179
  :param fallback: return this when the edge doesn't have 2 faces
154
180
  (instead of raising a `ValueError`).
155
181
  :type fallback: typing.Any
156
182
  :return: The angle between 2 connected faces in radians (negative for concave join).
183
+ :rtype: float
157
184
  """
158
185
  ...
159
186
 
160
- def calc_length(self):
187
+ def calc_length(self) -> float:
161
188
  """
162
189
 
163
190
  :return: The length between both verts.
191
+ :rtype: float
164
192
  """
165
193
  ...
166
194
 
167
- def calc_tangent(self, loop: BMLoop) -> BMLoop:
195
+ def calc_tangent(self, loop: BMLoop) -> mathutils.Vector:
168
196
  """Return the tangent at this edge relative to a face (pointing inward into the face).
169
197
  This uses the face normal for calculation.
170
198
 
@@ -195,7 +223,7 @@ class BMEdge:
195
223
  """Update normals of all connected faces and the edge verts."""
196
224
  ...
197
225
 
198
- def other_vert(self, vert: BMVert) -> BMVert:
226
+ def other_vert(self, vert: BMVert):
199
227
  """Return the other vertex on this edge or None if the vertex is not used by this edge.
200
228
 
201
229
  :param vert: a vert in this edge.
@@ -226,7 +254,7 @@ class BMEdgeSeq:
226
254
  """Ensure internal data needed for int subscription is initialized with verts/edges/faces, eg bm.verts[index].This needs to be called again after adding/removing data in this sequence."""
227
255
  ...
228
256
 
229
- def get(self, verts: BMVert, fallback=None):
257
+ def get(self, verts: BMVert, fallback=None) -> BMEdge:
230
258
  """Return an edge which uses the verts passed.
231
259
 
232
260
  :param verts: Sequence of verts.
@@ -268,7 +296,7 @@ class BMEdgeSeq:
268
296
  """
269
297
  ...
270
298
 
271
- def __getitem__(self, key: int) -> int:
299
+ def __getitem__(self, key: int) -> BMEdge:
272
300
  """
273
301
 
274
302
  :param key:
@@ -288,7 +316,7 @@ class BMEdgeSeq:
288
316
  """
289
317
  ...
290
318
 
291
- def __delitem__(self, key: int) -> int:
319
+ def __delitem__(self, key: int) -> BMEdge:
292
320
  """
293
321
 
294
322
  :param key:
@@ -298,7 +326,7 @@ class BMEdgeSeq:
298
326
  """
299
327
  ...
300
328
 
301
- def __iter__(self) -> BMEdge:
329
+ def __iter__(self) -> typing.Iterator[GenericType]:
302
330
  """
303
331
 
304
332
  :return:
@@ -306,7 +334,7 @@ class BMEdgeSeq:
306
334
  """
307
335
  ...
308
336
 
309
- def __next__(self) -> typing.Iterator[GenericType]:
337
+ def __next__(self) -> GenericType:
310
338
  """
311
339
 
312
340
  :return:
@@ -314,7 +342,7 @@ class BMEdgeSeq:
314
342
  """
315
343
  ...
316
344
 
317
- def __len__(self) -> GenericType:
345
+ def __len__(self) -> int:
318
346
  """
319
347
 
320
348
  :return:
@@ -375,7 +403,7 @@ class BMElemSeq:
375
403
  """Initialize the index values of this sequence.This is the equivalent of looping over all elements and assigning the index values."""
376
404
  ...
377
405
 
378
- def __getitem__(self, key: int) -> int:
406
+ def __getitem__(self, key: int) -> GenericType:
379
407
  """
380
408
 
381
409
  :param key:
@@ -395,7 +423,7 @@ class BMElemSeq:
395
423
  """
396
424
  ...
397
425
 
398
- def __delitem__(self, key: int) -> int:
426
+ def __delitem__(self, key: int) -> GenericType:
399
427
  """
400
428
 
401
429
  :param key:
@@ -405,7 +433,7 @@ class BMElemSeq:
405
433
  """
406
434
  ...
407
435
 
408
- def __iter__(self) -> GenericType:
436
+ def __iter__(self) -> typing.Iterator[GenericType]:
409
437
  """
410
438
 
411
439
  :return:
@@ -413,7 +441,7 @@ class BMElemSeq:
413
441
  """
414
442
  ...
415
443
 
416
- def __next__(self) -> typing.Iterator[GenericType]:
444
+ def __next__(self) -> GenericType:
417
445
  """
418
446
 
419
447
  :return:
@@ -421,7 +449,7 @@ class BMElemSeq:
421
449
  """
422
450
  ...
423
451
 
424
- def __len__(self) -> GenericType:
452
+ def __len__(self) -> int:
425
453
  """
426
454
 
427
455
  :return:
@@ -444,8 +472,11 @@ class BMFace:
444
472
  :type: bool
445
473
  """
446
474
 
447
- index: typing.Any
448
- """ Index of this element."""
475
+ index: int
476
+ """ Index of this element.
477
+
478
+ :type: int
479
+ """
449
480
 
450
481
  is_valid: bool
451
482
  """ True when this element is valid (hasn't been removed).
@@ -459,8 +490,11 @@ class BMFace:
459
490
  :type: typing.Union[typing.List[BMLoop], BMElemSeq]
460
491
  """
461
492
 
462
- material_index: typing.Any
463
- """ The face's material index."""
493
+ material_index: int
494
+ """ The face's material index.
495
+
496
+ :type: int
497
+ """
464
498
 
465
499
  normal: typing.Union[typing.Sequence[float], mathutils.Vector]
466
500
  """ The normal for this face as a 3D, wrapped vector.
@@ -492,14 +526,15 @@ class BMFace:
492
526
  :type: typing.Union[typing.List[BMVert], BMElemSeq]
493
527
  """
494
528
 
495
- def calc_area(self) -> typing.Union[typing.List[BMVert], BMElemSeq]:
529
+ def calc_area(self) -> float:
496
530
  """Return the area of the face.
497
531
 
498
532
  :return: Return the area of the face.
533
+ :rtype: float
499
534
  """
500
535
  ...
501
536
 
502
- def calc_center_bounds(self):
537
+ def calc_center_bounds(self) -> mathutils.Vector:
503
538
  """Return bounds center of the face.
504
539
 
505
540
  :return: a 3D vector.
@@ -523,14 +558,15 @@ class BMFace:
523
558
  """
524
559
  ...
525
560
 
526
- def calc_perimeter(self) -> mathutils.Vector:
561
+ def calc_perimeter(self) -> float:
527
562
  """Return the perimeter of the face.
528
563
 
529
564
  :return: Return the perimeter of the face.
565
+ :rtype: float
530
566
  """
531
567
  ...
532
568
 
533
- def calc_tangent_edge(self):
569
+ def calc_tangent_edge(self) -> mathutils.Vector:
534
570
  """Return face tangent based on longest edge.
535
571
 
536
572
  :return: a normalized vector.
@@ -562,7 +598,7 @@ class BMFace:
562
598
  """
563
599
  ...
564
600
 
565
- def copy(self, verts: bool = True, edges: bool = True) -> bool:
601
+ def copy(self, verts: bool = True, edges: bool = True) -> BMFace:
566
602
  """Make a copy of this face.
567
603
 
568
604
  :param verts: When set, the faces verts will be duplicated too.
@@ -636,7 +672,7 @@ class BMFaceSeq:
636
672
  """Ensure internal data needed for int subscription is initialized with verts/edges/faces, eg bm.verts[index].This needs to be called again after adding/removing data in this sequence."""
637
673
  ...
638
674
 
639
- def get(self, verts: BMVert, fallback=None):
675
+ def get(self, verts: BMVert, fallback=None) -> BMFace:
640
676
  """Return a face which uses the verts passed.
641
677
 
642
678
  :param verts: Sequence of verts.
@@ -679,7 +715,7 @@ class BMFaceSeq:
679
715
  """
680
716
  ...
681
717
 
682
- def __getitem__(self, key: int) -> int:
718
+ def __getitem__(self, key: int) -> BMFace:
683
719
  """
684
720
 
685
721
  :param key:
@@ -699,7 +735,7 @@ class BMFaceSeq:
699
735
  """
700
736
  ...
701
737
 
702
- def __delitem__(self, key: int) -> int:
738
+ def __delitem__(self, key: int) -> BMFace:
703
739
  """
704
740
 
705
741
  :param key:
@@ -709,7 +745,7 @@ class BMFaceSeq:
709
745
  """
710
746
  ...
711
747
 
712
- def __iter__(self) -> BMFace:
748
+ def __iter__(self) -> typing.Iterator[GenericType]:
713
749
  """
714
750
 
715
751
  :return:
@@ -717,7 +753,7 @@ class BMFaceSeq:
717
753
  """
718
754
  ...
719
755
 
720
- def __next__(self) -> typing.Iterator[GenericType]:
756
+ def __next__(self) -> GenericType:
721
757
  """
722
758
 
723
759
  :return:
@@ -725,7 +761,7 @@ class BMFaceSeq:
725
761
  """
726
762
  ...
727
763
 
728
- def __len__(self) -> GenericType:
764
+ def __len__(self) -> int:
729
765
  """
730
766
 
731
767
  :return:
@@ -879,7 +915,7 @@ class BMLayerCollection:
879
915
  """
880
916
  ...
881
917
 
882
- def keys(self):
918
+ def keys(self) -> typing.List[str]:
883
919
  """Return the identifiers of collection members
884
920
  (matching Python's dict.keys() functionality).
885
921
 
@@ -888,7 +924,7 @@ class BMLayerCollection:
888
924
  """
889
925
  ...
890
926
 
891
- def new(self, name: str) -> str:
927
+ def new(self, name: str) -> BMLayerItem:
892
928
  """Create a new layer
893
929
 
894
930
  :param name: Optional name argument (will be made unique).
@@ -906,7 +942,7 @@ class BMLayerCollection:
906
942
  """
907
943
  ...
908
944
 
909
- def values(self) -> BMLayerItem:
945
+ def values(self) -> list:
910
946
  """Return the values of collection
911
947
  (matching Python's dict.values() functionality).
912
948
 
@@ -915,7 +951,7 @@ class BMLayerCollection:
915
951
  """
916
952
  ...
917
953
 
918
- def verify(self) -> list:
954
+ def verify(self) -> BMLayerItem:
919
955
  """Create a new layer or return an existing active layer
920
956
 
921
957
  :return: The newly verified layer.
@@ -954,8 +990,11 @@ class BMLoop:
954
990
  :type: BMFace
955
991
  """
956
992
 
957
- index: typing.Any
958
- """ Index of this element."""
993
+ index: int
994
+ """ Index of this element.
995
+
996
+ :type: int
997
+ """
959
998
 
960
999
  is_convex: bool
961
1000
  """ True when this loop is at the convex corner of a face, depends on a valid face normal (read-only).
@@ -1011,15 +1050,16 @@ class BMLoop:
1011
1050
  :type: BMVert
1012
1051
  """
1013
1052
 
1014
- def calc_angle(self) -> BMVert:
1053
+ def calc_angle(self) -> float:
1015
1054
  """Return the angle at this loops corner of the face.
1016
1055
  This is calculated so sharper corners give lower angles.
1017
1056
 
1018
1057
  :return: The angle in radians.
1058
+ :rtype: float
1019
1059
  """
1020
1060
  ...
1021
1061
 
1022
- def calc_normal(self):
1062
+ def calc_normal(self) -> mathutils.Vector:
1023
1063
  """Return normal at this loops corner of the face.
1024
1064
  Falls back to the face normal for straight lines.
1025
1065
 
@@ -1067,7 +1107,7 @@ class BMLoopSeq:
1067
1107
  :type: BMLayerAccessLoop
1068
1108
  """
1069
1109
 
1070
- def __getitem__(self, key: int) -> int:
1110
+ def __getitem__(self, key: int) -> BMLoop:
1071
1111
  """
1072
1112
 
1073
1113
  :param key:
@@ -1087,7 +1127,7 @@ class BMLoopSeq:
1087
1127
  """
1088
1128
  ...
1089
1129
 
1090
- def __delitem__(self, key: int) -> int:
1130
+ def __delitem__(self, key: int) -> BMLoop:
1091
1131
  """
1092
1132
 
1093
1133
  :param key:
@@ -1097,7 +1137,7 @@ class BMLoopSeq:
1097
1137
  """
1098
1138
  ...
1099
1139
 
1100
- def __iter__(self) -> BMLoop:
1140
+ def __iter__(self) -> typing.Iterator[GenericType]:
1101
1141
  """
1102
1142
 
1103
1143
  :return:
@@ -1105,7 +1145,7 @@ class BMLoopSeq:
1105
1145
  """
1106
1146
  ...
1107
1147
 
1108
- def __next__(self) -> typing.Iterator[GenericType]:
1148
+ def __next__(self) -> GenericType:
1109
1149
  """
1110
1150
 
1111
1151
  :return:
@@ -1113,7 +1153,7 @@ class BMLoopSeq:
1113
1153
  """
1114
1154
  ...
1115
1155
 
1116
- def __len__(self) -> GenericType:
1156
+ def __len__(self) -> int:
1117
1157
  """
1118
1158
 
1119
1159
  :return:
@@ -1163,8 +1203,11 @@ class BMVert:
1163
1203
  :type: bool
1164
1204
  """
1165
1205
 
1166
- index: typing.Any
1167
- """ Index of this element."""
1206
+ index: int
1207
+ """ Index of this element.
1208
+
1209
+ :type: int
1210
+ """
1168
1211
 
1169
1212
  is_boundary: bool
1170
1213
  """ True when this vertex is connected to boundary edges (read-only).
@@ -1226,22 +1269,24 @@ class BMVert:
1226
1269
  :type: bool
1227
1270
  """
1228
1271
 
1229
- def calc_edge_angle(self, fallback: typing.Any = None) -> typing.Any:
1272
+ def calc_edge_angle(self, fallback: typing.Any = None) -> float:
1230
1273
  """Return the angle between this vert's two connected edges.
1231
1274
 
1232
1275
  :param fallback: return this when the vert doesn't have 2 edges
1233
1276
  (instead of raising a `ValueError`).
1234
1277
  :type fallback: typing.Any
1235
1278
  :return: Angle between edges in radians.
1279
+ :rtype: float
1236
1280
  """
1237
1281
  ...
1238
1282
 
1239
- def calc_shell_factor(self):
1283
+ def calc_shell_factor(self) -> float:
1240
1284
  """Return a multiplier calculated based on the sharpness of the vertex.
1241
1285
  Where a flat surface gives 1.0, and higher values sharper edges.
1242
1286
  This is used to maintain shell thickness when offsetting verts along their normals.
1243
1287
 
1244
1288
  :return: offset multiplier
1289
+ :rtype: float
1245
1290
  """
1246
1291
  ...
1247
1292
 
@@ -1343,7 +1388,7 @@ class BMVertSeq:
1343
1388
  """
1344
1389
  ...
1345
1390
 
1346
- def __getitem__(self, key: int) -> int:
1391
+ def __getitem__(self, key: int) -> BMVert:
1347
1392
  """
1348
1393
 
1349
1394
  :param key:
@@ -1363,7 +1408,7 @@ class BMVertSeq:
1363
1408
  """
1364
1409
  ...
1365
1410
 
1366
- def __delitem__(self, key: int) -> int:
1411
+ def __delitem__(self, key: int) -> BMVert:
1367
1412
  """
1368
1413
 
1369
1414
  :param key:
@@ -1373,7 +1418,7 @@ class BMVertSeq:
1373
1418
  """
1374
1419
  ...
1375
1420
 
1376
- def __iter__(self) -> BMVert:
1421
+ def __iter__(self) -> typing.Iterator[GenericType]:
1377
1422
  """
1378
1423
 
1379
1424
  :return:
@@ -1381,7 +1426,7 @@ class BMVertSeq:
1381
1426
  """
1382
1427
  ...
1383
1428
 
1384
- def __next__(self) -> typing.Iterator[GenericType]:
1429
+ def __next__(self) -> GenericType:
1385
1430
  """
1386
1431
 
1387
1432
  :return:
@@ -1389,7 +1434,7 @@ class BMVertSeq:
1389
1434
  """
1390
1435
  ...
1391
1436
 
1392
- def __len__(self) -> GenericType:
1437
+ def __len__(self) -> int:
1393
1438
  """
1394
1439
 
1395
1440
  :return:
@@ -1448,19 +1493,20 @@ class BMesh:
1448
1493
  :type: BMVertSeq
1449
1494
  """
1450
1495
 
1451
- def calc_loop_triangles(self) -> BMVertSeq:
1496
+ def calc_loop_triangles(self):
1452
1497
  """Calculate triangle tessellation from quads/ngons.
1453
1498
 
1454
1499
  :return: The triangulated faces.
1455
1500
  """
1456
1501
  ...
1457
1502
 
1458
- def calc_volume(self, signed: bool = False) -> bool:
1503
+ def calc_volume(self, signed: bool = False) -> float:
1459
1504
  """Calculate mesh volume based on face normals.
1460
1505
 
1461
1506
  :param signed: when signed is true, negative values may be returned.
1462
1507
  :type signed: bool
1463
1508
  :return: The volume of the mesh.
1509
+ :rtype: float
1464
1510
  """
1465
1511
  ...
1466
1512
 
@@ -1468,7 +1514,7 @@ class BMesh:
1468
1514
  """Clear all mesh data."""
1469
1515
  ...
1470
1516
 
1471
- def copy(self):
1517
+ def copy(self) -> BMesh:
1472
1518
  """
1473
1519
 
1474
1520
  :return: A copy of this BMesh.
@@ -1486,7 +1532,7 @@ class BMesh:
1486
1532
  face_normals=True,
1487
1533
  vertex_normals=True,
1488
1534
  use_shape_key: bool = False,
1489
- shape_key_index=0,
1535
+ shape_key_index: int = 0,
1490
1536
  ):
1491
1537
  """Initialize this bmesh from existing mesh datablock.
1492
1538
 
@@ -1497,6 +1543,7 @@ class BMesh:
1497
1543
  :param use_shape_key: Use the locations from a shape key.
1498
1544
  :type use_shape_key: bool
1499
1545
  :param shape_key_index: The shape key index to use.
1546
+ :type shape_key_index: int
1500
1547
  """
1501
1548
  ...
1502
1549
 
bmesh/utils/__init__.pyi CHANGED
@@ -1,3 +1,8 @@
1
+ """
2
+ This module provides access to blenders bmesh data structures.
3
+
4
+ """
5
+
1
6
  import typing
2
7
  import bmesh.types
3
8
 
@@ -17,7 +22,9 @@ def edge_rotate(edge: bmesh.types.BMEdge, ccw: bool = False) -> bmesh.types.BMEd
17
22
 
18
23
  ...
19
24
 
20
- def edge_split(edge: bmesh.types.BMEdge, vert: bmesh.types.BMVert, fac) -> typing.Tuple:
25
+ def edge_split(
26
+ edge: bmesh.types.BMEdge, vert: bmesh.types.BMVert, fac: float
27
+ ) -> typing.Tuple:
21
28
  """Split an edge, return the newly created data.
22
29
 
23
30
  :param edge: The edge to split.
@@ -25,6 +32,7 @@ def edge_split(edge: bmesh.types.BMEdge, vert: bmesh.types.BMVert, fac) -> typin
25
32
  :param vert: One of the verts on the edge, defines the split direction.
26
33
  :type vert: bmesh.types.BMVert
27
34
  :param fac: The point on the edge where the new vert will be created [0 - 1].
35
+ :type fac: float
28
36
  :return: The newly created (edge, vert) pair.
29
37
  :rtype: typing.Tuple
30
38
  """
@@ -134,7 +142,7 @@ def vert_collapse_edge(
134
142
  ...
135
143
 
136
144
  def vert_collapse_faces(
137
- vert: bmesh.types.BMVert, edge: bmesh.types.BMEdge, fac, join_faces: bool
145
+ vert: bmesh.types.BMVert, edge: bmesh.types.BMEdge, fac: float, join_faces: bool
138
146
  ) -> bmesh.types.BMEdge:
139
147
  """Collapses a vertex that has only two manifold edges onto a vertex it shares an edge with.
140
148
 
@@ -143,6 +151,7 @@ def vert_collapse_faces(
143
151
  :param edge: The edge to collapse into.
144
152
  :type edge: bmesh.types.BMEdge
145
153
  :param fac: The factor to use when merging customdata [0 - 1].
154
+ :type fac: float
146
155
  :param join_faces: When true the faces around the vertex will be joined otherwise collapse the vertex by merging the 2 edges this vertex connects to into one.
147
156
  :type join_faces: bool
148
157
  :return: The resulting edge from the collapse operation.
bpy/__init__.pyi CHANGED
@@ -1,3 +1,10 @@
1
+ """
2
+ This module is used for all Blender/Python access.
3
+
4
+ ```../examples/bpy.data.py```
5
+
6
+ """
7
+
1
8
  import typing
2
9
  import bpy.types
3
10
 
bpy/app/__init__.pyi CHANGED
@@ -1,3 +1,16 @@
1
+ """
2
+ This module contains application values that remain unchanged during runtime.
3
+
4
+ bpy.app.handlers.rst
5
+ bpy.app.translations.rst
6
+ bpy.app.icons.rst
7
+ bpy.app.timers.rst
8
+
9
+ :maxdepth: 1
10
+ :caption: Submodules
11
+
12
+ """
13
+
1
14
  import typing
2
15
  from . import handlers
3
16
  from . import icons
@@ -1,3 +1,44 @@
1
+ """
2
+ This module contains callback lists
3
+
4
+
5
+ --------------------
6
+
7
+ This script shows the most simple example of adding a handler.
8
+
9
+ ```../examples/bpy.app.handlers.py```
10
+
11
+
12
+ --------------------
13
+
14
+ By default handlers are freed when loading new files, in some cases you may
15
+ want the handler stay running across multiple files (when the handler is
16
+ part of an add-on for example).
17
+
18
+ For this the bpy.app.handlers.persistent decorator needs to be used.
19
+
20
+ ```../examples/bpy.app.handlers.1.py```
21
+
22
+
23
+ --------------------
24
+
25
+ Altering data from handlers should be done carefully. While rendering the
26
+ frame_change_pre
27
+
28
+ and frame_change_post
29
+
30
+ handlers are called from one
31
+ thread and the viewport updates from a different thread. If the handler changes
32
+ data that is accessed by the viewport, this can cause a crash of Blender. In
33
+ such cases, lock the interface (Render → Lock Interface or
34
+ bpy.types.RenderSettings.use_lock_interface) before starting a render.
35
+
36
+ Below is an example of a mesh that is altered from a handler:
37
+
38
+ ```../examples/bpy.app.handlers.2.py```
39
+
40
+ """
41
+
1
42
  import typing
2
43
  import bpy.types
3
44