mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-11-30 17:05:35 -05:00
Flatten filament preview bitmaps to opaque RGB for native labels
This commit is contained in:
1 parent
78de3ad9cd
commit
206552674b
7 files changed
+69
-11
No files matched your search
@@ -294,10 +294,10 @@ struct BitmapDC {
|
||||
wxMemoryDC dc;
|
||||
std::unique_ptr<wxGCDC> graphics;
|
||||
|
||||
BitmapDC(const wxSize& size, bool alpha) : bitmap(size){
|
||||
#ifdef __WXOSX__
|
||||
bitmap.UseAlpha();
|
||||
#endif
|
||||
// All previews are opaque after checkerboard compositing. RGB storage also
|
||||
// prevents Windows GDI labels from leaving invalid alpha bytes for menus.
|
||||
BitmapDC(const wxSize& size, bool alpha) : bitmap(size, 24)
|
||||
{
|
||||
dc.SelectObject(bitmap);
|
||||
// Don't set white background - let the color patterns fill the entire area
|
||||
dc.SetPen(*wxTRANSPARENT_PEN);
|
||||
|
||||
Reference in new issue
Block a user