How can I encode a video to h264?

Hector Tosado Jimenez picture Hector Tosado Jimenez · May 5, 2012 · Viewed 15.6k times · Source

I am trying to send a video file using GNUradio, specifically using GRC. In order to do this I am first obtaining whichever video, in our case we took a 6 second video of us staring and talking to the camera. After this was done we created a "pipe" file I believe is called using mkfifo, both for the input and output file. After that I believe Im supposed to save the video I took in a h264 encoding using a command that I found:

gst-launch -e -v v4l2src device="/dev/video1" ! video/x-raw-yuv, framerate=25/1, width=640, height=360 ! \timeoverlay halign=right valign=bottom shaded-background=true ! \textoverlay text="Test Video 640x360 25fps" halign=left valign=bottom shaded-background=true ! \x264enc bitrate=498 ! mpegtsmux ! filesink location=test1.ts

This is giving me an error:

WARNING: erroneous pipeline: no element "x264enc"

Ive been trying to find how to solve this and I've installed basically every package or library that exists that may have to do with h264 encoding or x264enc command.

How can I possibly resolve that issue? Thanks in advance.

Answer

HelloWorld picture HelloWorld · May 5, 2012

download and make install x264