fb_accel: add accelerated framebuffer for Apollo graphic chips

Origin commit data
------------------
Branch: ni/coolstream
Commit: 6ff9ff695b
Author: Michael Liebmann <tuxcode.bbg@gmail.com>
Date: 2017-02-07 (Tue, 07 Feb 2017)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Michael Liebmann
2017-02-07 17:18:01 +01:00
parent 7d945c2d59
commit 6aef723484
4 changed files with 276 additions and 0 deletions

View File

@@ -34,9 +34,11 @@
#endif
#if HAVE_COOL_HARDWARE
#ifndef BOXMODEL_APOLLO
/* not needed -- if you don't want acceleration, don't call CFbAccel ;) */
#define USE_NEVIS_GXA 1
#endif
#endif
class CFbAccel
: public CFrameBuffer
@@ -113,4 +115,23 @@ class CFbAccelCSNevis
void setupGXA(void);
};
class CFbAccelCSApollo
: public CFbAccel
{
private:
fb_pixel_t *backbuffer;
public:
CFbAccelCSApollo();
// ~CFbAccelCSApollo();
int setMode(unsigned int xRes, unsigned int yRes, unsigned int bpp);
void paintHLineRelInternal(int x, int dx, int y, const fb_pixel_t col);
void paintBoxRel(const int x, const int y, const int dx, const int dy, const fb_pixel_t col, int radius = 0, int type = CORNER_ALL);
void blit2FB(void *fbbuff, uint32_t width, uint32_t height, uint32_t xoff, uint32_t yoff, uint32_t xp = 0, uint32_t yp = 0, bool transp = false);
void blitBox2FB(const fb_pixel_t* boxBuf, uint32_t width, uint32_t height, uint32_t xoff, uint32_t yoff);
void setBlendMode(uint8_t);
void setBlendLevel(int);
};
#endif