40 size_t getWidth()
const;
41 size_t getHeight()
const;
43 Graphics::PixelFormat getFormat()
const;
45 bool getActive()
const;
47 void setActive(
bool b);
51 void setPalette(uint32_t* palette,
size_t nEntries);
53 uint32_t* getPalette()
const;
58 virtual void* getRawBuffer()
const;
63 virtual physical_uintptr_t getPhysicalPage(
size_t offset)
const;
65 size_t getMappingFlags()
const {
66 return m_MappingFlags;
68 void setMappingFlags(
size_t flags) {
69 m_MappingFlags = flags;
86 virtual Graphics::Buffer* createBuffer(
const void* srcData, Graphics::PixelFormat srcFormat,
87 size_t width,
size_t height, uint32_t* pPalette = 0);
107 void redraw(
size_t x = ~0UL,
size_t y = ~0UL,
size_t w = ~0UL,
size_t h = ~0UL,
108 bool bChild =
false);
115 virtual void blit(
Graphics::Buffer* pBuffer,
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
116 size_t width,
size_t height,
bool bLowestCall =
true);
121 virtual void draw(
void* pBuffer,
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
122 size_t width,
size_t height,
123 Graphics::PixelFormat format = Graphics::Bits32_Argb,
bool bLowestCall =
true);
126 virtual void rect(
size_t x,
size_t y,
size_t width,
size_t height, uint32_t colour,
127 Graphics::PixelFormat format = Graphics::Bits32_Argb,
bool bLowestCall =
true);
130 virtual void copy(
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
size_t w,
size_t h,
131 bool bLowestCall =
true);
134 virtual void line(
size_t x1,
size_t y1,
size_t x2,
size_t y2, uint32_t colour,
135 Graphics::PixelFormat format = Graphics::Bits32_Argb,
bool bLowestCall =
true);
138 void setPixel(
size_t x,
size_t y, uint32_t colour,
139 Graphics::PixelFormat format = Graphics::Bits32_Argb,
bool bLowestCall =
true);
147 void setXPos(
size_t x);
151 void setYPos(
size_t y);
155 void setWidth(
size_t w);
159 void setHeight(
size_t h);
163 void setFormat(Graphics::PixelFormat pf);
167 void setBytesPerPixel(
size_t b);
168 uint32_t getBytesPerPixel()
const;
172 void setBytesPerLine(
size_t b);
173 uint32_t getBytesPerLine()
const;
180 virtual void setFramebuffer(uintptr_t p);
184 void swSetPixel(
size_t x,
size_t y, uint32_t colour,
185 Graphics::PixelFormat format = Graphics::Bits32_Argb);
190 uintptr_t m_FramebufferBase;
202 virtual void draw(
Graphics::Buffer* pBuffer,
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
203 size_t width,
size_t height,
bool bLowestCall =
true);
205 void swBlit(
Graphics::Buffer* pBuffer,
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
206 size_t width,
size_t height);
208 void swRect(
size_t x,
size_t y,
size_t width,
size_t height, uint32_t colour,
209 Graphics::PixelFormat format);
211 void swCopy(
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
size_t w,
size_t h);
213 void swLine(
size_t x1,
size_t y1,
size_t x2,
size_t y2, uint32_t colour,
214 Graphics::PixelFormat format);
216 void swDraw(
void* pBuffer,
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
size_t width,
217 size_t height, Graphics::PixelFormat format = Graphics::Bits32_Argb,
218 bool bLowestCall =
true);
220 void swDraw(
Graphics::Buffer* pBuffer,
size_t srcx,
size_t srcy,
size_t destx,
size_t desty,
221 size_t width,
size_t height,
bool bLowestCall =
true);
223 Graphics::Buffer* swCreateBuffer(
const void* srcData, Graphics::PixelFormat srcFormat,
224 size_t width,
size_t height, uint32_t* pPalette);
229 virtual void hwRedraw(
size_t x = ~0UL,
size_t y = ~0UL,
size_t w = ~0UL,
size_t h = ~0UL);
232 size_t m_MappingFlags = 0;