friggog / tree-gen

Procedural generation of tree models in blender
GNU General Public License v3.0
827 stars 74 forks source link

cant generate leaves #65

Closed shotzz5 closed 2 years ago

shotzz5 commented 3 years ago

ive tried unisntaling and instaling the addon tweaked about with everything but for some reason they just dont generate

friggog commented 3 years ago

What version of blender are you on? Also by not generating do you mean it crashes or nothing appears or an empty mesh appears?

shotzz5 commented 2 years ago

sry for the late response, im on blender 2.93.5, by not generating them i mean nothing leaf related appears, just a trunk (is i triple checked i have leaf gen on)

samipfjo commented 2 years ago

Well, the good news is that Treegen is running, the bad news is that something is causing an error. There will be an error in the Blender console (Window > Console), would you mind taking a screenshot of it?

friggog commented 2 years ago

Just tried on 2.93.5 and everything works for me, would be great to have more info (type of tree, traceback as Luke suggested etc)

ThisIsADogHello commented 2 years ago

Just happened to me. Not entirely sure how to repro, since the problem only really happened to me after I've been spending a lot of time in one scene generating hundreds of trees as I tweaked the parameters. Luckily, I've got the error log and it's an easy fix. I've made a pull request #70 with the fix, but for posterity here's the error log the fix is based on:

Generating Tree

Using seed: 2

Making Stems -> 11000 stems made Stems made: 11061 in 38.622472 seconds Curve points: 33521

Making Leaves

Traceback (most recent call last): File "C:\Users\hadley\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\tree-gen\gui.py", line 235, in _construct tree = parametric.gen.construct(params, scene.seed_input, scene.generate_leaves_input) File "C:\Users\hadley\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\tree-gen\parametric\gen.py", line 1261, in construct t.make() File "C:\Users\hadley\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\tree-gen\parametric\gen.py", line 191, in make self.create_leaf_mesh() File "C:\Users\hadley\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\tree-gen\parametric\gen.py", line 296, in create_leaf_mesh windman.progress_begin(0, len(self.leaves_array)) ReferenceError: StructRNA of type WindowManager has been removed

Tree generation failed

friggog commented 2 years ago

Closed by #70 - thanks @ThisIsADogHello for the quick fix after repro!