How to apply 'Graphic3d_ArrayOfPolylines' colors without gradient

Hi All,

I have override the 'Compute' method of an AIS_PointCloud to show manage my own visualisation, i use the structs 'Graphic3d_ArrayOfPoints' and 'Graphic3d_ArrayOfPolylines' to show points and lines.

When i call SetVertexColor of Graphic3d_ArrayOfPolylines i get a gradient on color, it works very well however i would like to know how to remove the gradient, i want straight color between 2 vertex (even if i change my Graphic3d structures).

Any suggestion?

I attach a picture with the result i want.

Thanks in advance

Attachments: 
gkv311 n's picture

If you set different colors for neighbor points in a polyline - how would you expect these colors should be distributed across the polyline? If you want to assign colors for line segments - use Graphic3d_ArrayOfSegments instead or duplicate points in a polyline and assign the same color to point pairs.

Bonnaud Nathan's picture

Hi,

Yesterday, i try the dupplication of points of my polyline and it work well. Thank you !

Giovanni Bettega's picture

Sorry text written by error

Giovanni Bettega's picture

Please, could you attach a picture of what you don't want? This is what I would like tò have (if I understood well your initial.post)
Thank you
Giovanni