Community
Bifrost Forum
Welcome to the Bifrost Forum. This is the place for artists using Bifrost to ask and answer questions, browse popular topics, and share knowledge about creating effects procedurally using Bifrost. You can also visit the Bifrost Community on AREA to download an array of ready-to-use graphs, read Bifrost news and updates, and find the latest tutorials.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

share my first compound, number to string with decimal and round!

1 REPLY 1
Reply
Message 1 of 2
g2m.agent
300 Views, 1 Reply

share my first compound, number to string with decimal and round!

Finally! I have completed my first compound! It's a bit rough, and maybe it's not very efficient, but it works.

It's basically similar to the Python round() function, except that it outputs a string:

 

0 => "0.00"
15.5 => "15.50"
-0.3876 => "-0.39"

 

number: plugin some number.
has_decimal: decide how many decimal places to keep. 0: do not keep decimals; 1: keep one decimal place; 2: keep two decimal places. and so on.
is_round: whether to round.

 

I hope that in the future Bifrost's round_to_nearest and number_to_string will replace this compound because these two nodes should be handling these basic functions.

 

1 REPLY 1
Message 2 of 2

I have to study this one. There is a lot more goin on than i tought.

Thanks for sharing!

----------------------------------------------------------------
https://linktr.ee/cg_oglu

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report