Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is a webcam feed inside of emacs possible?

Tags:

emacs

I want to live stream me coding on TwitchTV. Back in my vim days, I would open up several terminals and leave a small hole in the corner to put a quicktime webcam display so that my screen recorder would capture my face. What I would like is the ability to embed a webcam feed into a buffer of emacs so that it will be integrated with emacs tiling ability. Is this possible? If so, how would I go about doing it?

like image 500
Collin Bell Avatar asked Jan 16 '16 15:01

Collin Bell


1 Answers

Take my answer with a grain of salt, it's untested and I'm not sure if it works, and it certainly won't do audio.

  1. Create a live-streaming .gif file from your video stream:

    git clone https://github.com/jbochi/gifstreaming
    cd gifstreaming
    mkdir input
    mkdir parts
    ffmpeg -re -i rtmp:///dev/video0 -pix_fmt pal8 -s 159x97 -r 10 input/in%d.gif &
    python transform.py
    node server.js

https://github.com/jbochi/gifstreaming

  1. Open a buffer with the image displayed inline using the emacs web browser:

M-x eww RET http://localhost:8080/ RET


Alternatively, you could try streaming directly from your webcam without the gif step, but I doubt eww can display video files inline.

http://www.area536.com/projects/streaming-video/

like image 53
Nick Sweeting Avatar answered Oct 05 '22 23:10

Nick Sweeting