Page MenuHome

DesignTask: Add Drawing Of Image/UV Editor to the Draw Manager
Closed, ResolvedPublicTO DO

Description

Investigate how we can add drawing of other views into the draw manager. The technical cases we have are:

  • UV Editor already uses the draw_cache of the draw manager for the stretching overlay.
  • Future Migration to other GLs.
  • Support for GPU selection.
  • Image/UV editor also has overlays.
  • Realtime Baking with unwrapping

This design will go over the how and impact of such a change.

  • The draw manager should be able to create a drawing and select loop based on the Context SpaceLink.
  • Current Draw loop is specific 3d. actually only v3d and ar3d are 3d specific parameters. The idea is to have a specific 2d drawing loop DRW_draw_render_loop_2d_ex in the draw manager that is more generic. The entry point will still be DRW_draw_view.

Matrices

The draw manager uses multiple matrices for specific part of the geometry transform. Most of the view2d drawing isn't using any matrices. There is one matrix that is generated from UI_view2d_view_to_region_m4 used by the gizmo code. One of the requests we have is to be able to rotate the image. This can be handled by the viewmat.

UI Changes
Using the new cursor in the Image/UV editor

Event Timeline

Jeroen Bakker (jbakker) lowered the priority of this task from 90 to Normal.Jul 23 2019, 5:17 PM
Jeroen Bakker (jbakker) created this task.
Jeroen Bakker (jbakker) renamed this task from [WIP] DesignTask: Add Drawing Of Image/UV Editor to the Draw Manager to DesignTask: Add Drawing Of Image/UV Editor to the Draw Manager.Aug 25 2020, 8:56 PM
Jeroen Bakker (jbakker) closed this task as Resolved.Sep 11 2020, 11:50 AM