Modulo Different in 4.2.2

In Blender 4.2.2. the Math Node has "truncated modulo" and "floored modulo". What is the different between the 2 and which would be the right one for the exercise? When I select truncated modulo and use a value of 2 the gondolas appear at every 2nd point on the circle, but without using the node, the gondolas appear at each point. Is the modulo node still required in 4.2.2?
1 love
Reply
  • Martin Bergwerf replied

    Hi aaaronstarlin ,

    Yes, the Modulo is still needed.

    The difference is, that the result gets either 'Floored' or 'Truncated'. This only makes a difference if the result of the Modulo is negative.

    For instance: -2.71828...Truncated is -2 (get rid of everything after the decimal point), while -2.71828... Floored is -3 (the highest integer smaller than, or equal to).

    The Modulo itself still works in the exact same way and in this case, the result is always an Integer anyway, so it doesn't matter which one you use.

    2 loves
  • hapit replied

    I searched for it almost at the same time.

    To add additional context: I found the Chat, where the feature was implemented. There is a picture which illustrates the difference very good.
    https://projects.blender.org/blender/blender/pulls/110728Β 

    Truncated is symetrical around zero and floored is always "left".

    • πŸ‘πŸ‘
    • πŸ‘πŸΌNice!
    2 loves