mirror of
https://github.com/matthew1000/gstreamer-cheat-sheet.git
synced 2024-11-24 09:11:00 +00:00
Try and fix broken markdown headers
This commit is contained in:
parent
cce4a1680d
commit
e96616b16e
5 changed files with 24 additions and 8 deletions
|
@ -10,7 +10,7 @@ export SRC=/home/me/videos/test.mp4
|
|||
|
||||
### Play a video (with audio)
|
||||
|
||||
`playbin` is a magical element that can play anything:
|
||||
The magical element `playbin` can play anything:
|
||||
|
||||
```
|
||||
gst-launch-1.0 playbin uri=file://$SRC
|
||||
|
|
|
@ -1,12 +1,16 @@
|
|||
# Capturing images (GStreamer command-line cheat sheet)
|
||||
|
||||
### Capture an image as png
|
||||
### Capture an image as PNG
|
||||
|
||||
The `pngenc` element can create a single PNG:
|
||||
|
||||
```
|
||||
gst-launch-1.0 videotestsrc ! pngenc ! filesink location=foo.png
|
||||
```
|
||||
|
||||
### Capture an image as jpeg
|
||||
### Capture an image as JPEG
|
||||
|
||||
The `jpegenc` element can create a single JPEG:
|
||||
|
||||
```
|
||||
gst-launch-1.0 videotestsrc ! jpegenc ! filesink location=foo.jpg
|
||||
|
|
|
@ -4,6 +4,8 @@ The [`shmsink`](https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-pl
|
|||
|
||||
### Putting a stream into memory
|
||||
|
||||
Put a test video source into memory:
|
||||
|
||||
```
|
||||
gst-launch-1.0 -v videotestsrc ! \
|
||||
'video/x-raw, format=(string)I420, width=(int)320, height=(int)240, framerate=(fraction)30/1' ! \
|
||||
|
@ -26,10 +28,10 @@ gst-launch-1.0 filesrc location=$SRC ! \
|
|||
|
||||
### Reading a stream from memory
|
||||
|
||||
This will display the video of a stream locally:
|
||||
|
||||
```
|
||||
gst-launch-1.0 shmsrc socket-path=/tmp/tmpsock ! \
|
||||
'video/x-raw, format=(string)I420, width=(int)320, height=(int)240, framerate=(fraction)30/1' ! \
|
||||
autovideosink
|
||||
````
|
||||
|
||||
|
||||
|
|
|
@ -97,7 +97,9 @@ gst-launch-1.0 \
|
|||
|
||||
Use the `audiomixer` element to mix audio. It replaces the `adder` element, which struggles under some circumstances (according to the [GStreamer 1.14 release notes](https://gstreamer.freedesktop.org/releases/1.14/)).
|
||||
|
||||
### Mix two (or more) test streams
|
||||
### Mix two (or more) test audio streams
|
||||
|
||||
Here we use two different frequencies (tones):
|
||||
|
||||
```
|
||||
gst-launch-1.0 \
|
||||
|
@ -112,6 +114,8 @@ gst-launch-1.0 \
|
|||
|
||||
### Mix two (or more) MP3 files
|
||||
|
||||
Ensure `$AUDIO_SRC` and `$AUDIO_SRC2` environment variables are set to mp3 files.
|
||||
|
||||
```
|
||||
gst-launch-1.0 \
|
||||
audiomixer name=mix ! audioconvert ! autoaudiosink \
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
# Test streams (GStreamer command-line cheat sheet)
|
||||
|
||||
## Video test streams
|
||||
## Video test streams
|
||||
|
||||
### Display a test pattern
|
||||
### Display a test pattern
|
||||
|
||||
The `videotestsrc` element creates test patterns. Display locally like this:
|
||||
|
||||
```
|
||||
gst-launch-1.0 videotestsrc ! videoconvert ! autovideosink
|
||||
|
@ -37,6 +39,8 @@ gst-launch-1.0 -v videotestsrc pattern=snow ! video/x-raw,width=1280,height=720
|
|||
|
||||
### Listen to a test audio (beep)
|
||||
|
||||
The element `audiotestsrc` can make a variety of test sounds:
|
||||
|
||||
```
|
||||
gst-launch-1.0 audiotestsrc ! autoaudiosink
|
||||
```
|
||||
|
@ -58,6 +62,8 @@ gst-launch-1.0 audiotestsrc volume=0.1 ! autoaudiosink
|
|||
|
||||
### White noise
|
||||
|
||||
Set `wave` to `white-noise`:
|
||||
|
||||
```
|
||||
gst-launch-1.0 audiotestsrc wave="white-noise" ! autoaudiosink
|
||||
```
|
||||
|
|
Loading…
Reference in a new issue