aboutsummaryrefslogtreecommitdiffhomepage
path: root/example
diff options
context:
space:
mode:
authorGravatar kkinnunen <kkinnunen@nvidia.com>2016-01-18 01:18:34 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-01-18 01:18:35 -0800
commit973d92cf91b21013361209e8a5c0c4685728847f (patch)
treecfd62c01fc0a605bd2925c807c5fc00bb5ebf571 /example
parent3ca73360493ba71831c86c8c5f9c36187c0355ca (diff)
SampleApp: Remove SkWindow::setColorType
Remove SkWindow::setColorType, it is used wrong and inconsistently. The color type is actually property of window backbuffer, used when the window is painted with software. This is as opposed to a generic window property that would affect all operation. Similar to MSAA sample count for window GPU backbuffer, the bitmap backbuffer color type should be a parameter of "attach" or "create window" functions, should this property ever be added back. The apps use the call wrong, setting the type as kRGBA_8888 or kBGRRA_8888 without no apparent rationale. These color types are incorrect, as the raster surface can not work with these. Reorganize the SkWindow::resize, since no change in SkWindow backbuffer size does not neccessarily mean that SkView would not need the call. Do not show the sw backbuffer color type in SampleApp title, as it does not really provide any information. On small screens, kBGRA_8888_ColorType fills up the whole title. BUG=skia:4733 GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1595503002 Review URL: https://codereview.chromium.org/1595503002
Diffstat (limited to 'example')
-rw-r--r--example/HelloWorld.cpp1
1 files changed, 0 insertions, 1 deletions
diff --git a/example/HelloWorld.cpp b/example/HelloWorld.cpp
index c7c6bcd1dc..6833a33828 100644
--- a/example/HelloWorld.cpp
+++ b/example/HelloWorld.cpp
@@ -59,7 +59,6 @@ void HelloWorldWindow::setTitle() {
}
bool HelloWorldWindow::setUpBackend() {
- this->setColorType(kRGBA_8888_SkColorType);
this->setVisibleP(true);
this->setClipToBounds(false);