Page MenuHome

Replacing UI_view2d_scrollsers_draw() to immedaite mode
ClosedPublic

Authored by Benjamin Summerton (define-private-public) on Nov 18 2016, 4:28 AM.

Diff Detail

Repository
rB Blender
Branch
imm.view2d.c.UI_view2d_scrollers_draw
Build Status
Buildable 297
Build 297: arc lint + arc unit

Event Timeline

Benjamin Summerton (define-private-public) retitled this revision from to Replacing UI_view2d_scrollsers_draw() to immedaite mode.Nov 18 2016, 4:28 AM
  • Horizontal scrolbars now use immedaite mode
  • vertical scrollbars now use immediate mode

Please review this. Please give me a response for the comment at line 1765.

source/blender/editors/interface/view2d.c
1811–1812

This seems a little odd to me that we would draw the scrollbars if and only if the alpha channel is fully visible. Shouldn't it be col[3] != 0? Or do we want to leave it like this.

Same goes for line 1873

Would be better to get TH_BACK only once in this function.

source/blender/editors/interface/view2d.c
1811–1812

From the comment above this clears a rect behind the scrollers. If not opaque it lets the existing pixels show through.

source/blender/editors/interface/view2d.c
1779–1781

I recommend getting rid of these. See below...

1813–1814

unsigned pos = add_attrib(immVertexFormat(), "pos" ...

1919–1920

same here

  • Merge branch 'blender2.8' into imm.view2d.c.UI_view2d_scrollers_draw
  • Merge branch 'blender2.8' into imm.view2d.c.UI_view2d_scrollers_draw
  • small cleanup
Mike Erwin (merwin) accepted this revision.
This revision is now accepted and ready to land.Nov 21 2016, 7:03 PM
Anthony Edlin (krash) accepted this revision.

Built and tested, seems fine.

landed in blender2.8