mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-25 00:49:47 +00:00
Create video_shader_driver_get_prev_textures
This commit is contained in:
parent
a2da59ac9b
commit
6d37cfc2fb
@ -2576,7 +2576,7 @@ static void *gl_init(const video_info_t *video, const input_driver_t **input, vo
|
||||
|
||||
if (gl->shader)
|
||||
{
|
||||
unsigned minimum = gl->shader->get_prev_textures();
|
||||
unsigned minimum = video_shader_driver_get_prev_textures(gl->shader);
|
||||
gl->textures = max(minimum + 1, gl->textures);
|
||||
}
|
||||
|
||||
@ -2823,7 +2823,7 @@ static bool gl_set_shader(void *data,
|
||||
|
||||
if (gl->shader)
|
||||
{
|
||||
unsigned textures = gl->shader->get_prev_textures() + 1;
|
||||
unsigned textures = video_shader_driver_get_prev_textures(gl->shader) + 1;
|
||||
|
||||
if (textures > gl->textures) /* Have to reinit a bit. */
|
||||
{
|
||||
|
@ -135,6 +135,13 @@ unsigned video_shader_driver_num_shaders(const shader_backend_t *shader)
|
||||
return shader->num_shaders();
|
||||
}
|
||||
|
||||
unsigned video_shader_driver_get_prev_textures(const shader_backend_t *shader)
|
||||
{
|
||||
if (!shader)
|
||||
return 0;
|
||||
return shader->get_prev_textures();
|
||||
}
|
||||
|
||||
bool video_shader_driver_set_coords(const shader_backend_t *shader, const void *data)
|
||||
{
|
||||
if (!shader || !shader->set_coords)
|
||||
|
@ -132,6 +132,8 @@ bool video_shader_driver_set_coords(const shader_backend_t *shader, const void *
|
||||
|
||||
bool video_shader_driver_set_mvp(const shader_backend_t *shader, void *data, const math_matrix_4x4 *mat);
|
||||
|
||||
unsigned video_shader_driver_get_prev_textures(const shader_backend_t *shader);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user