Base HTML5 Player features?

7 posts, 0 answers
  1. Brian Azzi
    Brian Azzi avatar
    65 posts
    Member since:
    Mar 2010

    Posted 28 Jan 2014 Link to this post

    Hello... does the MediaPlayer support the native underlying HTML5 video tag properties / methods?

    In particular, I am interested in playing a video with multiple audio tracks. The HTML5 spec outlines this (via audioTrackList), but it seems to be only implemented by IE 10/11 at the moment. In IE 10 or 11, if you load a video with multiple audio tracks, you get an audio selection menu / toolbar item. I don't specifically need this toolbar item, but I would like to be able to a) see if there are multiple audio tracks, and b) programmatic-ally set which one to play.

    Thanks,
    -Brian
  2. Radoslav
    Admin
    Radoslav avatar
    1564 posts

    Posted 31 Jan 2014 Link to this post

    Hello Brian,

    Unfortunately the RadMediaPlyer does not wrap audioTrackList functionality. However you can log the audioTrackList as a feature request into our public portal. Thus other users can see it and they can vote for it. The public portal can be found here: http://feedback.telerik.com/Project/108
    Also all available properties and methods of the RadMediaPlayer can be fond here:
    http://www.telerik.com/help/aspnet-ajax/mediaplayer-client-side-basics.html
    Additionally if you need some specific method or property from the video or audio elements you can get them via client side $find("RadMediaPlayer1").currentPlayer.media property of the player which contains video or audio element.  

    Regards,
    Radoslav
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the UI for ASP.NET AJAX, subscribe to the blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Brian Azzi
    Brian Azzi avatar
    65 posts
    Member since:
    Mar 2010

    Posted 31 Jan 2014 in reply to Radoslav Link to this post

    Thanks for the reply... that's actually very helpful that the base video element is exposed that way! (Some other HTML5 wrappers do not properly expose the element, and I can't get at the media.audioTracks property in IE... which allows setting & retrieving the audio tracks). 

    Is there a good way to add elements to the toolbar (custom button for example)? it would be nice to have my UI modifications in the player controls area instead of a separate area so that they would be visible in full screen mode / etc.

    Thanks again, good tip.
  5. Radoslav
    Admin
    Radoslav avatar
    1564 posts

    Posted 04 Feb 2014 Link to this post

    Hello Brian,

    Unfortunately we do not have built in functionality into the RadMediaPlayer control for inserting additional elements into its toolbars. You can get the toolbar wrapper element with following code
    $find("RadMediaPlayer1").toolbar.get_wrapper()
    and manually to insert elements with javascript. However please note that in this case new elements can broke the toolbar visually because it is not designed to have additional elements. 

    If you need further assistance, do not hesitate to contact us again.

    Regards,
    Radoslav
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the UI for ASP.NET AJAX, subscribe to the blog feed now.
  6. Brian Azzi
    Brian Azzi avatar
    65 posts
    Member since:
    Mar 2010

    Posted 05 Feb 2014 Link to this post

    One more quick question... how do I access / enable closed captioning via the HTML5 tracks? (I have a caption file). Do I set this up as a separate RadMediaSource? Is there a better way to access the markup for the underlying HTML5 player?
  7. Brian Azzi
    Brian Azzi avatar
    65 posts
    Member since:
    Mar 2010

    Posted 05 Feb 2014 Link to this post

    In regard to my above post... I found a way to at least enable captions (though it seems like a bit of a hack). In script, I get the player media element, then modify the innerHTML manually to add the caption track XML.

    media.innerHTML += '<track label="English Captions" srclang="en" kind="captions" src="URL HERE TO.vtt" type="text/vtt" default />';

    Obviously, there is no Telerik UI CC button (unfortunate)... so I'd have to create my own UI button... again, leading me to the whole question about "full screen" and the controls.
  8. Radoslav
    Admin
    Radoslav avatar
    1564 posts

    Posted 07 Feb 2014 Link to this post

    Hi Brian,

    Unfortunately we do not have Closed Caption button into the MediaPlayer. However as I said in my previous post you can log this as a feature request here:
    http://feedback.telerik.com/Project/108
    If it appears to be a common request and attainable enhancement, you may see it included in a future version of the product.

    If you need further assistance, do not hesitate to contact us again.

    Regards,
    Radoslav
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the UI for ASP.NET AJAX, subscribe to the blog feed now.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017