Module Documentation
FM4, S6E2DH/S6E2DF/S6E2D5/S6E2D3 Series, 32-Bit Microcontroller, Graphic Driver User Manual, Doc. No. 002-04387 Rev. *A
127
A typical mmlGdcPeBlt operation processes a store rectangle defined by the active area of the SRC surface
and the given matrix transformation. An application can change this behavior by using
mmlGdcPeSelectArea.
A SRC and STORE surface must be defined in minimum to proceed a mmlGdcPeBlt (simple copy)
operation. If a DST surface is defined, a blend operation will be performed. If a MASK surface is defined the
MASK alpha channel will be used as external alpha. That means the resulting alpha for the blendingstep is A
= Asrc
∗
Amask. If a ROP operation with MASK or DST is defined, external alpha or blendingmutates to a
ROP operation. See mmlGdcPeRopOperation for more details.
The graphical operation will not be finished after the mmlGdcPeBlt call. That means the involved buffers are
still in use. Please use synchronization objects or simple mmlGdcPeFinish to ensure that all operations are
complete.
Pixel Engine operations can be queued by the driver to enhance performance especially in multi-threading
environment. The execution especially of long processing commands can be forced by ammlGdcPeFlush
call. mmlGdcPeFinish, mmlGdcDispWinSetSurface and mmlGdcPeSync also flush the command queue.
The following features can be defined for the bounded surfaces:
ALL: simple transformation (translation, mirroring, 90°rotation) if buffer is not compressed.
SRC: rotate/scale or index/decompress.
DST: index/decompress if SRC does not require these features.
MASK: scale if scale factor is identical with SRC.
Parameters
in,out
pectx
Pixel Engine context (!=NULL).
in
offsetx
Horizontal offset (-4096 - 4095).
in
offsety
Vertical offset (-4096 - 4095) (count direction depends on
MML_GDC_PE_ATTR_ZERO_POINT).
Return values
MML_OK
On success. Otherwise the related error code.
11.6.5.7 MML_GDC_PE_API MM_ERROR mmlGdcPeCLUTData ( MML_GDC_PE_CONTEXT
pectx, MML_GDC_PE_CLUT_FORMAT format, const MM_S16
∗
pRed, const MM_S16
∗
pGreen, const MM_S16 pBlue )
Used to configure the Color Lookup Table (CLUT) (e.g., for gamma correction).
The format MML_GDC_PE_CLUT_FORMAT_256 defines 256 sample points representing the the resulting color
channel intensity.
The format MML_GDC_PE_CLUT_FORMAT_33 defines 33 sample points representing the resulting color channel
intensity. Intermediate values will be interpolated by the HW. The 1st sample point corresponds to input color code
0, 2nd one to 32, ..., last one to 1024 of the 10 bit 2D core internal processing pipeline. Although input 1024 is not
possible, the last sample point is needed for interpolation of codes 993 to 1023.
An index entry of 0 stands for the minimum and 1023 for the maximum intensity. Index values outside this range will
be clamped.
Note:
Example: Let F(in) be the requested gamma formula. Input values of F(in) are in the range [0.0, 1.0]. It is allowed
that the output value is smaller than 0.0 or bigger 1.0. The value array (in this example pRed) must be calculated in
the following way:
MML_GDC_PE_CLUT_FORMAT_256:
for
(i = 0; i <= 255; i++)
pRed[i] = (MM_S16)(0.5f + ( F(i/255.0f) * 1023.0f));