Changeset View
Changeset View
Standalone View
Standalone View
src/server/buffer_interface.cpp
Show First 20 Lines • Show All 218 Lines • ▼ Show 20 Line(s) | |||||
219 | 219 | | |||
220 | QImage::Format BufferInterface::Private::format() const | 220 | QImage::Format BufferInterface::Private::format() const | ||
221 | { | 221 | { | ||
222 | if (!shmBuffer) { | 222 | if (!shmBuffer) { | ||
223 | return QImage::Format_Invalid; | 223 | return QImage::Format_Invalid; | ||
224 | } | 224 | } | ||
225 | switch (wl_shm_buffer_get_format(shmBuffer)) { | 225 | switch (wl_shm_buffer_get_format(shmBuffer)) { | ||
226 | case WL_SHM_FORMAT_ARGB8888: | 226 | case WL_SHM_FORMAT_ARGB8888: | ||
227 | return QImage::Format_ARGB32; | 227 | return QImage::Format_ARGB32_Premultiplied; | ||
228 | case WL_SHM_FORMAT_XRGB8888: | 228 | case WL_SHM_FORMAT_XRGB8888: | ||
229 | return QImage::Format_RGB32; | 229 | return QImage::Format_RGB32; | ||
230 | default: | 230 | default: | ||
231 | return QImage::Format_Invalid; | 231 | return QImage::Format_Invalid; | ||
232 | } | 232 | } | ||
233 | } | 233 | } | ||
234 | 234 | | |||
235 | QImage BufferInterface::data() | 235 | QImage BufferInterface::data() | ||
▲ Show 20 Lines • Show All 68 Lines • Show Last 20 Lines |