MiniGUI API Reference (MiniGUI-Processes)  v4.0.7
A mature and proven cross-platform GUI system for embedded and smart IoT devices
Data Structures | Macros | Typedefs | Enumerations | Functions
External Stubs for DRI sub driver

Data Structures

struct  _DrmSurfaceBuffer
 
struct  _DrmDriverOps
 

Macros

#define DRM_DRIVER_VERSION   1
 

Typedefs

typedef struct _DrmSurfaceBuffer DrmSurfaceBuffer
 
typedef struct _DrmDriverOps DrmDriverOps
 

Enumerations

enum  ColorBlendMethod {
  COLOR_BLEND_PD_SRC_OVER = 0, COLOR_BLEND_PD_DST_OVER, COLOR_BLEND_PD_CLEAR, COLOR_BLEND_PD_SRC,
  COLOR_BLEND_PD_DST, COLOR_BLEND_PD_SRC_IN, COLOR_BLEND_PD_DST_IN, COLOR_BLEND_PD_SRC_OUT,
  COLOR_BLEND_PD_DST_OUT, COLOR_BLEND_PD_SRC_ATOP, COLOR_BLEND_PD_DST_ATOP, COLOR_BLEND_PD_XOR,
  COLOR_BLEND_PD_PLUS, COLOR_BLEND_PD_MODULATE , COLOR_BLEND_SP_NORMAL, COLOR_BLEND_SP_MULTIPLY,
  COLOR_BLEND_SP_SCREEN, COLOR_BLEND_SP_OVERLAY, COLOR_BLEND_SP_DARKEN, COLOR_BLEND_SP_LIGHTEN,
  COLOR_BLEND_SP_COLOR_DODGE, COLOR_BLEND_SP_COLOR_BURN, COLOR_BLEND_SP_HARD_LIGHT, COLOR_BLEND_SP_SOFT_LIGHT,
  COLOR_BLEND_SP_DIFFERENCE, COLOR_BLEND_SP_EXCLUSION , COLOR_BLEND_NS_HUE, COLOR_BLEND_NS_SATURATION,
  COLOR_BLEND_NS_COLOR, COLOR_BLEND_NS_LUMINOSITY
}
 
enum  ColorLogicalOp
 

Functions

DrmDriverOps__drm_ex_driver_get (const char *driver_name, int device_fd, int *version)
 

Detailed Description

Macro Definition Documentation

◆ DRM_DRIVER_VERSION

#define DRM_DRIVER_VERSION   1

The current version of DRM driver.

Definition at line 508 of file exstubs.h.

Typedef Documentation

◆ DrmDriverOps

typedef struct _DrmDriverOps DrmDriverOps

The structure type defines the operations for a DRM driver.

◆ DrmSurfaceBuffer

The structure type represents the buffer can be used by MiniGUI NEWGAL DRM engine for a hardware surface.

Enumeration Type Documentation

◆ ColorBlendMethod

The color blend mothed.

See Compositing and Blending Level 1

Enumerator
COLOR_BLEND_PD_SRC_OVER 

Porter Duff rule: source over destination

COLOR_BLEND_PD_DST_OVER 

Porter Duff rule: destination over source

COLOR_BLEND_PD_CLEAR 

Porter Duff rule: clear

COLOR_BLEND_PD_SRC 

Porter Duff rule: source

COLOR_BLEND_PD_DST 

Porter Duff rule: destination

COLOR_BLEND_PD_SRC_IN 

Porter Duff rule: souorce in destination

COLOR_BLEND_PD_DST_IN 

Porter Duff rule: destination in souorce

COLOR_BLEND_PD_SRC_OUT 

Porter Duff rule: source held out by destination

COLOR_BLEND_PD_DST_OUT 

Porter Duff rule: destination held out by source

COLOR_BLEND_PD_SRC_ATOP 

Porter Duff rule: source atop destination

COLOR_BLEND_PD_DST_ATOP 

Porter Duff rule: destination atop source

COLOR_BLEND_PD_XOR 

Porter Duff rule: source xor destination

COLOR_BLEND_PD_PLUS 

Porter Duff rule: plus

COLOR_BLEND_PD_MODULATE 

Porter Duff rule: modulate

COLOR_BLEND_SP_NORMAL 

Separable blend mode: normal The blending formula simply selects the source color.

COLOR_BLEND_SP_MULTIPLY 

Separable blend mode: multiply Darkens by multiplying colors: Sc·Dc.

COLOR_BLEND_SP_SCREEN 

Separable blend mode: screen Complements product of complements: Sc + Dc - Sc·Dc.

COLOR_BLEND_SP_OVERLAY 

Separable blend mode: overlay Inverse of hard-light.

COLOR_BLEND_SP_DARKEN 

Separable blend mode: darken Minimum of colors: min(Sc, Dc).

COLOR_BLEND_SP_LIGHTEN 

Separable blend mode: lighten Maximum of colors: max(Sc, Dc).

COLOR_BLEND_SP_COLOR_DODGE 

Separable blend mode: color-dodge Brightens destination based on source.

COLOR_BLEND_SP_COLOR_BURN 

Separable blend mode: color-burn Darkens destination based on source.

COLOR_BLEND_SP_HARD_LIGHT 

Separable blend mode: hard-light Similar to effect of harsh spotlight.

COLOR_BLEND_SP_SOFT_LIGHT 

Separable blend mode: soft-light Similar to effect of soft spotlight.

COLOR_BLEND_SP_DIFFERENCE 

Separable blend mode: difference Subtracts the darker from the lighter: Abs(Dc - Sc).

COLOR_BLEND_SP_EXCLUSION 

Separable blend mode: exclusion Similar to Difference but lower contrast.

COLOR_BLEND_NS_HUE 

Non-Separable blend mode: hue Creates a color with the hue of the source color and the saturation and luminosity of the backdrop color.

COLOR_BLEND_NS_SATURATION 

Non-Separable blend mode: saturation Creates a color with the saturation of the source color and the hue and luminosity of the backdrop color.

COLOR_BLEND_NS_COLOR 

Non-Separable blend mode: color Creates a color with the hue and saturation of the source color and the luminosity of the backdrop color.

COLOR_BLEND_NS_LUMINOSITY 

Non-Separable blend mode: luminosity Creates a color with the luminosity of the source color and the hue and saturation of the backdrop color.

Definition at line 165 of file exstubs.h.

◆ ColorLogicalOp

The color logical operations.

Definition at line 294 of file exstubs.h.

Function Documentation

◆ __drm_ex_driver_get()

DrmDriverOps* __drm_ex_driver_get ( const char *  driver_name,
int  device_fd,
int *  version 
)

Implement this stub to return the DRI driver operations

This function takes three arguments and returns NULL or a valid pointer of DrmDriverOps to MiniGUI.

This function can return different DrmDriverOps to MiniGUI according to the driver name and device file descriptor. In this way, your DRM engine driver implementation can support multiple GPUs.

If the external stub returns NULL, MiniGUI will try to use the dumb frame buffer instead.

Parameters
driver_nameThis argument gives the driver name determined by MiniGUI. Generally, it is the kernel driver name for your GPU. For example, for Intel i915/i965 GPUs, the driver name will be i915.
device_fdThis argument gives the file descriptor of the opened DRI device.
versionA pointer to an integer which will be used the interface version of the DRM engine driver.
Returns
NULL or a valid pointer to DrmDriverOps.
Note
We use the version control since 4.0.7. It will be initialized to zero by MiniGUI before calling this function. Because an old driver for MiniGUI 4.0.6 or earlier will not change the value, MiniGUI will deny to load the old driver.

The constant DRM_DRIVER_VERSION defines the current version code.