Operating systems, development tools, and professional services
for connected embedded systems
for connected embedded systems
![]() |
![]() |
![]() |
![]() |
PgGetLayerCaps()
Query the capabilities of a layer
Synopsis:
int PgGetLayerCaps( int layer,
int format_index,
PgLayerCaps_t *const caps );
Arguments:
- layer
- The layer index, which must be 0 or greater.
- format_index
- The format index, which must be 0 or greater.
- caps
- A pointer to a
PgLayerCaps_t
structure that the function fills with the layer capabilities.
Any existing content of the structure is discarded.
This argument must not be NULL.
Library:
ph
Description:
PgGetLayerCaps() queries the capabilities of the given layer, in the given format. You can use the format_index to iterate through all of the available layer formats. An error is returned when format_index exceeds the number of supported formats.
![]() |
You must target this function at a device by calling PdSetTargetDevice(). |
Returns:
- 0
- Success.
- -1
- An error occurred (errno is set).
Errors:
- EFAULT
- The caps argument is NULL.
- EINVAL
- The layer index is invalid, or the format_index if greater than the number of formats.
- ENXIO
- The layer doesn't exist.
- EOPNOTSUPP
- The driver doesn't support layers.
Classification:
Photon
| Safety: | |
|---|---|
| Interrupt handler | No |
| Signal handler | No |
| Thread | No |
See also:
PdSetTargetDevice(), PgLayerCaps_t
"Layers" in the Raw Drawing and Animation chapter of the Photon Programmer's Guide
![]() |
![]() |
![]() |
![]() |

![[Previous]](../prev.gif)
![[Contents]](../contents.gif)
![[Index]](../keyword_index.gif)
![[Next]](../next.gif)
