Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTon Roosendaal <ton@blender.org>2004-10-30 21:13:10 +0400
committerTon Roosendaal <ton@blender.org>2004-10-30 21:13:10 +0400
commit8aa1948c104b5a235908c3af7812dae6a668e311 (patch)
treeae8bd66bf365c7ccb59eca618ac927d12cc07b20 /source/blender/src/editmesh_mods.c
parente1fb446ce741c462a763b26ffba5cf572fb5de06 (diff)
AFAIK... last issue with new Z-culling selection.
Since the new menu system draws in backbuffer, the selectionbuffer then needs a refresh after. Solved by nicely signalling stuff.
Diffstat (limited to 'source/blender/src/editmesh_mods.c')
-rw-r--r--source/blender/src/editmesh_mods.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/source/blender/src/editmesh_mods.c b/source/blender/src/editmesh_mods.c
index 837aa625915..2bd8880ef18 100644
--- a/source/blender/src/editmesh_mods.c
+++ b/source/blender/src/editmesh_mods.c
@@ -87,8 +87,9 @@ editmesh_mods.c, UI level access, no geometry changes
#include "BDR_drawobject.h"
#include "BDR_editobject.h"
-#include "BSE_view.h"
+#include "BSE_drawview.h"
#include "BSE_edit.h"
+#include "BSE_view.h"
#include "IMB_imbuf.h"
@@ -103,16 +104,24 @@ editmesh_mods.c, UI level access, no geometry changes
int em_solidoffs=0, em_wireoffs=0, em_vertoffs; // set in drawobject.c ... for colorindices
+static void check_backbuf(void)
+{
+ if(G.vd->flag & V3D_NEEDBACKBUFDRAW) {
+ backdrawview3d(0);
+ }
+}
+
/* samples a single pixel (copied from vpaint) */
static unsigned int sample_backbuf(int x, int y)
{
unsigned int col;
if(x>=curarea->winx || y>=curarea->winy) return 0;
-
x+= curarea->winrct.xmin;
y+= curarea->winrct.ymin;
+ check_backbuf(); // actually not needed for apple
+
#ifdef __APPLE__
glReadBuffer(GL_AUX0);
#endif
@@ -141,6 +150,8 @@ static unsigned int *read_backbuf(short xmin, short ymin, short xmax, short ymax
if(yminc > ymaxc) return NULL;
buf= MEM_mallocN( (xmaxc-xminc+1)*(ymaxc-yminc+1)*sizeof(int), "sample rect");
+
+ check_backbuf(); // actually not needed for apple
#ifdef __APPLE__
glReadBuffer(GL_AUX0);