GLC_lib & GLC_Player Forums
http://www.forum.glc-lib.net/

error rendering selection
http://www.forum.glc-lib.net/viewtopic.php?f=14&t=977
Page 1 of 1

Author:  csell [ Sat Feb 18, 2017 12:21 pm ]
Post subject:  error rendering selection

Hello,

I am displaying a model with GLC_Viewport::backgroundColor set to a color of my liking. I also have set

GLC_SelectionMaterial::setUseSelectionMaterial(false);

now, when I select an area with transaprency (say, the window of a car), the non-covered area is painted in black. If I turn selection material on, it is completely painted in the selection color, which is also not ideal.

as a worklaround, I have commented out line 294 in glc_geometry.cpp:

//m_IsSelected= renderProperties.isSelected();

with that, everything displays ok for me, but since it is a uninformed hack I suppose it breaks elsewhere (most likely selection coloring will not work at all, wich is ok for me)

regards,
Chris

Author:  csell [ Sat Feb 18, 2017 1:23 pm ]
Post subject:  Re: error rendering selection

as an amendment, I have changed the commented-out line to

m_IsSelected= renderProperties.isSelected() && GLC_SelectionMaterial::isUseSelectionMaterial();

(with new function GLC_SelectionMaterial::isUseSelectionMaterial()). That way, selection works as previously if material is enabled.
Chris

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/