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: 

How to control the accuracy of a float value?

1 REPLY 1
SOLVED
Reply
Message 1 of 2
g2m.agent
312 Views, 1 Reply

How to control the accuracy of a float value?

How to control the accuracy of a float value?
 
for example:
 
0.0355942
 
I only want to 4 decimal places
 
0.0356
 
what should I do?
 
for now, I can only convert this float to string, trimming string, then convert it back to float.
Labels (1)
1 REPLY 1
Message 2 of 2

You can multiply by 10000, round and then divide by 10000 again.

 

round.png

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

Post to forums