From: reed@google.com Date: Thu, 24 Feb 2011 21:42:29 +0000 (+0000) Subject: fix bool bug so we can multisample now X-Git-Tag: accepted/tizen/5.0/unified/20181102.025319~18923 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a09368c9711e32257600e0f7deae2d6ba3fb5a76;p=platform%2Fupstream%2FlibSkiaSharp.git fix bool bug so we can multisample now git-svn-id: http://skia.googlecode.com/svn/trunk@851 2bbb7eff-a529-9590-31e7-b0007b416f81 --- diff --git a/gpu/src/GrGpuGL.cpp b/gpu/src/GrGpuGL.cpp index edcadb4..b30dd02 100644 --- a/gpu/src/GrGpuGL.cpp +++ b/gpu/src/GrGpuGL.cpp @@ -1554,7 +1554,7 @@ bool GrGpuGL::flushGLStateCommon(GrPrimitiveType type) { // only perform query if we know MSAA is supported. // calling on non-MSAA target caused a crash in one environment, // though I don't think it should. - if (!fAASamples[kHigh_AALevel]) { + if (fAASamples[kHigh_AALevel]) { GR_GL_GetIntegerv(GL_SAMPLE_BUFFERS, &msaa); } if (fCurrDrawState.fFlagBits & kAntialias_StateBit) { diff --git a/samplecode/SampleShapes.cpp b/samplecode/SampleShapes.cpp index 30ff3fd..a175af6 100644 --- a/samplecode/SampleShapes.cpp +++ b/samplecode/SampleShapes.cpp @@ -5,7 +5,7 @@ #include "SkStream.h" #include "SkView.h" -#define DO_AA false +#define DO_AA true #include "SkRectShape.h" #include "SkGroupShape.h" diff --git a/src/utils/mac/SkOSWindow_Mac.cpp b/src/utils/mac/SkOSWindow_Mac.cpp index e45a445..7716185 100644 --- a/src/utils/mac/SkOSWindow_Mac.cpp +++ b/src/utils/mac/SkOSWindow_Mac.cpp @@ -465,7 +465,7 @@ AGLContext create_gl(WindowRef wref, bool offscreen) AGL_STENCIL_SIZE, 8, AGL_SAMPLE_BUFFERS_ARB, 1, AGL_MULTISAMPLE, - AGL_SAMPLES_ARB, 2, + AGL_SAMPLES_ARB, 8, (offscreen ? AGL_OFFSCREEN : AGL_ACCELERATED), (offscreen ? AGL_NONE : AGL_DOUBLEBUFFER), AGL_NONE