android-video-player

Online Video not Playing

梦想与她 提交于 2019-12-06 05:00:46
问题 I'm following a Tutorial to play Video in Android, Tutorial Here But when I run the Application on Emulator, it Gives me the following Error MediaPlayer error (1, -2147483648) Please Help Here's the Code of my Application JAVA package com.example.videoplayer; import android.media.MediaPlayer; import android.media.MediaPlayer.OnErrorListener; import android.media.MediaPlayer.OnPreparedListener; import android.net.Uri; import android.os.Bundle; import android.app.Activity; import android

Android webview doesn't playing mp4 video in same page

女生的网名这么多〃 提交于 2019-12-05 13:48:11
I'm trying to show one local html file contains code for playing video and try to show that html file in android webview. I've used following code to for playing video: WebViewLoadVideoActivity.java //DECLARE webview variable outside of onCreate function so we can access it in other functions (menu) @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); WebView webView = (WebView) findViewById(R.id.webView1); WebSettings webSettings = webView.getSettings(); // Fetches the // WebSettings // import WebViewClient

How to start(play) video once buffer reaches 20% in android video view

南楼画角 提交于 2019-12-05 09:14:47
I have a video view to play video by using url which comes from server. I want video to be played once buffering reaches 20% . So i have added listener for setOnBufferingUpdateListener to mediaplayer like below. Uri video = Uri.parse(videoUrl); videoView.setVideoURI(video); videoView.requestFocus(); videoView.setOnPreparedListener(new OnPreparedListener() { public void onPrepared(MediaPlayer mp) { mp.setOnBufferingUpdateListener(Activity); progressVideoView.setVisibility(View.GONE); videoView.start(); } }); videoView.setOnErrorListener(new OnErrorListener() { @Override public boolean onError

Android video stream capture for AR

自闭症网瘾萝莉.ら 提交于 2019-12-05 06:04:06
问题 I would like to be able to capture the video from an android phone camera, and then process this video. Processing involves adding a layer of AR to the live stream. Is this possible on android? Pretty sure it should be. I have looked at the android site [http://developer.android.com/guide/topics/media/index.html] but this seems to be concerned with video capture and storage. I would like to be able to play with the video pre-storage. Thanks, 回答1: Depending on how real-time you want the data

Android Video Player libraries with cache video

为君一笑 提交于 2019-12-04 18:58:12
问题 I developed android app which is based on video listing,I face some problems that are, 1.When scroll a listview video need auto play 2.Need pause,stop,resume and full screen mode 3.Every time video is streaming 4.How to make cache videos and play without stream Is there any Lib or reference link,and advance Thanks 回答1: i suggest ExoPlayer, here is a good sample for caching, you can use VideoCache or OkHttpDataSource 来源: https://stackoverflow.com/questions/41585763/android-video-player

How to open video player in WebView?

梦想与她 提交于 2019-12-04 18:04:39
I've a WebApp showed with Webview. In those pages I've some links to videos (MP4, 3GP...). When I click on the link, nothing happens.? public class luxgateway extends Activity { WebView myWebView; public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); myWebView = (WebView) findViewById(R.id.webview); myWebView.getSettings().setJavaScriptEnabled(true); myWebView.getSettings().setAllowFileAccess(true); WebViewClient webViewClient = new MyWebViewClient(); myWebView.setWebViewClient(webViewClient); myWebView.loadUrl("http://www.example

What is the differnce between accessing file from assets folder or SD card

烈酒焚心 提交于 2019-12-04 14:21:47
问题 I am developing an application where I have to use three different size's file (1mb, 5mb, 15mb). I searched, then came to know that we can keep these video in assets folder and can use those video. Secondly, I came to know that we can keep these videos in assets folder and installation time we can move all videos to SD card. when tried second approach faced problem due to bigger file size. So, can anyone please tell me what is difference between both approaches and which one I should use. Any

Online Video not Playing

血红的双手。 提交于 2019-12-04 11:34:47
I'm following a Tutorial to play Video in Android, Tutorial Here But when I run the Application on Emulator, it Gives me the following Error MediaPlayer error (1, -2147483648) Please Help Here's the Code of my Application JAVA package com.example.videoplayer; import android.media.MediaPlayer; import android.media.MediaPlayer.OnErrorListener; import android.media.MediaPlayer.OnPreparedListener; import android.net.Uri; import android.os.Bundle; import android.app.Activity; import android.content.Context; import android.graphics.PixelFormat; import android.util.Log; import android.view.Menu;

android how to resize video width and height in surface view for media player

耗尽温柔 提交于 2019-12-04 08:38:19
Want to resize the video in surface view I am Playing a video in Media Player with using a Surface view and holder for video... // but on implementing MediaPlayerControl on some devices say Micromax, iball, Akash tablet it gives error of abstract method not available as tracked by ACRA bug tracking. Now I want to have solution of mentioned problems: How to get media player controls active in all devices wihtout crashing due to abstract method as for media controller in some devices. How can I resize the surface view of video. The code is working f9 on samsung galaxy gt p1000 OS 2.2 and some

Multiple Video Files Simultaneously Playing in Android

无人久伴 提交于 2019-12-04 07:55:25
I had asked the same question for iOS on iPad but now I am trying to see if it's possible within Android. The response I received so far is no within iOS. If it's possible in Android please explain what API is used. Here's my original question referenced: Original Posting on iOS for Multiple Videos Playing Simultaneously on an iPad I tried to do so(2 VideoViews), but only one video played. It is because of linux decoder, which may be used as single instance only(from stack trace info). For now, to achieve multiple videos playback I try to use FFmpeg as video decoder and OpenGL for render