Code Monkey home page Code Monkey logo

android-exoplayer2-ext-icy's People

Contributors

ovophoedo avatar saschpe avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

android-exoplayer2-ext-icy's Issues

Metadata out of sync

I suspect, due to ExoPlayer2 buffering the audio part of the stream, I find that the metadata updates come at a different time to the song change.. around 4-5 seconds (which Is why I think audio buffer).. since some of the audio files on my radio station are short intro's/drops/id's etc, do you think there is a way to attempt to keep the metadata updates in sync with the audio stream, based off the amount of data in the buffer?

Supertypes of the following classes cannot be resolved

After migrating to AndroidX and updating gradle dependencies. I'm getting a lot of unresolved reference from ExoPlayer2 and a compile error below:

 
Supertypes of the following classes cannot be resolved. Please make sure you have the required dependencies in the classpath:
    class saschpe.exoplayer2.ext.icy.IcyHttpDataSourceFactory, unresolved supertypes: com.google.android.exoplayer2.upstream.HttpDataSource.BaseFactory

I am using gradle 5.4.1
and here is my build.gradle dependencies


dependencies {
        classpath 'com.google.gms:google-services:4.2.0'
        classpath 'io.fabric.tools:gradle:1.28.1'
        classpath 'com.android.tools.build:gradle:3.4.1'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.31"
        classpath "gradle.plugin.org.jlleitschuh.gradle:ktlint-gradle:4.1.0"
        classpath "android.arch.navigation:navigation-safe-args-gradle-plugin:1.0.0"
    }
}

Any insight and help would be appreciated. Thanks!

Gradle Sync Issue

When building I get the following warning:
WARNING: API 'variant.getJavaCompile()' is obsolete and has been replaced with 'variant.getJavaCompileProvider()'.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getJavaCompile(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
Affected Modules: exoplayer2-ext-icy

Used gradle Version: 4.10.1
Android plugin Version: 3.3.0

Get image/artist associated with MetaData

Hi,

Thank you for making our work easy. I am in the requirement to show current play's artist, song an associated image. I am having trouble to find the image.

I tried to look into IcyMetadata class but it contains only streamTitle and streamUrl, Is there any way to get Artist and Image URL?

I appreciate it.

Thanks,

Upgrading to Gradle 5 causes a deprecation warning.

When trying to upgrade to Gradle 5, we receive this deprecation warning

WARNING: API 'variant.getJavaCompile()' is obsolete and has been replaced with 'variant.getJavaCompileProvider()'.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getJavaCompile(), use -Pandroid.debug.obsoleteApi=true on the command line to display more information.
Affected Modules: exoplayer2-ext-icy

This is caused by this line of code https://github.com/saschpe/android-exoplayer2-ext-icy/blob/master/exoplayer2-ext-icy/build.gradle#L78

Add support for raw icy-metadata read

We would like to extract more information than default values, like this
StreamTitle='';StreamUrl='';metadata='adswizzContext=11111';adw_ad='true';durationMilliseconds='29884';adId='44411';insertionType='midroll';

So I suggest to made following changes in original code

                ....
        IcyMetadata icyMetadata = new IcyMetadata();
        icyMetadata.rawMetadata = metaDataString;
                ....
    public final class IcyMetadata {
        String streamTitle;
        String streamUrl;
        String rawMetadata;

        public String getStreamTitle() {
            return streamTitle;
        }

        public String getStreamUrl() {
            return streamUrl;
        }

        public String getRawMetadata() {
            return rawMetadata;
        }

        @Override
        public String toString() {
            return "IcyMetadata{" +
                    "streamTitle='" + streamTitle + '\'' +
                    ", streamUrl='" + streamUrl + '\'' +
                    ", rawMetadata='" + rawMetadata + '\'' +
                    '}';
        }
    }

Only first block of MetaData is reported

Since the upgrade to ExoPlayer 2.10, only the first block of meta data from the stream is reported to listeners. Subsequent blocks are ignored.

You can test with the steam https://audio.maxi80.com

The culprit is this line of code 537a1b6#diff-039576ecd822048f37ed9e534e84b411R171 added in this commit 537a1b6

The metaDataIntervalInBytes is reset to zero after the first block is read. This is incorrect as this value is constant during the entire duration of the stream.

Unfortunately, fixing this is more than just deleting this line of code. I am investigating and will eventually send a PR when I will find a solution.

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.