Play Youtube HTML5 embedded Video in Android WebView

Step 1 : Simply add this to Manifest file

android:hardwareAccelerated="true"

step 2 : check if you are setting layer for your webview.

(i.e.)
//myWebView.setLayerType(View.LAYER_TYPE_SOFTWARE, null);

setting hardware acceleration to true and commenting these lines worked for me .

To know more about Hardware Acceleration and Layers look here at http://developer.android.com/guide/topics/graphics/hardware-accel.html

Leave a Comment