The image references. Look the cImage for the list of allowed operations.
More...
#include <CoreAPI.h>
|
| Image (const Image &im) |
|
bool | Read (const char *name) |
| Read the image from the file.
|
|
bool | Write (const char *name) |
| Write the image to file.
|
|
bool | FromTexture (int texture_id) |
| Get image from texture.
|
|
int | ToTexture () |
| Create texture from image.
|
|
int | Paste (PY_BYTE_ARRAY src_data, int pasteLeft=0, int pasteTop=0, int cropLeft=0, int cropTop=0, int cropRight=0, int cropBottom=0, bool flipY=false) |
| paste image to image
|
|
size_t | Pointer () |
| Pointer to the data.
|
|
bool | FromArray (PY_BYTE_ARRAY src_data) |
| Get image from texture.
|
|
bool | FromArray (PY_DWORD_ARRAY src_data) |
|
bool | FromArray (PY_FLOAT_ARRAY src_data) |
|
pybind11::buffer_info | _py_buffer_info () |
|
The image references. Look the cImage for the list of allowed operations.
- Examples
- TreesGenerator.cpp.
◆ FromArray()
bool coat::Image::FromArray |
( |
PY_BYTE_ARRAY | src_data | ) |
|
Get image from texture.
- Parameters
-
- Returns
- true if succeed
◆ FromTexture()
bool coat::Image::FromTexture |
( |
int | texture_id | ) |
|
Get image from texture.
- Parameters
-
- Returns
- true if succeed
◆ Paste()
int coat::Image::Paste |
( |
PY_BYTE_ARRAY | src_data, |
|
|
int | pasteLeft = 0, |
|
|
int | pasteTop = 0, |
|
|
int | cropLeft = 0, |
|
|
int | cropTop = 0, |
|
|
int | cropRight = 0, |
|
|
int | cropBottom = 0, |
|
|
bool | flipY = false ) |
paste image to image
- Parameters
-
numpy | array for source |
pasteLeft | |
pasteTop | |
cropLeft | |
cropTop | |
cropRight | |
cropBottom | |
flipY | |
- Returns
- true if succeed
◆ Pointer()
size_t coat::Image::Pointer |
( |
| ) |
|
Pointer to the data.
- Returns
- true if succeed
◆ Read()
bool coat::Image::Read |
( |
const char * | name | ) |
|
Read the image from the file.
- Parameters
-
- Returns
- true if loaded successfully
- Examples
- TreesGenerator.cpp.
◆ ToTexture()
int coat::Image::ToTexture |
( |
| ) |
|
Create texture from image.
- Returns
- true if succeed
◆ Write()
bool coat::Image::Write |
( |
const char * | name | ) |
|
Write the image to file.
- Parameters
-
- Returns
- true if succeed
The documentation for this class was generated from the following file: