![Rahman Abber Tahir's picture Rahman Abber Tahir's picture](/sites/default/files/images/userpic_default.png)
Wed, 04/26/2017 - 20:14
Forums:
Can Some tell how to get ambient light values i.e Ka parameter in .mtl file from Quantity_NOC_CADETBLUE4 ??
There are differnt version of one color for example; GRAY1 GRAY2 .
Can someone guide how to get the meaning parameter from these??
Regards,
Abber
Wed, 04/26/2017 - 21:35
Quantity_NOC_CADETBLUE4 is a value from enumeration Quantity_NameOfColor.
You can create Quantity_Color from it and fetch Red(), Green() and Blue() values.
Thu, 04/27/2017 - 14:02
Hi Kirill,
Thanks for reply! I actually wanted the ambient light values used for visualization.
Which is "Ka" parameter in .mtl file because I'm trying to convert .step file to .obj with .mtl.
Regards,
Abber
Sat, 04/29/2017 - 12:25
If you are trying to copy material values from what you see in OCCT 3D viewer, then you should look onto class Graphic3d_MaterialAspect defining Ambient, Diffuse, Specular and Emissive components of OpenGL material. Prs3d_ShadingAspect within Prs3d_Drawer is usually responsible for material definition of presentable objects.
Wed, 05/03/2017 - 20:43
Thanks you very much for reply, can you please give an example code how to get the shading aspect of the currently displayed object. :)
Regards,
Abber