Closed deckameron closed 4 years ago
Hi @deckameron.
I have tried to update to 2.9.0 in november, and was able to build module with it, but I couldn't get it work with Titanium because of Java 8:
Turn on Java 8 compiler support for the ExoPlayer library. Apps may need to add compileOptions { targetCompatibility JavaVersion.VERSION_1_8 } to their gradle settings to ensure bytecode compatibility.
Ticket in Appcelerators JIRA.
If you want to try it yourself: https://github.com/NetrisTV/ti.exoplayer/tree/test-2.9.1
git fetch origin
git checkout -b test-2.9.1 origin/test-2.9.1
cd android
ti clean
rm lib/*.aar lib/*.jar
cd ..
./gradlew app:tiBuild
Thank you @drauggres ! I will give it a try.
[EDIT] Just tried to build it and got the following error:
[ERROR] Failed to compile Java source files:
[ERROR] build
[ERROR] Likely fix is to remove from proxy.propertyAccessors listing, as both getter and setter methods are defined.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:tiBuild'.
> Process 'command 'ti'' finished with non-zero exit value 1
It has something to do with this part of VideoPlayerProxy.java
// clang-format off
@Kroll.proxy(creatableInModule = TiExoplayerModule.class, propertyAccessors = {
TiC.PROPERTY_AUTOPLAY,
TiC.PROPERTY_DURATION,
TiC.PROPERTY_END_PLAYBACK_TIME,
TiC.PROPERTY_INITIAL_PLAYBACK_TIME,
TiC.PROPERTY_PLAYABLE_DURATION,
TiC.PROPERTY_REPEAT_MODE,
TiC.PROPERTY_URL,
TiExoplayerModule.PROPERTY_CONTENT_EXTENSION,
TiExoplayerModule.PROPERTY_CONTENT_TYPE,
TiExoplayerModule.PROPERTY_DRM_KEY_REQUEST_PROPERTIES,
TiExoplayerModule.PROPERTY_DRM_LICENSE_URL,
TiExoplayerModule.PROPERTY_DRM_MULTI_SESSION_EXTRA,
TiExoplayerModule.PROPERTY_DRM_SCHEME_UUID_EXTRA,
TiExoplayerModule.PROPERTY_PREFER_EXTENSION_DECODERS,
TiExoplayerModule.PROPERTY_LINEAR_GAIN,
TiExoplayerModule.PROPERTY_SURFACE_TYPE
})
Do you have any ideia how to solve it?
Sorry, I'm still on 7.4.1. Fix for 7.5.0 to the same branch.
BTW, It would be better if you just add new comments instead of editing (if this is not a typo or something like that). Github doesn't send notifications when comments are modified, only for new ones.
@deckameron You can try to build module from test-2.9.6 branch.
const ExoPlayer = require("ru.netris.mobile.exoplayer");
const videoPlayer = ti_exoplayer.createVideoPlayer({
...
surfaceType: ExoPlayer.SURFACE_TYPE_SPHERICAL_VIEW
});
If you don't have playservices in your app then comment out extension-ima
in app/build.gradle
or just delete extension-ima-*.aar
from lib
directory after module unpacking.
Hi @drauggres I tried building the module but I got this error:
[ERROR] /Users/sandrobarnabe/Documents/Modules/ti.exoplayer-test-2.9.6/android/build/intermediates/res/merged/layout/player_view_none.xml:2: error: No resource identifier found for attribute 'surface_type' in package 'ru.netris.mobile.exoplayer'
/Users/sandrobarnabe/Documents/Modules/ti.exoplayer-test-2.9.6/android/build/intermediates/res/merged/layout/player_view_spherical_view.xml:2: error: No resource identifier found for attribute 'surface_type' in package 'ru.netris.mobile.exoplayer'
/Users/sandrobarnabe/Documents/Modules/ti.exoplayer-test-2.9.6/android/build/intermediates/res/merged/layout/player_view_surface_view.xml:2: error: No resource identifier found for attribute 'surface_type' in package 'ru.netris.mobile.exoplayer'
/Users/sandrobarnabe/Documents/Modules/ti.exoplayer-test-2.9.6/android/build/intermediates/res/merged/layout/player_view_texture_view.xml:2: error: No resource identifier found for attribute 'surface_type' in package 'ru.netris.mobile.exoplayer'
[ERROR] Failed to generate R class
Strange, just built it on different machine. https://github.com/NetrisTV/ti.exoplayer/releases/tag/2.2.0-alpha
Hi @drauggres,
I was looking for way to use 360 videos (surface_type : "spherical_view") and noticed that it is only possible in version 2.9.0. It is now in 2.9.4.
Could you please update it to a newer version? :-) Thank you!