PLY and STL files rendering differences with ViewCaptureToFile

Hi there,

I am saving some views using ViewCaptureToFile.

When I run the script with a PLY file the export file (a png) looks darker and difficult to read whereas when I run it with an STL file the export file is easier to understand and brighter.

How could I make the exports from the PLY files look like the ones from the STL files?

Thank you in advance!
Hans Paul

@Helvetosaur any idea here?

Not really - just to clarify, you are first importing a .ply or .stl and then doing a ViewCaptureToFile (png) in Rhino? Are you sure the imported meshes do not have a color/texture associated with them or something else that could influence their display/render color? What display mode are you using to do the screen captures?

I am using “Rendered”.
How could I adjust brigthness using the script?

Are there materials or textures attached to the objects you’re importing?
(select the object, check the properties panel under the material tab)

CaptureCapture1Capture2

nope

Hello - what happens if you make that material color white?

-Pascal

The result is too bright

Hm… you can try RebuildMesh and see if that cleans up… but before you do, what it you assign the default material to the object, is it still bright?

-Pascal

I found a way to do it manually:
I need to go to the object properties and change the “Display Color” --> “By layer”.

How can I do it with a script?

Thank you

Why you want a script for it? Select all objects and change at once the display color to „by layer“

@tim.stark I need to use a script to work on several files
@Helvetosaur @pascal any hint?

Hello - if the idea is to select everything and make it all display color by layer then

! _SelAll -Properties _Object _Color _Layer _EnterEnd

Does that do it?

-Pascal

Hi,

I’m also working with hansalbi and above didn’t work out. However I found out that Rendering option Gamma correction 2.2 does the trick. When I click Render button and subsequent Render window Gamma correction to 2.2 will work for me manually for this work.

How to set the Gamma correction via rhinoscript?

cheers,

Sara

@sarasikularathne @hansalbi
What I don’t understand is this: If the mesh objects - no matter what their source - have the same object and/or layer color, the same render material and are viewed under the exact same display mode and lighting, they should have a very similar appearance. I would be focusing on the difference between the imported objects in this regard to find a viable solution to your problem.

@Helvetosaur

Thanks for the quick replies on this matter. We really appreciate your efforts.

Yes our understanding is similar but Rhino seems to apply gamma settings differently for ply and stl. Do you know a setting which I could set to make the both same?

thanks,

Sara

Hello - can you please post examples, or send to tech@mcneel.com if the files are confidential?

thanks,

-Pascal

Hello Pascal - I sent an email