Build fix for SurfaceTest on non-gpu platforms

Unreviewed

git-svn-id: http://skia.googlecode.com/svn/trunk@8946 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
junov@chromium.org 2013-05-01 22:49:59 +00:00
Родитель da90474b5f
Коммит b516a41779
1 изменённых файлов: 3 добавлений и 1 удалений

Просмотреть файл

@ -147,6 +147,7 @@ static void TestSurfaceWritableAfterSnapshotRelease(skiatest::Reporter* reporter
canvas->clear(2); canvas->clear(2);
} }
#if SK_SUPPORT_GPU
static void TestGetTexture(skiatest::Reporter* reporter, static void TestGetTexture(skiatest::Reporter* reporter,
SurfaceType surfaceType, SurfaceType surfaceType,
GrContext* context) { GrContext* context) {
@ -162,6 +163,7 @@ static void TestGetTexture(skiatest::Reporter* reporter,
surface->notifyContentWillChange(SkSurface::kDiscard_ContentChangeMode); surface->notifyContentWillChange(SkSurface::kDiscard_ContentChangeMode);
REPORTER_ASSERT(reporter, image->getTexture() == texture); REPORTER_ASSERT(reporter, image->getTexture() == texture);
} }
#endif
static void TestSurfaceNoCanvas(skiatest::Reporter* reporter, static void TestSurfaceNoCanvas(skiatest::Reporter* reporter,
SurfaceType surfaceType, SurfaceType surfaceType,
@ -202,9 +204,9 @@ static void TestSurface(skiatest::Reporter* reporter, GrContextFactory* factory)
TestSurfaceWritableAfterSnapshotRelease(reporter, kPicture_SurfaceType, NULL); TestSurfaceWritableAfterSnapshotRelease(reporter, kPicture_SurfaceType, NULL);
TestSurfaceNoCanvas(reporter, kRaster_SurfaceType, NULL, SkSurface::kDiscard_ContentChangeMode); TestSurfaceNoCanvas(reporter, kRaster_SurfaceType, NULL, SkSurface::kDiscard_ContentChangeMode);
TestSurfaceNoCanvas(reporter, kRaster_SurfaceType, NULL, SkSurface::kRetain_ContentChangeMode); TestSurfaceNoCanvas(reporter, kRaster_SurfaceType, NULL, SkSurface::kRetain_ContentChangeMode);
#if SK_SUPPORT_GPU
TestGetTexture(reporter, kRaster_SurfaceType, NULL); TestGetTexture(reporter, kRaster_SurfaceType, NULL);
TestGetTexture(reporter, kPicture_SurfaceType, NULL); TestGetTexture(reporter, kPicture_SurfaceType, NULL);
#if SK_SUPPORT_GPU
if (NULL != factory) { if (NULL != factory) {
GrContext* context = factory->get(GrContextFactory::kNative_GLContextType); GrContext* context = factory->get(GrContextFactory::kNative_GLContextType);
TestSurfaceCopyOnWrite(reporter, kGpu_SurfaceType, context); TestSurfaceCopyOnWrite(reporter, kGpu_SurfaceType, context);