Forum Discussion

astudios's avatar
astudios
Channel Surfer
16 years ago

maintain original video aspect ratio..?

hello,

i'm a new roku developer and i have a simple question.

many of our videos are still in 4:3 format. but we have the roku connected to a 16:9 tv. when we attempt to play one of our videos using the "simplevideoplayer" sample program, it is stretched pretty badly. is there any way we can tell roku to play the video and maintain the original aspect ratio of the video itself? we are streaming the H.264-encoded video via the HLS protocol.

thank you!
steven

18 Replies

  • astudios's avatar
    astudios
    Channel Surfer
    "RokuKevin" wrote:
    astudios,

    From your description, it sounds to me that Wowza is not providing the resolution information encoded in the sequence headers in the transport stream... The output from FFMpeg and Windows Media Encoder both play at the proper resolution on the Roku because the Roku can read the resolution headers from its output. When putting those encodings through the Wowza server, the resolution information gets lost.

    I recommend working with Wowza to resolve this. I'm sure we'd all welcome an update on your findings.

    --Kevin


    kevin, thanks for the reply. i have copied your response in a WOWZA forum where hopefully their tech will be able to help shed some light on this issue. just so you know, it seems this issue was already brought up in the WOWZA forum by someone else and here's how they responded:

    "This [resolution] information is sent in the PPS and SPS NAL units of each key frame. We ensure that we inject SPS and PPS NAL units if they do not exist. If there is something more than this that needs to be done then I am not sure."

    so it appears that WOWZA is saying that they are indeed sending the necessary resolution information to you for HLS streaming.

    would you care to help further this discussion?

    thanks,
    steven
  • astudios's avatar
    astudios
    Channel Surfer
    with the release of the newest firmware update, the aspect ratio "stretching" problem seems to be solved! so, now 4:3 videos maintain their aspect ratios and are NOT stretched on a widescreen TV (before, they were most definitely stretched for both LIVE and VOD).

    okay, but there seems to be a new problem that perhaps someone can shed some light on?

    now, (with the newest firmware) any HLS-streamed video (VOD) does not play when you first click on it. i have to fast-forward a few minutes into it in order to get it to go. this did not happen with the previous firmware. in fact, i have two roku boxes here attached to my TV. one with the new firmware, one without. the one without can start playing the HLS video right away (although stretched), the new firmware box, does not play the HLS video -- but seems stuck on the loading screen for many minutes. i can fast-forward a few minutes into it and then it plays OK (maintaining aspect ratio).

    does anyone care to see this for yourself?

    load up our "sermonaudio" channel, go to the VIDEOS section, then click on any video to play and you'll see what i mean.

    thanks for any help,
    steven

    p.s. we are using WOWZA (latest version) on the back-end to HLS stream the videos. videos are all H.264+AAC and work just fine on iphones via HLS. thanks.
  • "astudios" wrote:
    now, (with the newest firmware) any HLS-streamed video (VOD) does not play when you first click on it. i have to fast-forward a few minutes into it in order to get it to go. this did not happen with the previous firmware. in fact, i have two roku boxes here attached to my TV. one with the new firmware, one without. the one without can start playing the HLS video right away (although stretched), the new firmware box, does not play the HLS video -- but seems stuck on the loading screen for many minutes. i can fast-forward a few minutes into it and then it plays OK (maintaining aspect ratio).


    I'd just like to comment that I am seeing similar behavior in one of my channels. The loading screen gets stuck at around 75% percent. FF does not seem to work for me (possibly b/c the file is transcoding). If I hit "UP" or "HOME" when on the loading screen it causes a reboot (do you see this too?).

    For reasons I prefer not to get into here I don't expect Roku to support my channel, but I can confirm that something has changed with the way HLS is handled.
  • yeah i just noticed issues too and i was just using a nasa stream as a test....
  • renojim's avatar
    renojim
    Community Streaming Expert
    "RokuPatrick" wrote:
    We're looking into the reported HLS issues in 2.8.

    As I said in the general forum, I have yet to find a video that will play under 2.8, so I don't think it's just HLS. I can't say I've tried many since most of them crash the box, but I can send you plenty of samples of videos that used to play.

    I'm having a bad day.... 😞

    -JT
  • astudios's avatar
    astudios
    Channel Surfer
    SOLVED!

    we changed the "minBandwidth" value in our ROKU app to 64 (used to be 20) and it worked! HLS video streaming works beautifully now! aspect ratio is maintained to boot!

    steven
  • astudios's avatar
    astudios
    Channel Surfer
    "astudios" wrote:
    SOLVED!

    we changed the "minBandwidth" value in our ROKU app to 64 (used to be 20) and it worked! HLS video streaming works beautifully now! aspect ratio is maintained to boot!

    steven

    just as a followup.. the above works for VOD (video-on-demand) but failed for any LIVE HLS stream. so, we inserted code to use minBandwidth=20 for all LIVE streams and minBandwidth=64 for all VOD videos. not pretty, but it works.

    steven