[Android] VideoPlayerActivity: restore the hardware acceleration mode after the playback of a TS file

Adrien Maglo git at videolan.org
Fri Jun 13 16:20:51 CEST 2014


vlc-ports/android | branch: master | Adrien Maglo <magsoft at videolan.org> | Fri Jun 13 16:20:45 2014 +0200| [3267ec9a2b4f42d83786f8533d600b8bf193f725] | committer: Adrien Maglo

VideoPlayerActivity: restore the hardware acceleration mode after the playback of a TS file

> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=3267ec9a2b4f42d83786f8533d600b8bf193f725
---

 .../src/org/videolan/vlc/gui/video/VideoPlayerActivity.java       |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
index 29a7507..d9704f9 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
@@ -1874,8 +1874,11 @@ public class VideoPlayerActivity extends Activity implements IVideoPlayer {
             if (locationLC.endsWith(".ts")
                 || locationLC.endsWith("tts")
                 || locationLC.endsWith(".m2t")
-                || locationLC.endsWith(".m2ts"))
+                || locationLC.endsWith(".m2ts")) {
+                mDisabledHardwareAcceleration = true;
+                mPreviousHardwareAccelerationMode = mLibVLC.getHardwareAcceleration();
                 mLibVLC.setHardwareAcceleration(LibVLC.HW_ACCELERATION_DISABLED);
+            }
         }
 
         /* Start / resume playback */



More information about the Android mailing list