[vlc-commits] vout_ios2: minor code optimization

Felix Paul Kühne git at videolan.org
Mon May 20 20:45:58 CEST 2013


vlc | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Mon May 20 20:44:53 2013 +0200| [04632cc8b2dd3699b8e48d5689904ecdc3e6f46a] | committer: Felix Paul Kühne

vout_ios2: minor code optimization

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=04632cc8b2dd3699b8e48d5689904ecdc3e6f46a
---

 modules/video_output/ios2.m |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/modules/video_output/ios2.m b/modules/video_output/ios2.m
index 9ecc58c..e1ccf87 100644
--- a/modules/video_output/ios2.m
+++ b/modules/video_output/ios2.m
@@ -315,7 +315,7 @@ static void PictureDisplay(vout_display_t *vd, picture_t *pic, subpicture_t *sub
 {
     vout_display_sys_t *sys = vd->sys;
     sys->has_first_frame = true;
-    if ([sys->glESView isAppActive])
+    if (likely([sys->glESView isAppActive]))
         vout_display_opengl_Display(sys->vgl, &vd->source);
 
     picture_Release(pic);
@@ -329,7 +329,7 @@ static void PictureRender(vout_display_t *vd, picture_t *pic, subpicture_t *subp
 
     vout_display_sys_t *sys = vd->sys;
 
-    if ([sys->glESView isAppActive])
+    if (likely([sys->glESView isAppActive]))
         vout_display_opengl_Prepare(sys->vgl, pic, subpicture);
 }
 
@@ -356,7 +356,7 @@ static int OpenglESClean(vlc_gl_t *gl)
 static void OpenglESSwap(vlc_gl_t *gl)
 {
     vout_display_sys_t *sys = (vout_display_sys_t *)gl->sys;
-    if ([sys->glESView isAppActive])
+    if (likely([sys->glESView isAppActive]))
         [[sys->glESView eaglContext] presentRenderbuffer:GL_RENDERBUFFER];
 }
 



More information about the vlc-commits mailing list