I don't have Blender as a Python Module, so I can't try that.
Can't repro for background mode using Blender 3.6/4.1 on Linux. I added
bpy.ops.wm.save_as_mainfile(filepath='test.blend')
to the bottom of my above script, saved it as a.py, and…
The length appears to be 0 only if the object is in edit mode. I get the expected length in object mode. Not sure if this is intentional.
This works for me.
import bpy
bpy.ops.object.select_all(action='SELECT')
bpy.ops.object.delete()
bpy.ops.object.select_all(action='DESELECT')
bpy.ops.mesh.primitive_cube_add(size…
Disconnect the Image Texture Alpha <-> Principled Node Alpha link in the Shader Editor.
There's a section about it on the Gotchas page
Help! My script crashes Blender
TL;DR Do not keep…
When you add or remove a color attribute, generally any existing references to color attributes may become junk (pointer is invalidated). Your workaround avoids this problem by holding onto names…
Just looking at [MeshFromGeometry::create_colors](6a9d2212e4/source/blender/io/wavefront_obj/importer/obj_impor
…
Simpler example: Take this OBJ file
v -0.004936 0.000000 1.013093 1.0000 0.4235 0.0000
v 1.995063 0.000000 1.013093 1.0000 0.8470 0.0000
v -0.004936 0.000000 -0.986907 1.0000 0.4235…
Nevermind, I managed to repro. I've attached a Test.obj. If o obj
is inserted on line 796, the vertex colors are broken. If it is inserted on line 797 instead though, it doesn't break.
[Iss117…
Can you attach an OBJ file for testing?
tess.blend in Blender
tess.glb in https://gltf-viewer.donmccurdy.com/
![Viewer.jpg](/attachments/ec43a9bc-b26a-4332-bfaa-9…
The "Vertex Color" node was renamed the "Color Attribute" node (in 3.2 IIRC).
The effect you see is actually from a small bug in the script. start
aliases obj.rotation_quaternion, so you are actually changing start
in the loop.
start = obj.rotation_quaternion #…
I don't what Flip Quats (Alt F) does. I tried it and it appears to do nothing. But I don't think any operator you run after the fact could fix this; the information about which way you rotated is…
@dr.sybren Starting from the default cube, view it from the top in object mode and hit R to start rotating. Spin around one full rotation counter-clockwise. It goes from 0 degrees to 360 degrees.…
Note that this is inconsistent with Eulers, which work as expected. If you spin the bone around a full revolution in Euler mode you go 0° -> 360°. The equivalent for quaternions would be to go 1…