diff options
author | Joshua Leung <aligorith@gmail.com> | 2009-11-11 11:12:54 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2009-11-11 11:12:54 +0300 |
commit | 1dfc7942d3f35cbb8bb0e94fec57828da0eb756c (patch) | |
tree | 4b3c51a8c36725c31de241ee8e81637d5b61d80f /source/blender/editors/gpencil/drawgpencil.c | |
parent | 7206437c7247040c7b3f00d7b76c715103282c4c (diff) |
Grease Pencil for Nodes Editor:
This commit restores Grease Pencil functionality for the Nodes Editor. Grease Pencil data is now stored at the NodeTree level, which means that annotations remain with the NodeTree they were made for.
Possible TODO's:
* In future, it may be worth investigating attaching Grease Pencil data to individual nodes, to allow annotations to stay attached to nodes as they are moved
* Include the settings for the 'active node' in a panel in the new NKEY region where the Grease Pencil buttons appear.
Diffstat (limited to 'source/blender/editors/gpencil/drawgpencil.c')
-rw-r--r-- | source/blender/editors/gpencil/drawgpencil.c | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/source/blender/editors/gpencil/drawgpencil.c b/source/blender/editors/gpencil/drawgpencil.c index 9a0187dde04..6651c7745bb 100644 --- a/source/blender/editors/gpencil/drawgpencil.c +++ b/source/blender/editors/gpencil/drawgpencil.c @@ -765,31 +765,4 @@ void draw_gpencil_3dview (bContext *C, short only3d) draw_gpencil_3dview_ext(scene, ar, only3d); } -/* draw grease-pencil sketches to opengl render window assuming that matrices are already set correctly */ -// XXX porting note, ogl render will probably be a window with one 3d region -void draw_gpencil_oglrender (bContext *C) -{ - ScrArea *sa= CTX_wm_area(C); - View3D *v3d= (View3D *)sa->spacedata.first; - ARegion *ar= CTX_wm_region(C); - Scene *scene= CTX_data_scene(C); - bGPdata *gpd; - - /* assume gpencil data comes from v3d */ - if (v3d == NULL) return; - gpd= gpencil_data_get_active(C); - if (gpd == NULL) return; - - /* pass 1: draw 3d-strokes ------------ > */ - gp_draw_data(gpd, 0, 0, ar->winx, ar->winy, CFRA, (GP_DRAWDATA_NOSTATUS|GP_DRAWDATA_ONLY3D)); - - /* pass 2: draw 2d-strokes ------------ > */ - /* adjust view matrices */ - wmOrtho2(-0.375f, (float)(ar->winx)-0.375f, -0.375f, (float)(ar->winy)-0.375f); // XXX may not be correct anymore - glLoadIdentity(); - - /* draw it! */ - gp_draw_data(gpd, 0, 0, ar->winx, ar->winy, CFRA, GP_DRAWDATA_NOSTATUS); -} - /* ************************************************** */ |