Samsung / Tizen-CSharp-Samples

Tizen C# Samples for Mobile, Wearable, and TV profiles.
Apache License 2.0
237 stars 224 forks source link

Video Player sample /Navigating between controls #18

Closed ahmad-crossplatform closed 6 years ago

ahmad-crossplatform commented 6 years ago

Hello there , I just started to read about Tizen and the ability to do so with Xamarin . I just cannot find a sample of video player for the TV , I tried to clone git://git.tizen.org/profile/tv/apps/dotnet/sample/videoplayer but it has no files.

the other topic that might be answered if I have managed to clone that solutoin is : do you have a recommended pattern to handle the events coming from the remote to navigate between different controls ?

sgchoi5 commented 6 years ago

Hello, We are trying to add more samples for Mobile/TV/Wearable. In case of Video, you can refer to Player sample for mobile first from DEV branch.

Tizen C# Sample Page: https://developer.tizen.org/ko/development/sample/.net-application/tizen-samples PlayerSample for Mobile: https://github.com/Samsung/Tizen-CSharp-Samples/tree/dev/Mobile/PlayerSample

The code of "dev" branch means it is not yet ready for public release. plz, consider that.

thanks Ben

rookiejava commented 6 years ago

@ahmad-crossplatform This sample app is helpful to you.

ahmad-crossplatform commented 6 years ago

@sgchoi5 @rookiejava thank you guys , how about handling the remote control directions ? Is there any best recommendation ?

ahmad-crossplatform commented 6 years ago

hello again , does any one have this but using CustomRenderes instead of implementing it as service ?

rookiejava commented 6 years ago
  1. In order to handle key events, you can use ElmSharp.EcoreEvent as below.
// Register key event callbacks for the window using the EcoreEvent.
EcoreEvent<EcoreKeyEventArgs> _keyUp = new EcoreEvent<EcoreKeyEventArgs>(EcoreEventType.KeyUp, EcoreKeyEventArgs.Create);

 _keyUp.On += (s, e) =>
{
 // write your code here using  e.Keyname and e.KeyCode
}

please refer to KeyCode. for more keycode details.

  1. Video Player You can make your own custom renderer for either VideoView or VideoPlayer refer to the sample app mentioned above. There is no big difference. And, we are preparing to contirubute a popoluar open source Xamarin.Forms media player plugins for tizen such as MediaManger. You can use these plugins for your video player app when it available. (I'm not sure the date but we hope soonish.)
hallower commented 6 years ago

@ahmad-crossplatform

Hi

This is not an answer for your question but I’d like to introduce TV video player sample and a lecture. I think it’s quite helpful for making your own Video Player.

Xamarin Forms TV App Development for Tizen http://tizenappschool.org/tutorial/71/contents/1

Sample code https://s3-us-west-1.amazonaws.com/tizenschool/97/Lect3_Snapshot09_Add_PlayerButton_Final.zip

Actually the sample code is related with below lectures that is describe how to make a video player on Tizen TV in detail, but those are written as Korean language. I leave URLs of them for the information.

Cross Platform TV Application Development http://tizenappschool.org/tutorial/95/contents/1 http://tizenappschool.org/tutorial/97/contents/1

ahmad-crossplatform commented 6 years ago

@hallower thanks a lot , but for some reason I cannot see the media samples ... like the videos ... where do you get that from ?