GVKun编程网logo

对不起,此视频无法在Http streaming android中流式传输到此设备(该视频无法流式传输到此设备)

25

本文将分享对不起,此视频无法在Httpstreamingandroid中流式传输到此设备的详细内容,并且还将对该视频无法流式传输到此设备进行详尽解释,此外,我们还将为大家带来关于AndroidHLS流

本文将分享对不起,此视频无法在Http streaming android中流式传输到此设备的详细内容,并且还将对该视频无法流式传输到此设备进行详尽解释,此外,我们还将为大家带来关于Android HLS 流式传输并将视频录制到 Android 手机、Android videoView给我提醒“抱歉,此视频无法播放”?、Android – 使用Android Studio和Gradle的httpcore和httpmime的Proguard、android – 使用服务流式传输音频的相关知识,希望对你有所帮助。

本文目录一览:

对不起,此视频无法在Http streaming android中流式传输到此设备(该视频无法流式传输到此设备)

对不起,此视频无法在Http streaming android中流式传输到此设备(该视频无法流式传输到此设备)

我可以成功地从URL(服务器)流式传输一些视频,

但其他人(我的视频到我的服务器)不是.

您可以在我的代码中看到(工作/不工作)
我遇到了这个问题.
“抱歉,此视频无法流式传输到此设备”

以下代码:

String url = null;
    //      url = "rtsp://v5.cache5.c.youtube.com/CiILENy73wIaGQmC00ZlwwIDOxMYDSANFEgGUgZ2aWRlb3MM/0/0/0/video.3gp"; // Working
    //      url = "http://daily3gp.com/vids/747.3gp"; // Working
    url = "http://www.ooklnet.com/files/381/381489/video.mp4"; // Working
    //      url = "rtsp://184.72.239.149/vod/mp4:BigBuckBunny_115k.mov"; // Working
    //      url = "http://dl.dropBox.com/u/80419/santa.mp4"; // Working

    //      url = "http://trekvn.hostoi.com/encode_normal.mp4"; // Not Working
    //      url = "http://trekvn.hostoi.com/output_encode_mp4_Box.mp4"; // Not Working
    //      url = "http://www.ourserversite.com:14556/ingCloud/users/400010001/mp4_320p/e8d8535852a98c949640c5d618ac23d320131022174507.mp4"; // Not Working
    //      url = "http://trekvn.hostoi.com/mpeg_2_ts.ts"; // Not Working

    videoviewer.setVideoURI(Uri.parse(url));

    videoviewer.requestFocus();
    videoviewer.setKeepScreenOn(true);
    videoviewer.setonErrorListener(this);
    videoviewer.setonPreparedListener(this);

@Override
    public void onPrepared(MediaPlayer mp) {
           videoviewer.start()'
}

所有这些视频都可以在网站上播放,
格式为* .mp4(mpeg-4 part 10),视频:.H264,音频:aac.

请告诉我为什么,
以及如何解决它.

p / s:三星galaxy Tab 7“ – 2.2.1

谢谢,

解决方法:

这是许多人遇到的问题,确保您了解以下内容以解决问题.

通过我的经验和这个Sorry, this video cannot be played – streaming mp4 to android的答案

最后,我找到了原因和解决方案:

– 原因:几乎* .mp4文件是为了在iOS上开发焦点而生成的,并且具有编码:H264 Main.虽然Android端只能流和播放文件的编码为:H264 Baseline.

– 解决方案:我们需要从编码H264 Main转换为H264 Baseline(保证启用Web优化(在-mdat之前移动-moov atom)功能)

– 错误:

>抱歉,此视频无法用于流式传输到此设备.
>抱歉,此视频无法播放.

HandBrake工具是完成它的最简单,最便宜的方法.

谢谢,

p / s:但是如果使用这种方法,则需要将视频上传到服务器进行测试.

Android HLS 流式传输并将视频录制到 Android 手机

Android HLS 流式传输并将视频录制到 Android 手机

如何解决Android HLS 流式传输并将视频录制到 Android 手机?

我想通过连接到 IPCamera 在我的 android 应用程序中流式传输视频。我已成功配置 IPCamera 视频,以便能够通过 HTTP 流在谷歌浏览器中进行流式传输。我想使用 HLS 平台在我的 android 应用程序中流式传输相同的视频并录制正在流式传输的视频。我应该使用哪种技术?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

Android videoView给我提醒“抱歉,此视频无法播放”?

Android videoView给我提醒“抱歉,此视频无法播放”?

My Code::

public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);

        VideoView videoView = (VideoView) findViewById(R.id.videoView1);
        MediaController mediaController = new MediaController(this);
        mediaController.setAnchorView(videoView);

        Uri video = Uri
                .parse("www.logisticinfotech.com/client/Malasiya Cup/movie.mp4");
        videoView.setMediaController(mediaController);
        videoView.setVideoURI(video);
        videoView.start();

    }

错误::抱歉,无法播放此视频.

logcat的::

01-03 20:19:14.044: DEBUG/AndroidRuntime(454): >>>>>>>>>>>>>> AndroidRuntime START <<<<<<<<<<<<<<
01-03 20:19:14.044: DEBUG/AndroidRuntime(454): CheckJNI is ON
01-03 20:19:14.224: DEBUG/AndroidRuntime(454): --- registering native functions ---
01-03 20:19:14.874: INFO/ActivityManager(59): Starting activity: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 cmp=com.logistic.videoview/.MainActivity }
01-03 20:19:15.014: DEBUG/AndroidRuntime(454): Shutting down VM
01-03 20:19:15.044: DEBUG/dalvikvm(454): Debugger has detached; object registry had 1 entries
01-03 20:19:15.134: INFO/AndroidRuntime(454): NOTE: attach of thread 'Binder Thread #3' Failed
01-03 20:19:15.784: INFO/StagefrightPlayer(34): setDataSource('www.logisticinfotech.com/client/Malasiya Cup/movie.mp4')
01-03 20:19:15.805: ERROR/MediaPlayer(420): error (1, -2147483648)
01-03 20:19:15.834: INFO/ActivityManager(59): displayed activity com.logistic.videoview/.MainActivity: 821 ms (total 821 ms)
01-03 20:19:15.885: ERROR/MediaPlayer(420): Error (1,-2147483648)
01-03 20:19:15.885: DEBUG/VideoView(420): Error: 1,-2147483648

解决方法:

我建议您查看Android对支持的媒体格式的概述.该网站涵盖了从Android的第一个版本到最新版本的所有内容:

Android Supported Media Formats

我猜你正在尝试在你的应用程序中包含一个视频,并且它需要在所有设备上运行,因此我建议你继续尝试使用与SD类似的配置文件对视频进行编码(高质量)在上述网站上列出.

您可以使用大量免费视频转换器对视频进行编码 – 其中一个可能是Freemake Video Converter.

Android – 使用Android Studio和Gradle的httpcore和httpmime的Proguard

Android – 使用Android Studio和Gradle的httpcore和httpmime的Proguard

我正在开发Android Studio 1.0.2和Gradle 1.0.0的应用程序,使用Apache库httpmime和httpcore作为多部分实体。 这是我的build.gradle :

apply plugin: ''com.android.application'' android { compileSdkVersion 21 buildToolsversion "21.1.1" // Something wrong with the httP* libs packagingOptions { exclude ''meta-inf/DEPENDENCIES'' exclude ''meta-inf/NOTICE'' exclude ''meta-inf/LICENSE'' exclude ''meta-inf/DEPENDENCIES.txt'' exclude ''meta-inf/LICENSE.txt'' exclude ''meta-inf/NOTICE.txt'' exclude ''meta-inf/NOTICE'' exclude ''meta-inf/LICENSE'' exclude ''meta-inf/DEPENDENCIES'' exclude ''meta-inf/notice.txt'' exclude ''meta-inf/license.txt'' exclude ''meta-inf/dependencies.txt'' exclude ''meta-inf/LGPL2.1'' } defaultConfig { // ... } buildTypes { release { minifyEnabled true proguardFiles getDefaultProguardFile(''proguard-android.txt''),''proguard-rules.pro'' } } } dependencies { compile filetree(dir: ''libs'',include: [''*.jar'']) compile "com.android.support:support-v4:21.0.2" compile ''org.apache.httpcomponents:httpcore:4.3.2'' compile ''org.apache.httpcomponents:httpmime:4.3.5'' compile ''net.hockeyapp.android:HockeySDK:3.5.0'' }

应用程序本身和“正常”释放APK工作正常,但是当我尝试使用ProGuard时,出现以下错误消息:

Note: there were 157 duplicate class deFinitions. (http://proguard.sourceforge.net/manual/troubleshooting.html#duplicateclass) Warning:library class org.apache.http.auth.AuthenticationException extends or implements program class org.apache.http.ProtocolException Warning:library class org.apache.http.auth.MalformedChallengeException extends or implements program class org.apache.http.ProtocolException Warning:library class org.apache.http.auth.params.AuthParamBean extends or implements program class org.apache.http.params.HttpAbstractParamBean Warning:library class org.apache.http.client.NonRepeatableRequestException extends or implements program class org.apache.http.ProtocolException Warning:library class org.apache.http.client.RedirectException extends or implements program class org.apache.http.ProtocolException Warning:library class org.apache.http.client.entity.UrlEncodedFormEntity extends or implements program class org.apache.http.entity.StringEntity Warning:library class org.apache.http.client.methods.httpentityEnclosingRequestBase extends or implements program class org.apache.http.httpentityEnclosingRequest Warning:library class org.apache.http.client.methods.HttpRequestBase extends or implements program class org.apache.http.message.AbstractHttpMessage Warning:library class org.apache.http.client.methods.HttpUriRequest extends or implements program class org.apache.http.HttpRequest Warning:library class org.apache.http.client.params.AllClientPNames extends or implements program class org.apache.http.params.CoreConnectionPNames Warning:library class org.apache.http.client.params.AllClientPNames extends or implements program class org.apache.http.params.CoreProtocolPNames Warning:library class org.apache.http.client.params.ClientParamBean extends or implements program class org.apache.http.params.HttpAbstractParamBean Warning:library class org.apache.http.client.protocol.RequestAddCookies extends or implements program class org.apache.http.HttpRequestInterceptor Warning:library class org.apache.http.client.protocol.RequestDefaultHeaders extends or implements program class org.apache.http.HttpRequestInterceptor Warning:library class org.apache.http.client.protocol.RequestProxyAuthentication extends or implements program class org.apache.http.HttpRequestInterceptor Warning:library class org.apache.http.client.protocol.RequestTargetAuthentication extends or implements program class org.apache.http.HttpRequestInterceptor Warning:library class org.apache.http.client.protocol.ResponseProcessCookies extends or implements program class org.apache.http.HttpResponseInterceptor Warning:library class org.apache.http.conn.BasicManagedEntity extends or implements program class org.apache.http.entity.httpentityWrapper Warning:library class org.apache.http.conn.ManagedClientConnection extends or implements program class org.apache.http.HttpClientConnection Warning:library class org.apache.http.conn.ManagedClientConnection extends or implements program class org.apache.http.HttpInetConnection Warning:library class org.apache.http.conn.OperatedClientConnection extends or implements program class org.apache.http.HttpClientConnection Warning:library class org.apache.http.conn.OperatedClientConnection extends or implements program class org.apache.http.HttpInetConnection Warning:library class org.apache.http.conn.params.ConnConnectionParamBean extends or implements program class org.apache.http.params.HttpAbstractParamBean Warning:library class org.apache.http.conn.params.ConnManagerParamBean extends or implements program class org.apache.http.params.HttpAbstractParamBean Warning:library class org.apache.http.conn.params.ConnRouteParamBean extends or implements program class org.apache.http.params.HttpAbstractParamBean Warning:library class org.apache.http.cookie.MalformedCookieException extends or implements program class org.apache.http.ProtocolException Warning:library class org.apache.http.cookie.params.CookieSpecParamBean extends or implements program class org.apache.http.params.HttpAbstractParamBean Warning:library class org.apache.http.impl.client.ClientParamsstack extends or implements program class org.apache.http.params.AbstractHttpParams Warning:library class org.apache.http.impl.client.EntityEnclosingRequestWrapper extends or implements program class org.apache.http.httpentityEnclosingRequest Warning:library class org.apache.http.impl.client.RequestWrapper extends or implements program class org.apache.http.message.AbstractHttpMessage Warning:library class org.apache.http.impl.client.TunnelRefusedException extends or implements program class org.apache.http.HttpException Warning:library class org.apache.http.impl.conn.DefaultClientConnection extends or implements program class org.apache.http.impl.socketHttpClientConnection Warning:library class org.apache.http.impl.conn.DefaultResponseParser extends or implements program class org.apache.http.impl.io.AbstractMessageParser Warning:library class org.apache.http.impl.conn.LoggingSessionInputBuffer extends or implements program class org.apache.http.io.SessionInputBuffer Warning:library class org.apache.http.impl.conn.LoggingSessionOutputBuffer extends or implements program class org.apache.http.io.SessionOutputBuffer Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.client.HttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.client.methods.httpentityEnclosingRequestBase depends on program class org.apache.http.httpentity Warning:library class org.apache.http.client.methods.HttpRequestBase depends on program class org.apache.http.ProtocolVersion Warning:library class org.apache.http.client.methods.HttpRequestBase depends on program class org.apache.http.RequestLine Warning:library class org.apache.http.conn.scheme.PlainSocketFactory depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.conn.scheme.SchemeRegistry depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.conn.scheme.socketFactory depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.conn.ssl.SSLSocketFactory depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpRequestExecutor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.ConnectionReuseStrategy Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.BasicHttpProcessor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpRequestExecutor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.ConnectionReuseStrategy Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.BasicHttpProcessor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpResponseInterceptor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpRequestInterceptor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpResponse Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpRequestExecutor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.ConnectionReuseStrategy Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpProcessor Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpHost Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.HttpRequest Warning:library class org.apache.http.impl.client.AbstractHttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.impl.client.DefaultHttpClient depends on program class org.apache.http.params.HttpParams Warning:library class org.apache.http.impl.client.DefaultHttpClient depends on program class org.apache.http.protocol.HttpRequestExecutor Warning:library class org.apache.http.impl.client.DefaultHttpClient depends on program class org.apache.http.protocol.HttpContext Warning:library class org.apache.http.impl.client.DefaultHttpClient depends on program class org.apache.http.ConnectionReuseStrategy Warning:library class org.apache.http.impl.client.DefaultHttpClient depends on program class org.apache.http.protocol.BasicHttpProcessor Warning:library class org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager depends on program class org.apache.http.params.HttpParams Warning:there were 109 instances of library classes depending on program classes. You must avoid such dependencies,since the program classes will be processed,while the library classes will remain unchanged. (http://proguard.sourceforge.net/manual/troubleshooting.html#dependency) :app:proguardRelease Failed Error:Execution Failed for task '':app:proguardRelease''. > java.io.IOException: Please correct the above warnings first.

根据错误消息中给出的有关重复类定义和库类的依赖程序类给出的链接我应该使用类似-injars ...或-libraryjars ...在我的proguard-rules.pro 。 但是因为我使用远程库而不是.jar文件,所以我不知道如何使用这些proguard选项。

所以我googlesearch我的问题的解决scheme,并发现了几种可能性:

模拟器不会closuresUbuntu

Android ADB – 无法识别LG G Pad(VK810)

在没有networking摄像头对话框的情况下启动Android模拟器

即使位于由错误指定的位置,Android Studio也无法检测到appt

Valgrind在Android 5 / L崩溃

我下载了jar子,将它们添加到我的applibs文件夹中,并为这两个jar子添加了选项-libraryjar和/或-injar ,但是没有任何组合可用:无法find或读取文件,或者获得了错误,其中一个库将被处理两次。

我也尝试了-keep class org.apache.** ,- -keep interface org.apache.** ,- -keep public class org.apache.** {*;} ,- -keepnames class org.apache.** {*;}各种组合-keepnames class org.apache.** {*;}有或没有{*;}但没有一个工作。

我也尝试了-dontwarn org.apache.**或-dontwarn org.apache.http.**选项,它在创buildAPK时没有给出任何错误,但是当我尝试使用http * libsbuild立Internet连接时应用程序,应用程序崩溃,像一个NoSuchMethodExceptionexception。

所以我的问题是:有没有使用远程库和proguard的方法? 或者,至less可以通过在我的 libs文件夹中包含.jars文件?

非常感谢你

清除使用PhoneGap上传ios应用程序的步骤

Android API中断

在x86上执行x86 Android AVD在Linux上的工作吗?

Android / Linux线程join超时

Android Studio:使用Mac(OSX)和Windows为同一项目更改SDK位置

那么我正在使用这样的

-dontwarn org.apache.commons.** -keep class org.apache.http.** { *; } -dontwarn org.apache.http.**

另外我编译使用我的libs文件夹内的jar

compile files(''libs/httpmime-4.3.5.jar'') compile files(''libs/httpclient-4.3.5.jar'') compile files(''libs/httpclient-cache-4.3.5.jar'') compile files(''libs/httpcore-4.3.2.jar'')

而不是从maven使用

总结

以上是小编为你收集整理的Android – 使用Android Studio和Gradle的httpcore和httpmime的Proguard全部内容。

如果觉得小编网站内容还不错,欢迎将小编网站推荐给好友。

android – 使用服务流式传输音频

android – 使用服务流式传输音频

请看一下我简单的三方法Service类,它可以流式传输音频并直接播放.

public class StreamService extends Service {

    private static final String TAG = "MyService";
    String url;
    MediaPlayer mp;

    @Override
    public void onCreate() {
        Toast.makeText(this, "My Service Created", Toast.LENGTH_LONG).show();
        Log.d(TAG, "onCreate");

        mp = new MediaPlayer();
        mp.setAudioStreamType(AudioManager.STREAM_MUSIC);
    }

    @Override
    public void onDestroy() {
        Toast.makeText(this, "My Service Stopped", Toast.LENGTH_LONG).show();
        Log.d(TAG, "onDestroy");

        mp.stop();
    }

    @Override
    public int onStartCommand(Intent intent, int flags, int startid) {
        Toast.makeText(this, "My Service Started", Toast.LENGTH_LONG).show();
        Log.d(TAG, "onStart");

        url = intent.getExtras().getString("url");
        try {
            mp.setDataSource(url);
            mp.prepare();
            mp.start();
        } catch(Exception e){}          
        return START_STICKY;
    }
}

在我的活动中,我有两个按钮来播放/停止媒体文件:

> playButton执行此操作:

Intent i = new Intent(this, StreamService.class);
i.putExtra("my_mp3_url_string");
startService(i);

> stopButton执行:

stopService(new Intent(this, StreamService.class));

现在,我有一些问题:

>我如何实现pauseButton?我想暂停在服务中运行的媒体
>我的播放/停止媒体/服务的方式是否正确?有没有更好的方法?
>我如何(定期)从我的服务更新我的活动用户界面?我需要添加一些东西吗?

解决方法:

我建议不要使用服务的生命周期来开始和停止播放.使用这种方法意味着每次想要启动新流时,必须通过启动新服务来减慢代码的速度.只需让相同的服务播放所有内容,您就可以节省一些时间.虽然这并不意味着它应该保持running all the time.

要实现这一点(并且能够暂停),您需要在启动后绑定到服务.使用绑定的服务,您将能够对其进行调用 – 例如暂停,播放,停止等.

以下是一些可以帮助您找到所需内容的链接:

> Using a Service with MediaPlayer
> Binding to a Service

我们今天的关于对不起,此视频无法在Http streaming android中流式传输到此设备该视频无法流式传输到此设备的分享已经告一段落,感谢您的关注,如果您想了解更多关于Android HLS 流式传输并将视频录制到 Android 手机、Android videoView给我提醒“抱歉,此视频无法播放”?、Android – 使用Android Studio和Gradle的httpcore和httpmime的Proguard、android – 使用服务流式传输音频的相关信息,请在本站查询。

本文标签: