Jump to content

Streaming Mpeg-Dash Video Texture *Now Working w/Webcam Demo*


MasterSplinter
 Share

Recommended Posts

  • 4 months later...
On 2016/3/15 at 7:37 AM, MasterSplinter said:

Okay,

Just made a webcam demo for ya'll to look at it... I kinda did this quick with some magic copy-pasta action.

My version has a slightly different version of BABYLON.VideoTexture as I removed on video ready whatever its called event behavior.

https://rawgit.com/wpdildine/webCAMbabylon/master/index.html

As added bonus this works on my cell phone!

 

Hi @MasterSplinter, thanks for your demo, it works on both my desktop and phone, but after I removed the rotation animation, I found that the default surface's video data is disordered(up down  reversed), can you or any others can explain it for me?  When I used the similar function in Three.js, it work fine without disordered.

 

Thank you!

Link to comment
Share on other sites

I remember this post, and glad to see the link from @Johnny007. Earlier in the post, I saw issues with autoplay on different OS and have the same issues. I can disable autoplay using:

jQuery( '#video' ).removeAttr( 'autoplay' ); 

I can use the above as well as a few other code options for removing specific video attributes, however the autoplay attribute isn't removed until the video plays through once - but at least it doesn't loop. If anyone has a method to stop or pause autoplay on PC after defining as a videoTexture, I believe this would still be very valuable to this topic. I can only pause autoplay the first time it plays by using videoTexture.video.pause(); only with an additional event to trigger by the user.

When we are in multi-user mode on our server, we stream everything in sync, so it's irrelevant as we have control over what elements we stream and when. However, if disconnected from the server, I can only load the video and am trying to keep it in a buffer before defining as a videoTexture - but this is causing allot of extra work which may not be necessary.

DB

Link to comment
Share on other sites

@Johnny007

Hello

could it possible be a driver problem with your device ? Can you root your phone to check that ? Sometimes it also happens with external webcams, the image is flipped, you have to solve it though installing a driver, or software, like skype ...or something more lowlevel.

The problem is when you get the right answer for you device, that means not that your code will work for everyone, be course the link from Mastersplinter works for me, i see a good image with the right order.

EDIT
@Johnny007
Can you upload your project as a minimal version of code, where you think you get a bug (use a babylonjs.max version for debug) 
https://github.com/BabylonJS/Babylon.js/tree/master/dist

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...