> For the complete documentation index, see [llms.txt](https://bhabs.gitbook.io/allsetup/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bhabs.gitbook.io/allsetup/gstreamer.md).

# GStreamer

```
# Capture a single image and save it in JPEG format.

$ gst-launch v4l2src num-buffers=1 ! jpegenc ! filesink location=/tmp/test.jpg

# Stream video from a webcam.

$ gst-launch v4l2src ! xvimagesink

Ref: https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-plugins/html/gstreamer-plugins-filesink.html
gst-launch-1.0 v4l2src num-buffers=1 ! jpegenc ! filesink location=capture1.jpeg
```
