Skip to content

Instantly share code, notes, and snippets.

@pavelvpster
pavelvpster / GStreamer-capture-to-images-JPEG.sh
Created September 28, 2014 14:13
GStreamer capture from webcam to image set; webcam supports JPEG output format.
gst-launch-0.10 v4l2src device=/dev/video0 \
! "image/jpeg,width=640,height=480,framerate=5/1" \
! videorate \
! "image/jpeg,framerate=1/6" \
! multifilesink location="./images/image-%06d.jpg"
@pavelvpster
pavelvpster / GStreamer-capture-to-images-with-timestamp-JPEG.sh
Created September 28, 2014 14:15
GStreamer capture webcam to image set with timespamp; webcam supports JPEG output format.
gst-launch-0.10 v4l2src device=/dev/video0 \
! "image/jpeg,width=640,height=480,framerate=5/1" \
! videorate \
! "image/jpeg,framerate=1/6" \
! jpegdec \
! clockoverlay time-format="%d.%m.%Y %H:%M:%S" \
! jpegenc \
! multifilesink location="./images/image-%06d.jpg"
@pavelvpster
pavelvpster / GStreamer-capture-to-images-with-timestamp-RAW_YUV.sh
Created September 28, 2014 14:18
GStreamer capture webcam to image set with timespamp; webcam does not support JPEG output format.
gst-launch-0.10 v4l2src device=/dev/video0 \
! "video/x-raw-yuv,width=640,height=480,framerate=5/1" \
! videorate \
! "video/x-raw-yuv,framerate=1/6" \
! clockoverlay time-format="%d.%m.%Y %H:%M:%S" \
! jpegenc \
! multifilesink location="./images/image-%06d.jpg"
@pavelvpster
pavelvpster / GStreamer-images-to-AVI.sh
Last active January 17, 2021 12:25
GStreamer convert image set to AVI (H264 encoding).
gst-launch-0.10 multifilesrc location="./images/image-%06d.jpg" \
! "image/jpeg,framerate=12/1" \
! jpegparse \
! jpegdec \
! x264enc \
! avimux \
! filesink location=video.avi