videojs / video.js

Video.js - open source HTML5 video player
https://videojs.com
Other
38.2k stars 7.47k forks source link

Resolution / stretching BUG #3241

Closed ethernetweb closed 4 years ago

ethernetweb commented 8 years ago

Update: The video displays it as a postage stamp size in the upper left corner. According to the rtmp meta data it has a set width/height but is apparently not acquired by videojs?

Description

Using the DEFAULT html at http://videojs.com/getting-started/ with autoplay If the source video resolution is 320 x 240 and you want it to fit the width/height of the videojs player element (say 640x480), it will not stretch unless you go full screen then back out of full screen. My source is a live stream of type="rtmp/flv"

Steps to reproduce

  1. Use default HTML from http://videojs.com/getting-started/
  2. Use nginx rtmp module + as3 flash netstream publish for broadcasting.
  3. Use a live rtmp/flv or rtmp/mp4 video source that has a resolution smaller than your
  4. Play video. (it dos not fit the resolution of video element unless you go full screen then back out of full screen.

    Results

    Expected

By telling videojs to use x width and y height, it should stretch the source video x/y to the

Actual

It starts playing but only displays in the

Error output

None

Additional Information

versions

Have tried 5.8.8 5.8.7 5.8.0

browsers

Have tried FireFox (recent) Chrome

OSes

Windows 7

plugins

None

calebfavor commented 7 years ago

@ethernetweb - Did you ever find a solution to this? We are having the same issue, the video is a tiny square in the top left.

hoodsy commented 7 years ago

@calebfavor @ethernetweb same here. been searching through to bugs looking for others with the same issue.

aditya-vadlamani commented 7 years ago

A little CSS worked for me. Set the width and height parent element of the video player to a certain value. For e.g.

<div id = videoContainer>
   <div id = player>
      <!-- Player begins here -->
   </div>
</div>

#videoContainer{
   height: 480px;
   width: 640px;
}

#player{
  height: 100%;
  width: 100%;
}
gkatsev commented 4 years ago

Given that Adobe Flash is being end-of-lifed this month we will no longer be working on flash related features.