mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2026-01-09 05:51:00 +00:00
Add helper to compare RedDrawable::Formats for copy compabible
Being copy compatible means the format are identical except that some bits in the source may be ignored in the destination.
This commit is contained in:
parent
5c2d9a3e32
commit
1efe358a05
@ -57,6 +57,10 @@ public:
|
||||
A1,
|
||||
};
|
||||
|
||||
static int format_copy_compatible(Format src, Format dest) {
|
||||
return src == dest || (src == ARGB32 && dest == RGB32);
|
||||
}
|
||||
|
||||
static int format_to_bpp(Format format) {
|
||||
if (format == RedDrawable::A1) {
|
||||
return 1;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user