Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Smart Tv Samsung Player #777

Open
isnzenauz opened this issue Nov 21, 2024 · 33 comments
Open

Smart Tv Samsung Player #777

isnzenauz opened this issue Nov 21, 2024 · 33 comments

Comments

@isnzenauz
Copy link

isnzenauz commented Nov 21, 2024

Hey Flutter-Tizen Team,
Thanks for this a lot of support its a good job, thanks again.

Im build app of media player to display content of m3u8, not included channels its pure media player.
so i need to publish it to samsung store, the app already working stabel in android phones and android tv, web too.

In liste below my dependencies, i need to know if will work good in samsung tvs,
and what is good for me to display video lives and vods with good rendring no lags its vido_player_tizen or video_player_videohole, video_player_avplay

if its video_player_videohole or avplay can you please tell me how i will integrate it, and with videohole - avplay can i use just TV Emulator to test the player without Real Device

Thank you so mush <3.
Best regards

name: SAID Media TV PLAYER
description: A SUPER TV MEDIA PLAYER.
publish_to: 'none'
version: 1.0.0+1
environment:
sdk: '>=3.3.0 <4.0.0'
dependencies:
flutter:
sdk: flutter
cupertino_icons: ^1.0.8
http: ^1.2.2
flutter_animate: ^4.5.0
youtube_player_flutter: ^9.0.3
flutter_native_splash: ^2.4.1
device_uuid: ^0.0.4
hive_flutter: ^1.1.0
intl: ^0.19.0
google_fonts: ^6.2.1
heroicons_flutter: ^0.4.0
wakelock_plus: ^1.2.8
connectivity_plus: ^5.0.1
url_launcher: ^6.3.0
dio: ^5.6.0
email_otp: ^2.1.2
font_awesome_flutter: ^10.7.0
video_player: ^2.9.2
fvp: ^0.27.0
flutter_bloc: ^8.1.6
equatable: ^2.0.5
cached_network_image: ^3.4.1
media_kit: ^1.1.11 # Primary package.
media_kit_video: ^1.2.5 # For video rendering.
media_kit_libs_video: ^1.0.5 # Native video dependencies.
dpad_container: ^2.0.4

dev_dependencies:
flutter_test:
sdk: flutter

flutter_lints: ^2.0.0

flutter_native_splash:
android: true
color: "#352A6E"
image: assets/images/splash_logo.png
fullscreen: true
android_12:
image: assets/images/splash_logo.png
flutter:
uses-material-design: true
assets:
- assets/images/
- assets/images/animated/

@JSUYA
Copy link
Member

JSUYA commented Nov 25, 2024

Hi, thank you for your interesting.

You may need to add *_tizen packages. like this..

  http: ^1.2.2
  flutter_animate: ^4.5.0
  youtube_player_flutter: ^9.0.3
  flutter_native_splash: ^2.4.1
  device_uuid: ^0.0.4
  hive_flutter: ^1.1.0
  intl: ^0.19.0
  google_fonts: ^6.2.1
  heroicons_flutter: ^0.4.0
  wakelock_plus: ^1.2.8
  # connectivity_plus: ^5.0.1
  connectivity_plus: ^6.1.0
  connectivity_plus_tizen: ^1.2.0
  # url_launcher: ^6.3.0
  url_launcher: ^6.1.0
  url_launcher_tizen: ^2.1.2
  dio: ^5.6.0
  email_otp: ^2.1.2
  font_awesome_flutter: ^10.7.0
  # video_player: ^2.9.2
  video_player_avplay: ^0.5.5
  fvp: ^0.27.0
  flutter_bloc: ^8.1.6
  equatable: ^2.0.5
  cached_network_image: ^3.4.1
  media_kit: ^1.1.11 # Primary package.
  media_kit_video: ^1.2.5 # For video rendering.
  media_kit_libs_video: ^1.0.5 # Native video dependencies.
  dpad_container: ^2.0.4

  # In use in above packages
  package_info_plus_tizen: ^1.0.4
  sqflite_tizen: ^0.1.3

But there seem to be some problems.

  • It depends on which video API you used, and there is no guide. APIs like DurationRage may have different usability, and there may be unimplemented APIs.
    +) If you have any API requirements or requests, we can review them.
  • It seems to use youtube_player_flutter, but this is not supported.
  • Since avplay is a player that supports DRM, it has hardware dependency. Therefore, it cannot be used on the emulator.

Thanks

@isnzenauz
Copy link
Author

isnzenauz commented Nov 25, 2024

thank you so mush sir for your helping:

****can you please tell me what is solution or alternative working with It seems to use youtube_player_flutter.
**** what about this lottie: ^3.1.3 its working in tizen
****so if i fixed the package youtube_player_flutter i can to publish it ?because for navigation and ux ui its perfect i test it already with emulator.

Best Reagards.

@JSUYA
Copy link
Member

JSUYA commented Nov 26, 2024

Hi

****can you please tell me what is solution or alternative working with It seems to use youtube_player_flutter.

****so if i fixed the package youtube_player_flutter i can to publish it ?because for navigation and ux ui its perfect i test it already with emulator.

youtube_player_flutter is implemented using flutter_inappwebview. We do not support flutter_inappwebview. Therefore, youtube_player_flutter does not work on tizen.

The only alternative is youtube_player_iframe. This plugin is implemented using flutter_webview, and since Tizen supports flutter_webview, if you change some of the internal code of youtube_player_iframe, it will work on Tizen TV.

However, there are some issues due to Tizen TV webview. In webview, youtube video rendering is drawn on the surface for video play, not the webview surface. Therefore, the backgroundColor of the player and the scaffold(container) containing the player must be transparent.
I have written a sample code for this. I hope it will help you.
JSUYA/youtube_player_flutter@03affeb
(This code does not guarantee correct behavior.)

**** what about this lottie: ^3.1.3 its working in tizen

The lottie package has no platform dependency, so there is no problem running it on tizen.

@isnzenauz
Copy link
Author

you are helpful <3 thank you so mush.

what about this please:

https://pub.dev/packages/pod_player
https://pub.dev/packages/y_player

@JSUYA
Copy link
Member

JSUYA commented Nov 27, 2024

https://pub.dev/packages/pod_player

If you add video_player_tizen and run the example, everything works fine except for youtube play and vimeo play.
The youtube example throws Exception: videoQuality cannot be empty, but I don't know about this part.

https://pub.dev/packages/y_player

y_player uses media_kit, and since the media_kit_video plugin has implementation code for each platform, it seems to be platform dependent, and the tizen does not support it because there is no implementation for this.

@isnzenauz
Copy link
Author

If i test youtube package in emulator and working good in emulator should be work good in real device?!

@JSUYA
Copy link
Member

JSUYA commented Nov 27, 2024

The behavior of the emulator is not 100% guaranteed to work on a real TV device. Each TVs vary in model and device performance.
Please refer to the model list and TV specs. Hope it helps.
https://developer.samsung.com/smarttv/develop/specifications/media-specifications/2024-tv-video-specifications.html
https://developer.samsung.com/smarttv/develop/specifications/tv-model-groups.html

@isnzenauz
Copy link
Author

can you tell me if this package video player working with no problem with tizen:
https://pub.dev/packages/fvp

and this for youtube trailer its video player to:
https://pub.dev/packages/youtube_captioned_player

thank you so much for your help<3, i purchased yesterday tv tizen 8 2024 for testing,

@JSUYA
Copy link
Member

JSUYA commented Dec 2, 2024

can you tell me if this package video player working with no problem with tizen:
https://pub.dev/packages/fvp

I don't know much about fvp, but when I looked at fvp's git, it looks like fvp is a player implemented using libmdk while utilizing the interface of video_player.
You can check the information implemented for each platform here.
https://github.com/wang-bin/fvp/blob/master/pubspec.yaml
This plugin does not work because there is no implementation for Tizen.

and this for youtube trailer its video player to:
https://pub.dev/packages/youtube_captioned_player

In the case of youtube_captioned_player.. I couldn't find a special platform dependency,
so I changed video_player to video_player_avplay and modified some codes and ran the example, but it didn't work as I thought.
When I tried to output the URL obtained by analyzing YouTube manifest in another web browser player, the video did not played. I don't know much about YouTube video structure, so i can't more analysis.

@JSUYA
Copy link
Member

JSUYA commented Dec 6, 2024

and this for youtube trailer its video player to:
https://pub.dev/packages/youtube_captioned_player

In the case of youtube_captioned_player.. I couldn't find a special platform dependency, so I changed video_player to video_player_avplay and modified some codes and ran the example, but it didn't work as I thought. When I tried to output the URL obtained by analyzing YouTube manifest in another web browser player, the video did not played. I don't know much about YouTube video structure, so i can't more analysis.

Supporting youtube in flutter-tizen is our long-standing task.
So I reviewed youtube_captioned_player a bit more.

When I modified and checked it as below, I found out that the reason why the video is not displayed is that there are sources that do not provided muxed video.
When playing 'videoOnly`(video only), it plays well through the video_player_tizen package.
I saw that there are no platform-related issues with video playback.

   video_player: ^2.9.2
+  video_player_tizen: ^2.5.4
...
-      manifest = await yt.videos.streamsClient.getManifest(videoId);
+      manifest = await yt.videos.streams.getManifest(videoId);
+      print(manifest);
...

-    final videoStreamInfo = manifest.muxed.withHighestBitrate();
+    if (manifest.muxed.isEmpty) {
+      final videoStreamInfo = manifest.video.withHighestBitrate();
+      videoUrl = videoStreamInfo.url.toString();
+    } else {
+      final videoStreamInfo = manifest.muxed.withHighestBitrate();
+      videoUrl = videoStreamInfo.url.toString();
+    }

@isnzenauz
Copy link
Author

No problem i integred youtube_player_iframe like you told me,
Im working now for player i see fvp but idont know if will be work good or not its supported many codecs that why i need to use it because my project its for cros- platform samsung android appel tv

@isnzenauz
Copy link
Author

Hey Sir;
*** i integrate the Avplaye in my project, itest it in emulator sound of movies is working but movies no, iknow the player is working just in real device but i test it in emulator first and just sound working, after that i test it in real device (SAMSUNG SERIE 8 2024), and the sound not working like emulator and screen is black movies not runing,

video5958560609669751025.mp4

and i integrate the youtube_flutter_iframe like you told me and its not working give me wihte screen.

video5958560609669751029.mp4

Thank you so mush for all ur supprot.

@isnzenauz
Copy link
Author

any help please ?

@JSUYA
Copy link
Member

JSUYA commented Dec 10, 2024

Hey Sir; *** i integrate the Avplaye in my project, itest it in emulator sound of movies is working but movies no, iknow the player is working just in real device but i test it in emulator first and just sound working, after that i test it in real device (SAMSUNG SERIE 8 2024), and the sound not working like emulator and screen is black movies not runing,

video5958560609669751025.mp4
and i integrate the youtube_flutter_iframe like you told me and its not working give me wihte screen.

video5958560609669751029.mp4
Thank you so mush for all ur supprot.

Did you apply the appropriate privileges to video_player_avplay?
And you need a partner-level certificate to use the drmplay privilege.
https://github.com/flutter-tizen/plugins/tree/master/packages/video_player_avplay#required-privileges

I recommend that you first test the test url of the video you want to play in the examples of video_player_tizen and video_player_avplay.

You need to make some code changes to use youtube_flutter_iframe.
I tested the example this way.
JSUYA/youtube_player_flutter@03affeb
But I can't guarantee that this will work for you.

@isnzenauz
Copy link
Author

i test the video player tizen its work but av play not

@isnzenauz
Copy link
Author

example of video_player_avplay give me this errors:

(:11905): GStreamer-WARNING **: 05:02:36.295: Failed to load plugin '/lib/gstreamer-1.0/libgstffmpeg.so': libclearkey.so.0: cannot open shared object file: Operation not permitted
[I] [GC_INFO] GC_Start #1: Gen(0), Time(3883665 ms), Reason(0)
[I] [GC_INFO] GC_End #1: Gen(0), Time(3883667 ms)
[E]
(:11905): GStreamer-WARNING **: 05:02:51.217: Failed to load plugin '/lib/gstreamer-1.0/libgsthls.so': libclearkey.so.0: cannot open shared object file: Operation not permitted
[E]
(:11905): GStreamer-CRITICAL **: 05:02:56.862: gst_element_query: assertion 'GST_IS_ELEMENT (element)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:56.862: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GStreamer-CRITICAL **: 05:02:56.893: gst_element_query: assertion 'GST_IS_ELEMENT (element)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:56.893: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GStreamer-CRITICAL **: 05:02:56.923: gst_element_query: assertion 'GST_IS_ELEMENT (element)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:56.923: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:56.954: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:56.984: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:57.015: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:57.045: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:57.075: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:57.106: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:57.136: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:57.139: g_object_set: assertion 'G_IS_OBJECT (object)' failed
[E]
(:11905): GLib-GObject-CRITICAL **: 05:02:57.166: g_value_get_uint64: assertion 'G_VALUE_HOLDS_UINT64 (value)' failed
[E]
(:11905): GStreamer-WARNING **: 05:02:57.171: Failed to load plugin '/lib/gstreamer-1.0/libgstffmpeg.so': libclearkey.so.0: cannot open shared object file: Operation not permitted
apps/com.example.myapp/bin/Runner.dll: src/sstracksource.cpp:958: bool plusplayer::SsTrackSource::CreatePipeline_(): Assertion `pipeline_->demuxer' failed.
DotNET onSigabrt called on com.example.myapp
DotNET onSigsegv called

@isnzenauz
Copy link
Author

image

im aleady i have certifcate

@JSUYA
Copy link
Member

JSUYA commented Dec 11, 2024

Did you add privilege to tizen-manifest.xml?
This log was a certification issue in most cases. What is your tizen version?
If you have a shareable URL that we can test, please provide it as well.

@xiaowei-guan Could you please check this?

@isnzenauz
Copy link
Author

isnzenauz commented Dec 11, 2024

***yes already add the privilege and i test the example project of video_player_avplay,

i generate again the certificate with uuid of my tv samsung, tizen 8, its same problem

image

image

@xiaowei-guan
Copy link
Contributor

xiaowei-guan commented Dec 12, 2024

tizen 8,

@isnzenauz Hello, did you change the ap-version to 8.0?

<manifest package="org.tizen.video_player_avplay_example" version="1.0.0" api-version="8.0" xmlns="http://tizen.org/ns/packages">

@isnzenauz
Copy link
Author

tizen 8,

@isnzenauz Hello, did you change the ap-version to 8.0?

<manifest package="org.tizen.video_player_avplay_example" version="1.0.0" api-version="8.0" xmlns="http://tizen.org/ns/packages">

Yes sir, already do it in tizen-manifest.xml

image
image

@isnzenauz
Copy link
Author

ANy help please ?

@xiaowei-guan
Copy link
Contributor

ANy help please ?

Hello, you should run flutter-tizen clean after change api-version to 8.0. you can try this first.

if you still has this issue, are you a parthner of samsung? I think you shoud sign the app with partner level certificate.

@isnzenauz
Copy link
Author

Every modification i do flutter-tizen clean,

I sign the project with certificate with ly account samsung in studio tize and i give the device permission install apps,

If you have ready project i will happy to run it to see if the problem from me because i test the examples and my project to is not working

@xiaowei-guan
Copy link
Contributor

@isnzenauz Could you please refer to this page(https://developer.samsung.com/tv-seller-office/guides/membership/becoming-partner.html), if you want to use avplay plugin, you shoudl become a partner first, then you can create a partner level certificate to sign the app. if still can't use launch the sample app, I will request a USB certificate for you.

@isnzenauz
Copy link
Author

@xiaowei-guan im trying to get partner but i cant ?

image

@isnzenauz
Copy link
Author

any one of support can help me about this content manage because his refuse my email adresses

@xiaowei-guan
Copy link
Contributor

@xiaowei-guan im trying to get partner but i cant ?

image

The Email that need to be filled in is not yours, it's samsung content's manager Email.
I think you should follow below steps:
Input all information to create group > Becomes public group > Partnership confirmation by Samsung Contents Manager > Becomes partner group

https://seller.samsungapps.com/tv/membership/group-information

@isnzenauz
Copy link
Author

I do it but where i can get email of Samsung content manger

@xiaowei-guan
Copy link
Contributor

@xiaowei-guan
Copy link
Contributor

If still doesn't work, you can create a QA at here:
https://developer.samsung.com/tv-seller-office/guides/11-qa/asking-question.html

@isnzenauz
Copy link
Author

thanks i already open the qa i will see what happen with support and i will tell u

@isnzenauz
Copy link
Author

the support his give me email of content manager and i request the partnership im still waiting to approve it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants