RASPIVIDYUV(1)

NAME
raspividyuv - records unencoded video with the Pi Camera Module

SYNOPSIS
raspividyuv [-3d mode] [-3dswap] [-ISO value] [-a flags|text] [-ae size,fg,bg] [-ag value] [-awb mode] [-awbg b,r] [-br value] [-cfx u:v] [-co value] [-cs camera] [-d ms] [-dg value] [-dn screen] [-drc value] [-ev value] [-ex mode] [-f] [-fli mode] [-fps fps] [-gps] [-h size] [-hf] [-i state] [-ifx effect] [-k] [-l] [-md mode] [-mm mode] [-n] [-o filename] [-op opacity] [-p x,y,w,h] [-pts filename] [-roi x,y,w,h] [-rot value] [-s] [-sa value] [-set] [-sh value] [-ss value] [-t ms] [-td on,off] [-v] [-vf] [-w size]
raspividyuv [-?]
raspividyuv [--help]

DESCRIPTION
raspividyuv is a command line utility for recording unencoded video frames from the Raspberry Pi Camera Module (any version), in YUV format by default (see [YUV]). It has numerous options which can be used to customize the recording, the preview display, or to perform more complex operations like video streaming.

OPTIONS
The options documented in the following sections are specific to the raspividyuv utility, or commonly used with it. For full details of the other options (which are common to all the camera utilities), please refer to the raspicam(7) manual page.

GENERAL OPTIONS

-?, --help
    Display a concise description of all parameters

-d, --demo [ms]
    This options cycles through the range of camera options. No recording is taken, and the demo will end at the end of the timeout period, irrespective of whether all the options have been cycled. The time between cycles should be specified as a millisecond value.

-fps, --framerate fps
    Specifies the frames per second to record. At present, the minimum frame rate allowed is 2fps, and the maximum is 30fps. This is likely to change in the future.

-h, --height size
    Set the video height to size.

-i, --initial state
    Define whether the camera will start paused or will immediately start recording. Valid states are record or pause. Note that if you are using a simple timeout (without --timed or --keypress or other options to activate recording), and --initial is set to pause, no output will be recorded.

-k, --keypress
    On each press of the Enter key, the recording will be paused or restarted. Pressing X then Enter will stop recording and close the application. Note that the timeout value (-t) will be used to signal the end of recording, but is only checked after each Enter keypress; so if the system is waiting for a keypress, even if the timeout has expired, it will still wait for the keypress before exiting.

-l, --listen
    When using a network connection as the --output, this option will make the sytem wait for a connection from the remote system before sending data.

-y, --luma
    Only outputs the luma (Y) channel of the YUV image. This is effectively the black and white, or intensity, part of the image. See [YUV] for more information.

-o, --output filename
    Specify the output filename. If not specified, no file is saved. If the filename is “-”, then all output is sent to stdout. To connect to a remote IPv4 host, use tcp or udp followed by the required IP Address. e.g. tcp://192.168.1.2:1234 or udp://192.168.1.2:1234.

    To listen on a TCP port (IPv4) and wait for an incoming connection use the --listen option, e.g. raspividyuv -l -o tcp://0.0.0.0:3333 will bind to all network interfaces, raspividyuv -l -o tcp://192.168.1.1:3333 will bind to a local IPv4.

-pts, --save-pts filename
    Saves timestamp information to the specified file. Useful as an input file to mkvmerge(1).

-rgb, --rgb
    This option forces the video to be saved as RGB data with 8 bits per channel, rather than YUV420. Note that the video frames saved in raspividyuv are padded to a horizontal size divisible by 32, so there may be unused bytes at the end of each line. Buffers are also padded vertically to be divisible by 16, and in the YUV mode, each plane of Y,U,V is padded in this way.

-s, --signal
    Sending a USR1 signal to the raspividyuv process will toggle between recording and paused. This can be done using the killall(1) command, as below:

        killall -USR1 raspividyuv

    Note that the timeout value will be used to indicate the end of recording, but is only checked after each receipt of the USR1 signal; so if the system is waiting for a signal, even if the timeout has expired, it will still wait for the signal before exiting.

-td, --timed on,off
    This options allows the video capture to be paused and restarted at particular time intervals. Two values are required: the on time and the off time, both measured in milliseconds. On time is the amount of time the video is captured, and off time is the amount it is paused. The total runtime of the application is defined by the timeout option (-t). Note that the runtime may go slightly over the timeout setting depending on the on and off times.

    For example:

        raspividyuv -o test.h264 -t 25000 --timed 2500,5000

    This will alternate between recording for 2500ms (2.5s), then pausing for 5000ms (5s) gaps, until 25000ms (25s) have elapsed. The resulting recording will only be 10s long, since 4 segments of 2.5s = 10s, separated by 3 gaps of 5s = 15s, for a total of 25s:

        Seconds            1                   2
         1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
        RRRRR..........RRRRR..........RRRRR..........RRRRR

-t, --timeout ms
    The total length of time that the program will run for. If not specified, the default is 5000ms (5 seconds). If set to 0, the application will run indefinitely until stopped with Ctrl-C.

-v, --verbose
    Outputs debugging/information messages during the program run.

EXIT STATUS

0   Application ran successfully (EX_OK)

64  Bad command line parameter (EX_USAGE)

70  Software or camera error (EX_SOFTWARE)

130 Application terminated by Ctrl-C

SEE ALSO
raspicam(7), raspistill(1), raspivid(1), raspiyuv(1), vcgencmd(1), [SOURCE]

REFERENCES

[SOURCE]
    https://www.raspberrypi.org/documentation/raspbian/applications/camera.md

[YUV]
    https://en.wikipedia.org/wiki/YUV