mirror of
https://github.com/VincentWei/MiniGUI.git
synced 2026-02-06 02:01:50 +08:00
Merge branch 'rel-4-0' of gitlab.fmsoft.cn:VincentWei/minigui into rel-4-0
This commit is contained in:
@@ -800,9 +800,9 @@ GAL_Surface* __drm_create_surface_from_name (GHANDLE video,
|
||||
uint32_t name, uint32_t drm_format, uint32_t pixels_off,
|
||||
uint32_t width, uint32_t height, uint32_t pitch);
|
||||
|
||||
GAL_Surface* __drm_create_surface_from_handle (GHANDLE video,
|
||||
uint32_t handle, size_t size, uint32_t drm_format, uint32_t pixels_off,
|
||||
uint32_t width, uint32_t height, uint32_t pitch);
|
||||
//GAL_Surface* __drm_create_surface_from_handle (GHANDLE video,
|
||||
// uint32_t handle, size_t size, uint32_t drm_format, uint32_t pixels_off,
|
||||
// uint32_t width, uint32_t height, uint32_t pitch);
|
||||
|
||||
GAL_Surface* __drm_create_surface_from_prime_fd (GHANDLE video,
|
||||
int prime_fd, size_t size, uint32_t drm_format, uint32_t pixels_off,
|
||||
|
||||
@@ -63,6 +63,8 @@
|
||||
#include <time.h>
|
||||
#endif
|
||||
|
||||
#include <sys/select.h>
|
||||
|
||||
#ifndef HAVE_STRDUP
|
||||
char* strdup (const char *string)
|
||||
{
|
||||
|
||||
@@ -1681,7 +1681,7 @@ static DrmSurfaceBuffer *drm_create_dumb_buffer(DrmVideoData* vdata,
|
||||
surface_buffer->handle,
|
||||
surface_buffer->width, surface_buffer->height,
|
||||
surface_buffer->pitch,
|
||||
surface_buffer->size, surface_buffer->offset);
|
||||
(long unsigned int)surface_buffer->size, (long unsigned int)surface_buffer->offset);
|
||||
|
||||
/* prepare buffer for memory mapping */
|
||||
memset(&mreq, 0, sizeof(mreq));
|
||||
@@ -1810,7 +1810,7 @@ static DrmSurfaceBuffer *drm_create_dumb_buffer_from_prime_fd(DrmVideoData* vdat
|
||||
return NULL;
|
||||
}
|
||||
|
||||
_DBG_PRINTF("size got by calling lseek: %lu\n", size);
|
||||
_DBG_PRINTF("size got by calling lseek: %lu\n", (long unsigned int)size);
|
||||
}
|
||||
|
||||
ret = drmPrimeFDToHandle (vdata->dev_fd, prime_fd, &handle);
|
||||
|
||||
@@ -3813,6 +3813,10 @@ HDC drmCreateDCFromNameEx (GHANDLE video, uint32_t name, uint32_t drm_format,
|
||||
return (HDC)pmem_dc;
|
||||
}
|
||||
|
||||
extern GAL_Surface* __drm_create_surface_from_handle (GHANDLE video, uint32_t handle,
|
||||
unsigned long size, uint32_t drm_format, uint32_t pixels_off,
|
||||
uint32_t width, uint32_t height, uint32_t pitch);
|
||||
|
||||
HDC drmCreateDCFromHandleEx (GHANDLE video, uint32_t handle, size_t size,
|
||||
uint32_t drm_format, off_t offset,
|
||||
uint32_t width, uint32_t height, uint32_t pitch)
|
||||
@@ -3824,7 +3828,7 @@ HDC drmCreateDCFromHandleEx (GHANDLE video, uint32_t handle, size_t size,
|
||||
return HDC_INVALID;
|
||||
|
||||
LOCK (&__mg_gdilock);
|
||||
surface = __drm_create_surface_from_handle (video, handle, size,
|
||||
surface = (GAL_Surface *)__drm_create_surface_from_handle (video, handle, size,
|
||||
drm_format, offset, width, height, pitch);
|
||||
UNLOCK (&__mg_gdilock);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user