Bundle SDL2 multimedia library for 2D graphics, input handling, audio playback, and window management. Core types: Window, Renderer, Texture, Surface, Event, and Mixer. Compile with -lib sdl2.
PixelData
Raw pixel data for surfaces and textures
Operations
Copy #
Copies raw pixel data
method : public : Copy(data:PixelData) ~ BoolParameters
| Name | Type | Description |
|---|---|---|
| data | PixelData | data to copy |
Return
| Type | Description |
|---|---|
| Bool | true if copied, false otherwise |
Get #
Get pixel value for index
method : public : Get(index:Int) ~ IntParameters
| Name | Type | Description |
|---|---|---|
| index | Int | index to get |
Return
| Type | Description |
|---|---|
| Int | pixel value for index |
Get #
Get pixel value for x and y offset
method : public : Get(x:Int, y:Int) ~ IntParameters
| Name | Type | Description |
|---|---|---|
| x | Int | x-offset |
| y | Int | y-offset |
Return
| Type | Description |
|---|---|
| Int | pixel value for index |