bmikiwer
-
Posts
3 -
Joined
-
Last visited
Content Type
Profiles
Forums
Blogs
Downloads
Articles
Gallery
Posts posted by bmikiwer
-
-
-
I'm trying to make sense of the 'Ns' values I get when exporting a model(.obj) from IronCAD.
11 Cylinders, Highlight spread from 0 - 100 (0, 10, 20, 30, ...) gets me a .mtl file with these 'Ns' values:
5, 21, 69, 149, 261, 405, 581, 789, 1029, 1301, 1605
I've read that the 'Ns' values usually are between 0 and 1000.
First I thought these values were exponential but I believe them to be quadratic.
Is there a mathematic function that will convert these values to linear values between 0 - 100 or 0 - 1000?
Example:
If a material get's a 'Ns' value of 681 how would I know how much Highlight Spread that material has?
Material file question (.obj export)
in General Discussion
Posted · Edited by bmikiwer
Thank you!
Just wanted to point out that in your "Else" statement, it should be:
Ns = sqrt(value-5) * 2.5;
if I'm not mistaken.
But it appears to be working perfectly. I did modify this a bit since I need the values between 0 and 1 and in reverse. This function is written in Python if anyone is wondering.
def ironNs(value):
----if value
--------ns = 1.0
----elif value > 1605.0:
--------ns = 0.0
----else:
--------ns = 1.0 - (sqrt(value - 5) * 0.025)
----return ns
Also, thank the developer!