Community
VRED Forum
Welcome to Autodesk’s VRED Forums. Share your knowledge, ask questions, and explore popular VRED topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Thicker LineGeometries in OpenGL AND Raytracing

6 REPLIES 6
SOLVED
Reply
Message 1 of 7
marc.winter2
474 Views, 6 Replies

Thicker LineGeometries in OpenGL AND Raytracing

Hi,

 

Cloned clippingPlaneContours with SimpleMaterial and LineChunk are reasonable not visible in Raytracing.

If I put a UPlasticMaterial on the Line, it is quite thin but visible.

I only found the "Line Chrome"-Material to change the width in the Material.

"The Line Chrome Material is a special variant of the chrome materials for line geometries."

 

Is there something like "Line Plastic"-Material? Chrome is not what i need here 😞

Or how to get thicker Lines in Raytracing and OpenGL?

 

Thanks

Best regards,

Marc

6 REPLIES 6
Message 2 of 7

In raytracing when you apply a plastic material to the clipping contour you can control the thickness of the tubes by going to the material settings under Raytracing and changing the Line Tube Radius.

Sadly I don´t know a solution for OpenGL for the cloned lines.



Michael Nikelsky
Sr. Principal Engineer
Message 3 of 7

Thanks Michael,
that gets me a little bit further. So I have to handle it different for OpenGL and Raytracing.
But how can i change the "Line Tube Radius" scriptwise?
I cant find it in the NodeEditor.
Message 4 of 7

The variable is in the colorComponentData:

mat = findMaterial("PlasticMaterial")
cd = mat.fields().getFieldContainer("colorComponentData")
print( vrFieldAccess(cd).getReal32("tubeRadius"))


Michael Nikelsky
Sr. Principal Engineer
Message 5 of 7

Thanks a lot. There is only one problem left.
A visible change to the tubeRadius only happens after I reopen the material editor or manually hide and show the contour. I tried all the updateMethods of APIv1 ive found....
Message 6 of 7

That is the usually issue that you need to trigger a change on the material if you change something in the component (something that should be addressed with the upcoming python V2 API):

 

mat = findMaterial("PlasticMaterial")
cd = mat.fields().getFieldContainer("colorComponentData")
vrFieldAccess(cd).setReal32("tubeRadius", 20.0)
mat.fields().setInt32("flags", mat.fields().getInt32("flags2"))

 



Michael Nikelsky
Sr. Principal Engineer
Message 7 of 7

thx
mat.fields().setUInt32('flags', mat.fields().getUInt32('flags'))
works like a charme

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

Post to forums  

Autodesk Design & Make Report