0

I am attempting to use a custom attribute 'rand', generated via the Attribute Randomize node, to drive the Seed value for a Random Float node:

Screenshot of sample node setup

I have been unable to find any nodes/combination of nodes that will allow me to use the 'rand' integer assigned to each point to drive the Seed value. I would like to use 'rand' to drive multiple different Random Float nodes (with different ranges) throughout the node chain. Each time a Random Float node is encountered, a different random float should be generated for each point.

Any advice on whether or not this is possible, and how, would be appreciated.

Thanks!

SlickRed
  • 951
  • 1
  • 5
  • 14
  • Hello, why can't you directly use the rand attribute ? it's already randomized for each point and you can control the min, max, and seed the same way – Gorgious Aug 22 '21 at 20:02
  • Hi Gorgious. Thanks for your comment. This is actually part of a larger issue I'm trying to solve.

    I currently have a geometry tree for creating buildings. I would like to scatter a series of procedurally generated buildings across a plane (using a separate geometry node tree).

    I could create a collection, and create a bunch of buildings by using different settings for each building (height, width, etc.). However I'd prefer to generate these values procedurally, using a random seed for each point distributed across the plane. (Out of characters, can't expand further).

    – SlickRed Aug 22 '21 at 20:48
  • Maybe it's easier to ask this - how would I use my custom 'rand' attribute to drive any seed input on any node? (It doesn't necessarily have to be the Random Float node). – SlickRed Aug 22 '21 at 20:54
  • Yeah I think I understand your motivation, unfortunately it's not currently possible to have a different seed for each point using this method. The seed input of these nodes is valid for the whole tree and it can only be set to a single value per tree – Gorgious Aug 23 '21 at 06:42
  • Understood, thanks anyway. My other thought is to somehow compare the location of each point to the location of an empty object at the world origin, and thereby produce a different float for each point which could be used to drive a setting (such as building height). I'm unsure how to do this however, so I'll open a new question. Thanks for your input Gorgious. – SlickRed Aug 23 '21 at 13:24
  • No problem :) Maybe this will help, this sounds familiar : https://blender.stackexchange.com/a/221052/86891 – Gorgious Aug 23 '21 at 14:44

1 Answers1

1

This is now possible using the Random Value node to create random floats, integers, vectors, etc.

SlickRed
  • 951
  • 1
  • 5
  • 14