diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2009-03-18 00:44:58 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2009-03-18 00:44:58 +0300 |
commit | d52400bfbd2a7e4d09b5a71bc461a554d232af15 (patch) | |
tree | 08815f065fc90aac0ae62ae5f3a89d20e19399e6 /source/blender/editors/space_view3d/view3d_view.c | |
parent | 1ac0d54fea831c485e8e27e8bfa887e15beb58de (diff) | |
parent | 28f6d223d079b1e5cb67e3fc22fb7f818deb8dcb (diff) |
2.50: svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r18677:19317
Notes:
* Sequence transform strip uses G.scene global, this is commented
out now, should be fixed.
* Etch-a-ton code was most difficult to merge. The files already in
2.5 got merged, but no new files were added. Calls to these files
are commented out with "XXX etch-a-ton". editarmature.c and
transform_snap.c were complex to merge. Martin, please check?
* Game engine compiles and links again here for scons/make/cmake
(player still fails to link).
Diffstat (limited to 'source/blender/editors/space_view3d/view3d_view.c')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_view.c | 37 |
1 files changed, 33 insertions, 4 deletions
diff --git a/source/blender/editors/space_view3d/view3d_view.c b/source/blender/editors/space_view3d/view3d_view.c index b1bd39a66da..072aab55ed4 100644 --- a/source/blender/editors/space_view3d/view3d_view.c +++ b/source/blender/editors/space_view3d/view3d_view.c @@ -71,6 +71,9 @@ #include "ED_screen.h" #include "ED_view3d.h" +// XXX etch-a-ton #include "BIF_sketch.h" +// XXX etch-a-ton #include "BDR_sketch.h" + #include "UI_interface.h" #include "UI_resources.h" #include "UI_view2d.h" @@ -802,7 +805,28 @@ void project_float_noclip(ARegion *ar, float *vec, float *adr) } } - +int get_view3d_ortho(View3D *v3d, RegionView3D *rv3d) +{ + Camera *cam; + + if(rv3d->persp==V3D_CAMOB) { + if(v3d->camera && v3d->camera->type==OB_CAMERA) { + cam= v3d->camera->data; + + if(cam && cam->type==CAM_ORTHO) + return 1; + else + return 0; + } + else + return 0; + } + + if(rv3d->persp==V3D_ORTHO) + return 1; + + return 0; +} /* also exposed in previewrender.c */ int get_view3d_viewplane(View3D *v3d, RegionView3D *rv3d, int winxi, int winyi, rctf *viewplane, float *clipsta, float *clipend, float *pixsize) @@ -1120,8 +1144,13 @@ short view3d_opengl_select(ViewContext *vc, unsigned int *buffer, unsigned int b if(vc->obedit && vc->obedit->type==OB_MBALL) { draw_object(scene, ar, v3d, BASACT, DRAW_PICKING|DRAW_CONSTCOLOR); } - else if ((vc->obedit && vc->obedit->type==OB_ARMATURE)) { - draw_object(scene, ar, v3d, BASACT, DRAW_PICKING|DRAW_CONSTCOLOR); + else if((vc->obedit && vc->obedit->type==OB_ARMATURE)) { + /* XXX etch-a-ton if(BIF_fullSketchMode()) { + BDR_drawSketchNames(); + } + else*/ { + draw_object(scene, ar, v3d, BASACT, DRAW_PICKING|DRAW_CONSTCOLOR); + } } else { Base *base; @@ -1236,7 +1265,7 @@ static void initlocalview(Scene *scene, ScrArea *sa) locallay= free_localbit(); if(locallay==0) { - printf("Sorry, no more than 8 localviews\n"); // XXX error + printf("Sorry, no more than 8 localviews\n"); // XXX error ok= 0; } else { |