Merge commit '3a7f96fd99528968c39b5be81db067ca018d432b' into dev
This commit is contained in:
9
external/SDL/test/testcamera.c
vendored
9
external/SDL/test/testcamera.c
vendored
@@ -21,7 +21,7 @@ static SDLTest_CommonState *state = NULL;
|
||||
static SDL_Camera *camera = NULL;
|
||||
static SDL_CameraSpec spec;
|
||||
static SDL_Texture *texture = NULL;
|
||||
static SDL_bool texture_updated = SDL_FALSE;
|
||||
static bool texture_updated = false;
|
||||
static SDL_Surface *frame_current = NULL;
|
||||
static SDL_CameraID front_camera = 0;
|
||||
static SDL_CameraID back_camera = 0;
|
||||
@@ -59,9 +59,6 @@ SDL_AppResult SDL_AppInit(void **appstate, int argc, char *argv[])
|
||||
return SDL_APP_FAILURE;
|
||||
}
|
||||
|
||||
/* Enable standard application logging */
|
||||
SDL_SetLogPriority(SDL_LOG_CATEGORY_APPLICATION, SDL_LOG_PRIORITY_INFO);
|
||||
|
||||
/* Parse commandline */
|
||||
for (i = 1; i < argc;) {
|
||||
int consumed;
|
||||
@@ -305,7 +302,7 @@ SDL_AppResult SDL_AppIterate(void *appstate)
|
||||
* But in case of 0-copy, it's needed to have the frame while using the texture.
|
||||
*/
|
||||
frame_current = frame_next;
|
||||
texture_updated = SDL_FALSE;
|
||||
texture_updated = false;
|
||||
}
|
||||
|
||||
if (frame_current) {
|
||||
@@ -339,7 +336,7 @@ SDL_AppResult SDL_AppIterate(void *appstate)
|
||||
/* Update SDL_Texture with last video frame (only once per new frame) */
|
||||
if (frame_current && !texture_updated) {
|
||||
SDL_UpdateTexture(texture, NULL, frame_current->pixels, frame_current->pitch);
|
||||
texture_updated = SDL_TRUE;
|
||||
texture_updated = true;
|
||||
}
|
||||
|
||||
SDL_GetTextureSize(texture, &tw, &th);
|
||||
|
||||
Reference in New Issue
Block a user