rename graph_win32->graph_gdi

This commit is contained in:
houzh 2024-10-24 16:15:38 +08:00
parent bea3f746a4
commit 11d62fe59b
2 changed files with 10 additions and 10 deletions

View File

@ -16,7 +16,7 @@ include_directories(./
) )
add_library(tvhal SHARED ${WIN32_SRCS} graph_wgl.c) add_library(tvhal SHARED ${WIN32_SRCS} graph_wgl.c)
add_library(tvhal-wgl SHARED ${WIN32_SRCS} graph_wgl.c) add_library(tvhal-wgl SHARED ${WIN32_SRCS} graph_wgl.c)
add_library(tvhal-gdi SHARED ${WIN32_SRCS} graph_win32.c) add_library(tvhal-gdi SHARED ${WIN32_SRCS} graph_gdi.c)
set_target_properties(tvhal PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS ON) set_target_properties(tvhal PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS ON)
set_target_properties(tvhal-wgl PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS ON) set_target_properties(tvhal-wgl PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS ON)

View File

@ -175,14 +175,14 @@ int32_t GFXGetDisplaySize(int dispid,uint32_t*width,uint32_t*height) {
} }
int32_t GFXLockSurface(HANDLE surface,void**buffer,uint32_t*pitch) { int32_t GFXLockSurface(GFXHANDLE surface,void**buffer,uint32_t*pitch) {
FBSURFACE*ngs=(FBSURFACE*)surface; FBSURFACE*ngs=(FBSURFACE*)surface;
*buffer=ngs->buffer; *buffer=ngs->buffer;
*pitch=ngs->pitch; *pitch=ngs->pitch;
return 0; return 0;
} }
int32_t GFXGetSurfaceInfo(HANDLE surface,uint32_t*width,uint32_t*height,int32_t *format) { int32_t GFXGetSurfaceInfo(GFXHANDLE surface,uint32_t*width,uint32_t*height,int32_t *format) {
FBSURFACE*ngs=(FBSURFACE*)surface; FBSURFACE*ngs=(FBSURFACE*)surface;
*width = ngs->width; *width = ngs->width;
*height= ngs->height; *height= ngs->height;
@ -190,15 +190,15 @@ int32_t GFXGetSurfaceInfo(HANDLE surface,uint32_t*width,uint32_t*height,int32_t
return E_OK; return E_OK;
} }
int32_t GFXUnlockSurface(HANDLE surface) { int32_t GFXUnlockSurface(GFXHANDLE surface) {
return 0; return 0;
} }
int32_t GFXSurfaceSetOpacity(HANDLE surface,uint8_t alpha) { int32_t GFXSurfaceSetOpacity(GFXHANDLE surface,uint8_t alpha) {
return 0;//dispLayer->SetOpacity(dispLayer,alpha); return 0;//dispLayer->SetOpacity(dispLayer,alpha);
} }
int32_t GFXFillRect(HANDLE surface,const GFXRect*rect,uint32_t color) { int32_t GFXFillRect(GFXHANDLE surface,const GFXRect*rect,uint32_t color) {
FBSURFACE*ngs=(FBSURFACE*)surface; FBSURFACE*ngs=(FBSURFACE*)surface;
uint32_t x,y; uint32_t x,y;
GFXRect rec= {0,0,0,0}; GFXRect rec= {0,0,0,0};
@ -213,7 +213,7 @@ int32_t GFXFillRect(HANDLE surface,const GFXRect*rect,uint32_t color) {
return E_OK; return E_OK;
} }
int32_t GFXFlip(HANDLE surface) { int32_t GFXFlip(GFXHANDLE surface) {
FBSURFACE*surf=(FBSURFACE*)surface; FBSURFACE*surf=(FBSURFACE*)surface;
FBDEVICE*dev=devs+surf->dispid; FBDEVICE*dev=devs+surf->dispid;
if(surf->ishw) { if(surf->ishw) {
@ -223,7 +223,7 @@ int32_t GFXFlip(HANDLE surface) {
return 0; return 0;
} }
int32_t GFXCreateSurface(int dispid,HANDLE*surface,uint32_t width,uint32_t height,int32_t format,BOOL hwsurface) { int32_t GFXCreateSurface(int dispid,GFXHANDLE*surface,uint32_t width,uint32_t height,int32_t format,bool hwsurface) {
FBSURFACE*surf=(FBSURFACE*)malloc(sizeof(FBSURFACE)); FBSURFACE*surf=(FBSURFACE*)malloc(sizeof(FBSURFACE));
FBDEVICE*dev = &devs[dispid]; FBDEVICE*dev = &devs[dispid];
surf->dispid=dispid; surf->dispid=dispid;
@ -255,7 +255,7 @@ int32_t GFXCreateSurface(int dispid,HANDLE*surface,uint32_t width,uint32_t heigh
} }
int32_t GFXBlit(HANDLE dstsurface,int dx,int dy,HANDLE srcsurface,const GFXRect*srcrect) { int32_t GFXBlit(GFXHANDLE dstsurface,int dx,int dy,GFXHANDLE srcsurface,const GFXRect*srcrect) {
unsigned int x,y,sw,sh; unsigned int x,y,sw,sh;
FBSURFACE*ndst=(FBSURFACE*)dstsurface; FBSURFACE*ndst=(FBSURFACE*)dstsurface;
FBSURFACE*nsrc=(FBSURFACE*)srcsurface; FBSURFACE*nsrc=(FBSURFACE*)srcsurface;
@ -296,7 +296,7 @@ int32_t GFXBlit(HANDLE dstsurface,int dx,int dy,HANDLE srcsurface,const GFXRect*
return 0; return 0;
} }
int32_t GFXDestroySurface(HANDLE surface) { int32_t GFXDestroySurface(GFXHANDLE surface) {
FBSURFACE* surf = (FBSURFACE*)surface; FBSURFACE* surf = (FBSURFACE*)surface;
FBDEVICE* dev = devs + surf->dispid; FBDEVICE* dev = devs + surf->dispid;
if (surf->hBitmap) { if (surf->hBitmap) {