HD1 compat #2; pu/fb-setmode

Origin commit data
------------------
Commit: 894233a9db
Author: Michael Liebmann <tuxcode.bbg@gmail.com>
Date: 2017-05-04 (Thu, 04 May 2017)
This commit is contained in:
Michael Liebmann
2017-05-04 02:16:06 +02:00
committed by vanhofen
parent 15e77032a8
commit e768096b64
4 changed files with 20 additions and 2 deletions

View File

@@ -86,8 +86,11 @@ class CFbAccelCSHDx
protected: protected:
OpenThreads::Mutex mutex; OpenThreads::Mutex mutex;
/* Function temporarily disabled for HD1 */
#if BOXMODEL_CS_HD2
int fbCopy(uint32_t *mem_p, int width, int height, int dst_x, int dst_y, int src_x, int src_y, int mode); int fbCopy(uint32_t *mem_p, int width, int height, int dst_x, int dst_y, int src_x, int src_y, int mode);
int fbFill(int sx, int sy, int width, int height, fb_pixel_t color, int mode=0); int fbFill(int sx, int sy, int width, int height, fb_pixel_t color, int mode=0);
#endif
public: public:
CFbAccelCSHDx(); CFbAccelCSHDx();
@@ -124,7 +127,8 @@ class CFbAccelCSHD1
inline void paintHLineRel(int x, int dx, int y, const fb_pixel_t col) { paintLine(x, y, x+dx, y, col); }; inline void paintHLineRel(int x, int dx, int y, const fb_pixel_t col) { paintLine(x, y, x+dx, y, col); };
inline void paintVLineRel(int x, int y, int dy, const fb_pixel_t col) { paintLine(x, y, x, y+dy, col); }; inline void paintVLineRel(int x, int y, int dy, const fb_pixel_t col) { paintLine(x, y, x, y+dy, 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 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 fbCopyArea(uint32_t width, uint32_t height, uint32_t dst_x, uint32_t dst_y, uint32_t src_x, uint32_t src_y); /* Function temporarily disabled for HD1 */
// void fbCopyArea(uint32_t width, uint32_t height, uint32_t dst_x, uint32_t dst_y, uint32_t src_x, uint32_t src_y);
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, uint32_t unscaled_w = 0, uint32_t unscaled_h = 0); //NI 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, uint32_t unscaled_w = 0, uint32_t unscaled_h = 0); //NI
void blitBox2FB(const fb_pixel_t* boxBuf, uint32_t width, uint32_t height, uint32_t xoff, uint32_t yoff); void blitBox2FB(const fb_pixel_t* boxBuf, uint32_t width, uint32_t height, uint32_t xoff, uint32_t yoff);
void waitForIdle(const char *func = NULL); void waitForIdle(const char *func = NULL);

View File

@@ -262,6 +262,8 @@ void CFbAccelCSHD1::paintBoxRel(const int x, const int y, const int dx, const in
checkFbArea(x, y, dx, dy, false); checkFbArea(x, y, dx, dy, false);
} }
/* Function temporarily disabled for HD1 */
#if 0
void CFbAccelCSHD1::fbCopyArea(uint32_t width, uint32_t height, uint32_t dst_x, uint32_t dst_y, uint32_t src_x, uint32_t src_y) void CFbAccelCSHD1::fbCopyArea(uint32_t width, uint32_t height, uint32_t dst_x, uint32_t dst_y, uint32_t src_x, uint32_t src_y)
{ {
if ((width == 0) || (height == 0)) if ((width == 0) || (height == 0))
@@ -280,6 +282,7 @@ void CFbAccelCSHD1::fbCopyArea(uint32_t width, uint32_t height, uint32_t dst_x,
fbCopy(NULL, w_, h_, dst_x, dst_y, src_x, src_y_, mode); fbCopy(NULL, w_, h_, dst_x, dst_y, src_x, src_y_, mode);
// printf("\033[31m>>>>\033[0m%s hw blit w: %d, h: %d, dst_x: %d, dst_y: %d, src_x: %d, src_y: %d\n", __func_ext__, w_, h_, dst_x, dst_y, src_x, src_y); // printf("\033[31m>>>>\033[0m%s hw blit w: %d, h: %d, dst_x: %d, dst_y: %d, src_x: %d, src_y: %d\n", __func_ext__, w_, h_, dst_x, dst_y, src_x, src_y);
} }
#endif
void CFbAccelCSHD1::blit2FB(void *fbbuff, uint32_t width, uint32_t height, uint32_t xoff, uint32_t yoff, uint32_t xp, uint32_t yp, bool transp, uint32_t unscaled_w, uint32_t unscaled_h) //NI void CFbAccelCSHD1::blit2FB(void *fbbuff, uint32_t width, uint32_t height, uint32_t xoff, uint32_t yoff, uint32_t xp, uint32_t yp, bool transp, uint32_t unscaled_w, uint32_t unscaled_h) //NI
{ {
@@ -386,8 +389,11 @@ int CFbAccelCSHD1::setMode(unsigned int, unsigned int, unsigned int)
bpp = screeninfo.bits_per_pixel; bpp = screeninfo.bits_per_pixel;
printf(LOGTAG "%dx%dx%d line length %d. using %s graphics accelerator.\n", xRes, yRes, bpp, stride, _fix.id); printf(LOGTAG "%dx%dx%d line length %d. using %s graphics accelerator.\n", xRes, yRes, bpp, stride, _fix.id);
/* Function temporarily disabled for HD1 */
#if 0
if (videoDecoder != NULL) if (videoDecoder != NULL)
videoDecoder->updateOsdScreenInfo(); videoDecoder->updateOsdScreenInfo();
#endif
int needmem = stride * yRes * 2; int needmem = stride * yRes * 2;
if (available >= needmem) if (available >= needmem)

View File

@@ -36,6 +36,8 @@ CFbAccelCSHDx::~CFbAccelCSHDx()
} }
*/ */
/* Function temporarily disabled for HD1 */
#if BOXMODEL_CS_HD2
int CFbAccelCSHDx::fbCopy(uint32_t *mem_p, int width, int height, int CFbAccelCSHDx::fbCopy(uint32_t *mem_p, int width, int height,
int dst_x, int dst_y, int src_x, int src_y, int mode) int dst_x, int dst_y, int src_x, int src_y, int mode)
{ {
@@ -58,7 +60,10 @@ int CFbAccelCSHDx::fbCopy(uint32_t *mem_p, int width, int height,
mutex.unlock(); mutex.unlock();
return ret; return ret;
} }
#endif
/* Function temporarily disabled for HD1 */
#if BOXMODEL_CS_HD2
int CFbAccelCSHDx::fbFill(int sx, int sy, int width, int height, fb_pixel_t color, int mode/*=0*/) int CFbAccelCSHDx::fbFill(int sx, int sy, int width, int height, fb_pixel_t color, int mode/*=0*/)
{ {
if (videoDecoder == NULL) { if (videoDecoder == NULL) {
@@ -74,6 +79,7 @@ int CFbAccelCSHDx::fbFill(int sx, int sy, int width, int height, fb_pixel_t colo
mutex.unlock(); mutex.unlock();
return ret; return ret;
} }
#endif
#if 0 #if 0
/* TODO: Run this functions with hardware acceleration */ /* TODO: Run this functions with hardware acceleration */

View File

@@ -560,7 +560,9 @@ void CStreamInfo2::paint_techinfo(int xpos, int ypos)
snprintf(buf, sizeof(buf), "%dx%d", xres, yres); snprintf(buf, sizeof(buf), "%dx%d", xres, yres);
g_Font[font_info]->RenderString (xpos+spaceoffset, ypos, box_width2, buf, COL_MENUCONTENT_TEXT); g_Font[font_info]->RenderString (xpos+spaceoffset, ypos, box_width2, buf, COL_MENUCONTENT_TEXT);
#if HAVE_COOL_HARDWARE //#if HAVE_COOL_HARDWARE
/* Function temporarily disabled for HD1 */
#if BOXMODEL_CS_HD2
//Video SYSTEM //Video SYSTEM
ypos += iheight; ypos += iheight;
snprintf(buf, sizeof(buf), "%s:", g_Locale->getText (LOCALE_STREAMINFO_VIDEOSYSTEM)); snprintf(buf, sizeof(buf), "%s:", g_Locale->getText (LOCALE_STREAMINFO_VIDEOSYSTEM));