Allow alpha control for gl.DrawUnitShape

Allow alpha control for gl.DrawUnitShape

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

Post Reply
aeonios
Posts: 202
Joined: 03 Feb 2015, 14:27

Allow alpha control for gl.DrawUnitShape

Post by aeonios »

Currently the DrawUnits/FeaturesPostDeferred callins are only enabled if forward rendering is disabled, which basically never happens. However these functions are the only non-ugly-hack way of drawing unit/feature "ghosts" if deferred rendering is enabled, so why aren't they enabled by default when deferred rendering is enabled?

Ok it turns out the interface to gl.DrawUnitShape just changed without me knowing it. However while it's possible to specify that a unit be drawn with translucency it's no longer possible to specify the opacity (which used to be possible with gl.Color). If you set it to use raw rendering then gl.Color sort of works but it overrides the unit's texture entirely which is typically not what you want.
Post Reply

Return to “Engine”

cron