|  | MPLABĀ® Harmony Graphics Suite
    | 
Pixel Buffer functions and definitions. More...
#include "gfx/legato/common/legato_color.h"

Go to the source code of this file.
| Data Structures | |
| struct | lePixelBuffer | 
| Typedefs | |
| typedef struct lePixelBuffer | lePixelBuffer | 
| Enumerations | |
| enum | BufferFlags { BF_NONE = 0, BF_LOCKED = 1 << 0 } | 
| leArray data structure definition. | |
| Functions | |
| LIB_EXPORT leResult | lePixelBufferCreate (const int32_t width, const int32_t height, const leColorMode mode, const void *const address, lePixelBuffer *buffer) | 
| Create a pixelbuffer.  More... | |
| LIB_EXPORT leBuffer | lePixelBufferOffsetGet (const lePixelBuffer *const buffer, uint32_t x, uint32_t y) | 
| Get buffer at point.  More... | |
| LIB_EXPORT leBuffer | lePixelBufferOffsetGet_Unsafe (const lePixelBuffer *const buffer, uint32_t x, uint32_t y) | 
| Get buffer at point.  More... | |
| LIB_EXPORT leColor | lePixelBufferGet (const lePixelBuffer *const buffer, uint32_t x, uint32_t y) | 
| Get pixel at point.  More... | |
| LIB_EXPORT leColor | lePixelBufferGet_Unsafe (const lePixelBuffer *const buffer, uint32_t x, uint32_t y) | 
| Get pixel at point.  More... | |
| LIB_EXPORT leColor | lePixelBufferGetIndex_Unsafe (const lePixelBuffer *const buffer, const uint32_t idx) | 
| Get color at index.  More... | |
| LIB_EXPORT leResult | lePixelBufferClipRect (const lePixelBuffer *const buffer, const leRect *const rect, leRect *result) | 
| Clip rectangle.  More... | |
| LIB_EXPORT leResult | lePixelBufferSet (const lePixelBuffer *const buffer, uint32_t x, uint32_t y, leColor color) | 
| Pixel set.  More... | |
| LIB_EXPORT leResult | lePixelBufferSet_Unsafe (const lePixelBuffer *const buffer, uint32_t x, uint32_t y, leColor color) | 
| Pixel set.  More... | |
| leResult | lePixelBufferAreaFill (const lePixelBuffer *const buffer, uint32_t x, uint32_t y, uint32_t w, uint32_t h, const leColor color) | 
| Area fill with checking.  More... | |
| LIB_EXPORT leResult | lePixelBufferAreaFill_Unsafe (const lePixelBuffer *const buffer, uint32_t x, uint32_t y, uint32_t w, uint32_t h, leColor color) | 
| Area fill no checking.  More... | |
| leResult | lePixelBufferCopy (lePixelBuffer *dest, uint32_t x, uint32_t y, const lePixelBuffer *src, const leRect *srcRect) | 
| LIB_EXPORT leBool | lePixelBuffer_IsLocked (const lePixelBuffer *const buffer) | 
| Determines the lock state.  More... | |
| LIB_EXPORT leResult | lePixelBuffer_SetLocked (lePixelBuffer *buffer, leBool locked) | 
| Sets the lock.  More... | |
Pixel Buffer functions and definitions.
Pixel buffer generation and management functions.
| LIB_EXPORT leBool lePixelBuffer_IsLocked | ( | const lePixelBuffer *const | buffer | ) | 
Determines the lock state.
Returns the lock state of buffer.
| param1 | buffer is the source color value. | 
| LIB_EXPORT leResult lePixelBuffer_SetLocked | ( | lePixelBuffer * | buffer, | 
| leBool | locked | ||
| ) | 
Sets the lock.
Set the lock flag on buffer to the desired lock state specified by locked.
| param1 | buffer is the source color value. | 
| param2 | locked is the source color mode | 
| leResult lePixelBufferAreaFill | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y, | ||
| uint32_t | w, | ||
| uint32_t | h, | ||
| const leColor | color | ||
| ) | 
Area fill with checking.
Fill buffer with color defined by the x, y w, h.
| param1 | buffer is the source color value. | 
| LIB_EXPORT leResult lePixelBufferAreaFill_Unsafe | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y, | ||
| uint32_t | w, | ||
| uint32_t | h, | ||
| leColor | color | ||
| ) | 
Area fill no checking.
Fill buffer with color defined by the x, y w, h.
| param1 | buffer is the source color value. | 

| LIB_EXPORT leResult lePixelBufferClipRect | ( | const lePixelBuffer *const | buffer, | 
| const leRect *const | rect, | ||
| leRect * | result | ||
| ) | 
Clip rectangle.
Clips a rectangle against a pixel buffer. The result is guaranteed to fit inside the buffer's area.
| param1 | buffer is the source color value. | 
| LIB_EXPORT leResult lePixelBufferCreate | ( | const int32_t | width, | 
| const int32_t | height, | ||
| const leColorMode | mode, | ||
| const void *const | address, | ||
| lePixelBuffer * | buffer | ||
| ) | 
Create a pixelbuffer.
| param1 | buffer is the source color value. | 
| LIB_EXPORT leColor lePixelBufferGet | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y | ||
| ) | 
Get pixel at point.
Gets the value of the pixel that resides at the provided point in the given buffer
| param1 | buffer is the source color value. | 

| LIB_EXPORT leColor lePixelBufferGet_Unsafe | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y | ||
| ) | 
Get pixel at point.
Gets the value of the pixel that resides at the provided point in the given buffer. Like lePixelBufferGet but performs no bounds checking.
| param1 | buffer is the source color value. | 


| LIB_EXPORT leColor lePixelBufferGetIndex_Unsafe | ( | const lePixelBuffer *const | buffer, | 
| const uint32_t | idx | ||
| ) | 
Get color at index.
Pixel get.
Interprets the pixel buffer as a table of indices and looks up a specific index at position 'idx'. Indices may be 1bpp, 4bpp, or 8bpp in size and are indicated by the color mode of the pixel buffer.
| param1 | buffer is the source color value. | 
A faster less-safe version of lePixelBufferGetIndex.
| param1 | buffer is the source color value. | 
Get color at index.
A faster less-safe version of lePixelBufferGetIndex.
| param1 | buffer is the source color value. | 
| LIB_EXPORT leBuffer lePixelBufferOffsetGet | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y | ||
| ) | 
Get buffer at point.
Gets the offset address of the pixel that resides at the provided point in the given buffer.
| param1 | buffer is the source color value. | 

| LIB_EXPORT leBuffer lePixelBufferOffsetGet_Unsafe | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y | ||
| ) | 
Get buffer at point.
Gets the offset address of the pixel that resides at the provided point in the given buffer. Similar to lePixelBufferOffsetGet but performs no bounds checking.
| param1 | buffer is the source color value. | 

| LIB_EXPORT leResult lePixelBufferSet | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y, | ||
| leColor | color | ||
| ) | 
Pixel set.
Sets a pixel in a pixel buffer at a point to a specified color. Caller is responsible for ensuring that the input color is in the same color format as the pixel buffer
| param1 | buffer is the source color value. | 
| LIB_EXPORT leResult lePixelBufferSet_Unsafe | ( | const lePixelBuffer *const | buffer, | 
| uint32_t | x, | ||
| uint32_t | y, | ||
| leColor | color | ||
| ) | 
Pixel set.
Sets a pixel in a pixel buffer at a point to a specified color. Caller is responsible for ensuring that the input color is in the same color format as the pixel buffer. Like lePixelBufferSet but performs no bounds checking.
| param1 | buffer is the source color value. | 

 1.8.18
 1.8.18