-
-
Notifications
You must be signed in to change notification settings - Fork 338
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Black Bars around video stream and video stream is stuck when scrolling #574
Comments
This comment has been minimized.
This comment has been minimized.
@aspdev91 The layout constraints warning have nothing to do with your issue see #422 that why i have hide your comment above. If you want to update video location on scrool you need to call Here is an example to do that automaticly. We may add that by default later. // Scan every 500ms for refreshing video tag position and on various user events.
var scanVideoTagTimer,
scanVideoTagInterval = 500;
function scanVideoTag() {
clearTimeout(scanVideoTagTimer);
var shouldRefreshingVideos = $window.document.querySelectorAll('video').length > 0;
if (shouldRefreshingVideos) {
$window.cordova.plugins.iosrtc.refreshVideos();
}
scanVideoTagTimer = setTimeout(scanVideoTag, scanVideoTagInterval);
};
// Start scanVideoTag
scanVideoTagTimer = setTimeout(scanVideoTag, scanVideoTagInterval);
window.onorientationchange = scanVideoTag;
window.addEventListener('touchstart', scanVideoTag);
window.addEventListener('click', scanVideoTag);
window.addEventListener('touchmove', scanVideoTag);
window.addEventListener('touchend', scanVideoTag); related: #478 |
@aspdev91 The black bar issue you have on capture can be related to this bug I do recomand you try master until 6.0.14 is released and this but with it:
|
Let me kow if this 2 thing works for you and i will close the issue. |
Notice that to get Image to canvas you need to use special iosrtc code see example here: |
@hthetiot Thank you for the help on this.. This was a blocker for us. The scrolling issue is resolved with the code you provided. For the image canvas, I tried to run the test code and got this error in Safari debug tools:
For the black bar, I was on latest master when I made this post and I just pulled master again using your command. Unfortunately, the black bars are still there. |
localVideoEl need to be your element and you need to propably do that in a setTimeout or after the video canplay event.
Please create separate issue that would help to keep issue scope. |
Did you use object-fit also it will depend the size of your video tag |
@aspdev91 glad it is solved for you, I plan to add SHIM to emulate Original Stream to Canvas in the future. For object-fit CSS here is quick reference for people landing on this issue: |
extra/renderer-and-libwebrtc-tests.js
file).Versions affected
Description
I'm not able to get a 4/3 video atm. It's also stuck to the screen as seen in the video below. I tested the same javascript code with on a hosted environment and accessed it with Safari. It worked perfectly fine. Below is a short video of what I encountered.
https://youtu.be/KiO-VVzpV-w
Steps to reproduce
If you run this code, you should be able to reproduce. I've tried numerous combinations of the constraints in getUserMedia using back and front cameras alongside different resolutions to no avail.
})
Expected results
A 4/3 video that is not stuck to the screen. I also fed the video in a image recognition model and the confidence score was super low. I think it's because it's feeding in those black bars as well since I assume its part of the video. I tested the same javascript code on a hosted environment and accessed it with Safari. It worked perfectly fine.
Actual results
See video below:
https://youtu.be/KiO-VVzpV-w
The text was updated successfully, but these errors were encountered: