mirror of
https://github.com/libretro/RetroArch
synced 2025-04-16 08:43:10 +00:00
Document shader_context.c
This commit is contained in:
parent
b243f64554
commit
f259b56d5f
@ -179,7 +179,7 @@ static const gfx_ctx_driver_t *gfx_ctx_init(void *data,
|
|||||||
* @hw_render_ctx : Request a graphics context driver capable of
|
* @hw_render_ctx : Request a graphics context driver capable of
|
||||||
* hardware rendering?
|
* hardware rendering?
|
||||||
*
|
*
|
||||||
* Finds first suitable graphics context driver and initializes.
|
* Finds graphics context driver and initializes.
|
||||||
*
|
*
|
||||||
* Returns: graphics context driver if found, otherwise NULL.
|
* Returns: graphics context driver if found, otherwise NULL.
|
||||||
**/
|
**/
|
||||||
|
@ -35,19 +35,34 @@ static const shader_backend_t *shader_ctx_drivers[] = {
|
|||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* shader_ctx_find_driver:
|
||||||
|
* @ident : Identifier of shader context driver to find.
|
||||||
|
*
|
||||||
|
* Finds shader context driver and initializes.
|
||||||
|
*
|
||||||
|
* Returns: shader context driver if found, otherwise NULL.
|
||||||
|
**/
|
||||||
const shader_backend_t *shader_ctx_find_driver(const char *ident)
|
const shader_backend_t *shader_ctx_find_driver(const char *ident)
|
||||||
{
|
{
|
||||||
unsigned i;
|
unsigned i;
|
||||||
|
|
||||||
for (i = 0; shader_ctx_drivers[i]; i++)
|
for (i = 0; shader_ctx_drivers[i]; i++)
|
||||||
{
|
{
|
||||||
if (strcmp(shader_ctx_drivers[i]->ident, ident) == 0)
|
if (!strcmp(shader_ctx_drivers[i]->ident, ident))
|
||||||
return shader_ctx_drivers[i];
|
return shader_ctx_drivers[i];
|
||||||
}
|
}
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* shader_ctx_init_first:
|
||||||
|
*
|
||||||
|
* Finds first suitable shader context driver and initializes.
|
||||||
|
*
|
||||||
|
* Returns: shader context driver if found, otherwise NULL.
|
||||||
|
**/
|
||||||
const shader_backend_t *shader_ctx_init_first(void)
|
const shader_backend_t *shader_ctx_init_first(void)
|
||||||
{
|
{
|
||||||
unsigned i;
|
unsigned i;
|
||||||
|
@ -84,8 +84,23 @@ extern const shader_backend_t shader_null_backend;
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/**
|
||||||
|
* shader_ctx_find_driver:
|
||||||
|
* @ident : Identifier of shader context driver to find.
|
||||||
|
*
|
||||||
|
* Finds shader context driver and initializes.
|
||||||
|
*
|
||||||
|
* Returns: shader context driver if found, otherwise NULL.
|
||||||
|
**/
|
||||||
const shader_backend_t *shader_ctx_find_driver(const char *ident);
|
const shader_backend_t *shader_ctx_find_driver(const char *ident);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* shader_ctx_init_first:
|
||||||
|
*
|
||||||
|
* Finds first suitable shader context driver and initializes.
|
||||||
|
*
|
||||||
|
* Returns: shader context driver if found, otherwise NULL.
|
||||||
|
**/
|
||||||
const shader_backend_t *shader_ctx_init_first(void);
|
const shader_backend_t *shader_ctx_init_first(void);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user