mirror of
https://github.com/VincentWei/MiniGUI.git
synced 2026-02-06 10:21:57 +08:00
define backward compatible APIs for drmCreateDCFromXXX
This commit is contained in:
@@ -14395,10 +14395,18 @@ MG_EXPORT BOOL drmGetSurfaceInfo (GHANDLE video, HDC hdc, DrmSurfaceInfo* info);
|
||||
*
|
||||
* \return The handle to the memory DC for success, HDC_INVALID for failure.
|
||||
*/
|
||||
MG_EXPORT HDC drmCreateDCFromName (GHANDLE video,
|
||||
MG_EXPORT HDC drmCreateDCFromNameEx (GHANDLE video,
|
||||
uint32_t name, uint32_t drm_format, off_t offset,
|
||||
uint32_t width, uint32_t height, uint32_t pitch);
|
||||
|
||||
static inline HDC drmCreateDCFromName (GHANDLE video,
|
||||
uint32_t name, uint32_t drm_format,
|
||||
uint32_t width, uint32_t height, uint32_t pitch)
|
||||
{
|
||||
return drmCreateDCFromNameEx (video,
|
||||
name, drm_format, 0, width, height, pitch);
|
||||
}
|
||||
|
||||
/**
|
||||
* This function creates a memory DC with a DRM surface which is created by
|
||||
* a foreign process and identified by a PRIME file descriptor.
|
||||
@@ -14414,10 +14422,18 @@ MG_EXPORT HDC drmCreateDCFromName (GHANDLE video,
|
||||
*
|
||||
* \return The handle to the memory DC for success, HDC_INVALID for failure.
|
||||
*/
|
||||
MG_EXPORT HDC drmCreateDCFromPrimeFd (GHANDLE video,
|
||||
MG_EXPORT HDC drmCreateDCFromPrimeFdEx (GHANDLE video,
|
||||
int prime_fd, size_t size, uint32_t drm_format, off_t offset,
|
||||
uint32_t width, uint32_t height, uint32_t pitch);
|
||||
|
||||
static inline HDC drmCreateDCFromPrimeFd (GHANDLE video,
|
||||
int prime_fd, size_t size, uint32_t drm_format,
|
||||
uint32_t width, uint32_t height, uint32_t pitch)
|
||||
{
|
||||
return drmCreateDCFromPrimeFdEx (video,
|
||||
prime_fd, size, drm_format, 0, width, height, pitch);
|
||||
}
|
||||
|
||||
/**
|
||||
* This function creates a memory DC with a DRM surface which is created by
|
||||
* a foreign graphics component.
|
||||
@@ -14433,10 +14449,18 @@ MG_EXPORT HDC drmCreateDCFromPrimeFd (GHANDLE video,
|
||||
*
|
||||
* \return The handle to the memory DC for success, HDC_INVALID for failure.
|
||||
*/
|
||||
MG_EXPORT HDC drmCreateDCFromHandle (GHANDLE video,
|
||||
MG_EXPORT 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);
|
||||
|
||||
static inline HDC drmCreateDCFromHandle (GHANDLE video,
|
||||
uint32_t handle, size_t size, uint32_t drm_format,
|
||||
uint32_t width, uint32_t height, uint32_t pitch)
|
||||
{
|
||||
return drmCreateDCFromHandleEx (video,
|
||||
handle, size, drm_format, 0, width, height, pitch);
|
||||
}
|
||||
|
||||
/** @} end of gdi_drm_fns */
|
||||
|
||||
#endif /* _MGGAL_DRM */
|
||||
|
||||
Reference in New Issue
Block a user