Hello everyone
unRegisterRedrawViewsCallback li
fn li =(
gw.setColor #fill (color 0 255 255)
gw.setColor #line (color 0 255 0)
gw.hPolyline #([300,50,16], [300,200,8], [450,250,4]) true
--
gw.hPolygon #([200,100,16], [380,100,8], [250,200,4]) \
#((color 255 255 0), (color 0 255 255), (color 0 255 0)) \
#([1.0,.5,0], [0.5,0.5,0], [0,0,0.5])
gw.setTransform(Matrix3 1)
gw.startTriangles()
gw.triangle #([0,0,0], [50,0,0], [50,50,0]) #((color 255 255 0), (color 0 255 255), (color 0 255 0))
gw.triangle #([0,0,0], [50,50,0], [0,50,0]) #((color 255 255 0), (color 0 255 255), (color 0 255 0))
gw.endTriangles()
-- Update the viewports
gw.enlargeUpdateRect #whole
gw.updateScreen()
)
registerRedrawViewsCallback li
In the above script the vertex color doesn’t work. As you can see I tried both hPolygon and triangle. Tested in 3dsmax 2018 and 2020 same result. Tested with dx, nitro, opegnl, software display driver same result. Also gw.setColor #fill (color 0 255 255) doesn’t work.
Only hpolyline seems to work at least is coherent with the line color I set.
I think they are corrupted functions, they get the color from a random state inside the engine.
Attached the output
Let me know if I miss something or there is a workaround.
Thanks
