Code review comment for lp://qastaging/~unity-team/unity/new-dash-blending

Revision history for this message
Robert Carr (robertcarr) wrote :

Hi Tim.

The IfDefs are intentional, and not related to Nux. The flow is so that on OpenGL ES2 when we always have GLSL we can avoid having to check at runtime if we are using the GLSL code path. The ifdefs could of course be removed, with the second case gone.

Not sure exactly how you want the drawing code extracted either. If you mean for example, lines 61-83 should be in a function because something similar is used elsewhere (247-271), I suppose that could be done. If we want to introduce three functions which are just, if (GLSL) Blend else DrawTexture using bla method, it should probably be in Nux instead. Jay?

The real problem is that the same window rendering code is replicated across various views, panel, etc...it's not purely a matter of copy paste to solve this at the moment though because of DrawContent, and some coupling with drawing and internal state (like in PanelView) so it doesn't seem like an appropriate time to try and fix that.

« Back to merge proposal