Created
October 11, 2022 01:01
-
-
Save erwincoumans/bc89e92188d7d96242d847c667b5b3e0 to your computer and use it in GitHub Desktop.
Create 120k cubes in Blender 3.4 alpha: selection is broken (b key and select some region of cubes) and deletion (select all 'a', delete 'x') takes very long.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#See Aras' post, https://twitter.com/aras_p/status/1579383862165405696 | |
import time | |
import bpy | |
print("hello world") | |
mesh = bpy.data.meshes['Cube'] | |
start = time.time() | |
for z in range (0,7,3): | |
for x in range(-9,10): | |
for y in range(-9,10): | |
ob = bpy.data.objects.new("Gen", object_data=mesh) | |
ob.location.x = x*2.1 | |
ob.location.y = y*2.1 | |
ob.location.z = z | |
bpy.context.collection.objects.link(ob) | |
end = time.time() | |
print("Generated in ", end-start," sec") | |
start = end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment