i’d like to distribute this green particle only on the white area of this procedurally created cycles mask. I need to find a way to link this cycles map to either a vertex or texture emplacement slot in the particle system. i need to automate this for an addon.
Could the solution be Non destructive. (= can still change parameters of the material afterward and it will influence the particles) edit* and other than baking maybe ?
→ if someone could find a process that is destructive but good enough for automation he’ll get 20$.
→ if someone can write me a code that is destructive that i can use that can automate this process for any terrain, (+explanations if needed) he’ll get 80$
→ if someone find a non-destructive solution he’ll get 100$
Okay. Good luck. I’ll only pay one solution (for now… If someone find a non-destructive one later i’ll consider it too.)
There is two topic for this question, one in the python support category, one in the Basic & interface category.
Unfortunately, there is no easy way to directly use shader data.
Apart from shader option, you might be able to detect appropriate faces via dot product of face normals and global Z axis, then combine them into vertex group and use as vgroup density guide for particles.
I am iterating through vertex normals, calculating dot product with Z axis and assigning weight data based on comparison between dot and some threshold. White circles are vertices with 1.0 weight
However there is a problem, that particle system still places particles on some faces where weight was set to 0 (like above nose of a monkey on attached pic)
Thanks for the answer. i’ll do some testing.
But about the main question. There’s really no way to use the node data ?
with cycles you can do so many dispersion maps easely. elevation, slopes, occlusion, pointiness… i want to harness cycles nodes power for particles distribution.
Plus Cycles is a rendering engine, not a data transformation tool. Terrain generation is not non-destructive anyway, so why seek non-destructive workflow? Just bake curvature and ambient occlusion to vertex colors or vertex weighs, and use that data to control how to spawn objects or particles.
…dude don’t spam the thread with offtopic questions
Oops. (deleted)
Terrain generation is not non-destructive anyway,
what about a noise texture + displacement ? what about non destructively re importing another model of the terrain witouth needing to remade the distribution maps from scratch ?
To give flexibility to my users. Adjusting slope/altitude/occlusion/pointiness masks on the fly from a node could be way more efficient and easy to use for a biome scattering tool.
Yeah, but Cycles is a rendering engine, not a data transformation tool. Blender really should have proper function nodes that can transform data like textures, vertex colors and weighs.
all the data needed is only but a simple b/w color information, is this so difficult to transmit to either the texture editor or vertex paintings editors ?
To the best of my knowledge: as the entire thing is a monolithic CUDA or OpenCL blob that reads data only one way… yes. Yes, it is. Only way you can get things out of Cycles is render it to an image.
Thanks. Now i know that im restricted to mesh data analysis distributing my particles, lot of work, i will need to find someone to work with me on that part then. The reward is still open. anyone who find a way to make a non destructive link. he’ll recieve 100$
I also believe that baking is pretty straight forward. And it isn’t difficult to automate.
You can even have a script to bake the texture into a vertex weight layer (thought particles can use image textures as well).
baking and uv unwrapping automatically any terrain what so ever ?
what about if the script that auto unwrap don’t do it correctly for 100% of cases ? what about if the baking process is taking too long ? what about if the terrain mesh is tool heavy for all of this ?
i don’t think that it is a reliable option but if you think it could work prove me wrong with a code and i’ll give you 80$
what are the steps to automate ?
terrain sellection
enter edit mode
enter top view
unwrap
optimize uv island in texture emplacement in another editor
after that there two possibilities, the vertex one ore texture creation one. i think that the texture creation one will be less complex
create new texture texture
adjust all parameters for particles blablabla
use texture based on image
set image on uv
Done. Like that ? Am i missing something ? Are you advicing me other kind’s of steps for unwrapping the terrain ? do i need to enter edit mode ?
In the case of particles, you’ll probably don’t need a very high resolution. Also you just need the color, so there’s no usage of the expensive raytracing, and you’ll be fine baking with just 1 sample.
The only problem i can imagine, is about when to update the texture (in case of changes in the material).