Showing
1 changed file
with
6 additions
and
6 deletions
... | @@ -65,12 +65,12 @@ function init() | ... | @@ -65,12 +65,12 @@ function init() |
65 | var messageboxHeight = $('#messagebox').height(); | 65 | var messageboxHeight = $('#messagebox').height(); |
66 | video.width = video.videoWidth; | 66 | video.width = video.videoWidth; |
67 | video.height = video.videoHeight; | 67 | video.height = video.videoHeight; |
68 | - if (video.width > screenWidth || video.height + headerHeight + messageboxHeight > screenHeight){ | 68 | + if (video.width > screenWidth || video.height + headerHeight > screenHeight){ |
69 | - var ratio = Math.min(screenWidth / video.width * 1.0, screenHeight / ((video.height + headerHeight + messageboxHeight) * 1.0)); | 69 | + var ratio = Math.min(screenWidth / video.width * 1.0, screenHeight / ((video.height + headerHeight) * 1.0)); |
70 | - container.style.width = Math.round(video.videoWidth * ratio) + 'px'; | 70 | + container.style.width = Math.round(video.width * ratio) + 'px'; |
71 | - container.style.height = Math.round(video.videoHeight * ratio) + 'px'; | 71 | + container.style.height = Math.round(video.height * ratio) + 'px'; |
72 | - canvasOutput.width = Math.round(video.videoWidth * ratio); | 72 | + canvasOutput.width = Math.round(video.width * ratio); |
73 | - canvasOutput.height = Math.round(video.videoHeight * ratio); | 73 | + canvasOutput.height = Math.round(video.height * ratio); |
74 | } | 74 | } |
75 | load_cascade(); | 75 | load_cascade(); |
76 | }); | 76 | }); | ... | ... |
-
Please register or login to post a comment