Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Flipping video data in JavaScript

Options
  • 10-10-2018 2:50pm
    #1
    Registered Users Posts: 8


    Hi. I'm using a js library to record videos from a webcam. I display the webcam stream in a <video> element and flip it in css:
    rotateY().

    When the library finishes recording, it creates a data URI.
    The video is then saved but isn't flipped. How did I "flip" the data URI?

    I hope I made sense.
    Thanks in advance.


Comments

  • Registered Users Posts: 2,031 ✭✭✭colm_c


    You're flipping the display of the video, not the video itself.

    Unless you can get the js library to do it, or even the webcam to do it, unlikely to do with with css...


  • Registered Users Posts: 8 Alex Nuzum


    That's what I was trying to explain. Do you know any libraries. I couldn't find any. If I do though I'll post it here., others must surely have this problem.


  • Closed Accounts Posts: 260 ✭✭rd1izb7lvpuksx


    Do you want to do this serverside or in the browser? If serverside, then use ffmpeg to hflip or vlip it - there even a JS port (https://github.com/Kagami/ffmpeg.js). It'll be a lot more awkward to do clientside.


  • Registered Users Posts: 568 ✭✭✭rgodard80a


    Alternatively, some IP cameras / webcams have an admin page/controls to alter brightness, contrast etc.

    And they may have a setting to flip the video for you at source.


  • Registered Users Posts: 8 Alex Nuzum


    Thanks. I'll look into ffmpeg


  • Advertisement
Advertisement