Giter Club home page Giter Club logo

Comments (5)

crazecoder avatar crazecoder commented on August 29, 2024

First, the url has some error

04-23 05:26:46.679 9215-9422/com.crazecoder.fluttergsyplayerexample E/IJKMEDIA: https://r3---sn-cvh76nez.googlevideo.com/videoplayback?id=63fea2322266d75a&itag=22&source=picasa&begin=0&requiressl=yes&pl=24&sc=yes&ttl=transient&ei=2iq-XJuVOYTM1gKZm7TIDw&susc=ph&app=fife&mime=video/mp4&cnr=14&dur=1475.163&lmt=1555929420020340&ipbits=0&keepalive=yes&ratebypass=yes&ip=134.19.181.231&expire=1555973882&sparams=app,cnr,dur,ei,expire,id,ip,ipbits,itag,lmt,mime,mip,mm,mn,ms,mv,pl,requiressl,sc,source,susc,ttl&signature=496BCECE113BD8BB210E99694CBE78F063CA784C.71BDEACC63FC2A2AAE7704309044E65719202872&key=cms1&title=(720P%20-%20mp4)%20Pokemon+Sun+%26+Moon+Episode+118.mp4&cms_redirect=yes&mip=123.201.249.80&mm=30&mn=sn-cvh76nez&ms=nxu&mt=1555972243&mv=u: Protocol not found

and, your android theme

java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.

from flutter_ijkplayer_beta.

dheerajbred avatar dheerajbred commented on August 29, 2024

Hi,

Thanks a lot for replying. That link is a google video, it will expire within 60mins. The video was working. I changed the link and tried again, but I am facing the same issue.

This is my manifest xml

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    package="com.crazecoder.fluttergsyplayerexample">

    <!-- The INTERNET permission is required for development. Specifically,
         flutter needs it to communicate with the running application
         to allow setting breakpoints, to provide hot reload, etc.
    -->
    <uses-permission android:name="android.permission.INTERNET"/>

    <!-- io.flutter.app.FlutterApplication is an android.app.Application that
         calls FlutterMain.startInitialization(this); in its onCreate method.
         In most cases you can leave this as-is, but you if you want to provide
         additional functionality it is fine to subclass or reimplement
         FlutterApplication and put your custom class here. -->
    <application
        android:name="io.flutter.app.FlutterApplication"
        android:label="flutter_gsyplayer_example"
        android:icon="@mipmap/ic_launcher"
        tools:replace="android:label"
        tools:ignore="GoogleAppIndexingWarning">
        <activity
            android:name=".MainActivity"
            android:launchMode="singleTop"
            android:theme="@style/LaunchTheme"
            android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density"
            android:hardwareAccelerated="true"
            android:windowSoftInputMode="adjustResize">
            <!-- This keeps the window background of the activity showing
                 until Flutter renders its first frame. It can be removed if
                 there is no splash screen (such as the default splash screen
                 defined in @style/LaunchTheme). -->
            <meta-data
                android:name="io.flutter.app.android.SplashScreenUntilFirstFrame"
                android:value="true" />
            <intent-filter>
                <action android:name="android.intent.action.MAIN"/>
                <category android:name="android.intent.category.LAUNCHER"/>
            </intent-filter>
        </activity>
    </application>
</manifest>

I tried changing it to android:theme="@style/Theme.AppCompat". But it did nothing.

Same error:

4-23 18:51:57.069 30828-31138/com.crazecoder.fluttergsyplayerexample E/IJKMEDIA: https://www9.mp4upload.com:282/d/rsxwxfqlz3b4quuo6ovqsp2slh3jtcbo3zsxfyw3ytk6pr43vysfl5p4/video.mp4: Protocol not found
04-23 18:51:57.144 30828-30828/com.crazecoder.fluttergsyplayerexample E/tv.danmaku.ijk.media.player.IjkMediaPlayer: Error (-10000,0)
04-23 18:51:57.274 30828-30828/com.crazecoder.fluttergsyplayerexample E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.crazecoder.fluttergsyplayerexample, PID: 30828
    java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.
        at androidx.appcompat.app.AppCompatDelegateImpl.createSubDecor(AppCompatDelegateImpl.java:555)
        at androidx.appcompat.app.AppCompatDelegateImpl.ensureSubDecor(AppCompatDelegateImpl.java:518)
        at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:466)
        at androidx.appcompat.app.AppCompatDialog.setContentView(AppCompatDialog.java:94)
        at androidx.appcompat.app.AlertController.installContent(AlertController.java:232)
        at androidx.appcompat.app.AlertDialog.onCreate(AlertDialog.java:279)
        at android.app.Dialog.dispatchOnCreate(Dialog.java:553)
        at android.app.Dialog.show(Dialog.java:289)
        at androidx.appcompat.app.AlertDialog$Builder.show(AlertDialog.java:1007)
        at com.crazecoder.media.IjkVideoView$5.onError(IjkVideoView.java:582)
        at tv.danmaku.ijk.media.player.AbstractMediaPlayer.notifyOnError(AbstractMediaPlayer.java:106)
        at tv.danmaku.ijk.media.player.IjkMediaPlayer$EventHandler.handleMessage(IjkMediaPlayer.java:1020)
        at android.os.Handler.dispatchMessage(Handler.java:102)
        at android.os.Looper.loop(Looper.java:145)
        at android.app.ActivityThread.main(ActivityThread.java:6912)
        at java.lang.reflect.Method.invoke(Native Method)
        at java.lang.reflect.Method.invoke(Method.java:372)
        at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
04-23 18:51:57.329 2740-31144/? E/android.os.Debug: ro.product_ship = true

This is my project: https://we.tl/t-K6FbmPr8MZ

from flutter_ijkplayer_beta.

crazecoder avatar crazecoder commented on August 29, 2024

Your project is not flutter_ijkplayer_beta, but flutter_gsyplayer, and your project androidTestImplementation androidx

from flutter_ijkplayer_beta.

dheerajbred avatar dheerajbred commented on August 29, 2024

I am using flutter_ijkplayer_beta by using this git itself.
This is my pubspec.yaml: http://icecream.me/35f69507507bb72a6b956f29a12b65e4

As for androidx, I tried adding

android.useAndroidX=true
android.enableJetifier=true to gradle.properties 

and

refractor > migrate to androidx
http://icecream.me/bdfe3cb893236ad649a343d0fe205ea7

and both.

All these are giving me the same error.

It'd be great if you can add an example or something so that we can understand clearly. This player is just amaaazing and is undoubtedly the best video player for flutter. I really just want to use it on androidx too.

from flutter_ijkplayer_beta.

crazecoder avatar crazecoder commented on August 29, 2024

9a29f44
example

from flutter_ijkplayer_beta.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.