Saving datetimes as text

Marc Murphy marcmltd at marcm.co.uk
Mon Dec 10 01:13:44 PST 2012


Hi,

Have a look at transport stream carrier.  This is used in broadcast to deliver video and audio to be synchronised using a presentation time for decode.  The PTS (presentation Time Stamp) ensures that the video and audio are rendered at the correct time.  You can use MPEG2 or h264 video in a transport stream for the video and normally mpeg or ac3 audio.



There are quite a few options for the mpegts plugin and maybe other people on the forum will be able to assist.



Regards

Marc



________________________________
From: gstreamer-devel-bounces+marcmltd=marcm.co.uk at lists.freedesktop.org [gstreamer-devel-bounces+marcmltd=marcm.co.uk at lists.freedesktop.org] on behalf of Thomas Levine [occurrence at thomaslevine.com]
Sent: 07 December 2012 16:41
To: Gstreamer Devel
Subject: Saving datetimes as text

Hi,

I am going to record video, audio and electromyography (It doesn't
matter if that
means nothing to you.) at the same time, and I want to align the
measurements.

In case you are curious, I want to figure out why wrists make that
cracking noise
if you twist them in that weird way that you'll know about only if you
do it.
Electromyography measures electric potential across a muscle, so it's
sort of like
muscle activity. More here: https://github.com/tlevine/wrist-cracking

All of the recording devices are plugged into the same computer, so I
think that
using clock time would less annoying than some other approaches. Thus,
I want to
get a datetime out of the video and audio that I'm recording.

This command seems decent for recording the video and audio.

     gst-launch-0.10 v4l2src ! timeoverlay halign=right valign=top ! \
       clockoverlay time-format="%Y-%m-%d %H:%M:%S" halign=left
valign=top ! \
       video/x-raw-yuv,width=640,height=480 ! ffmpegcolorspace !
theoraenc ! \
       oggmux name=mux ! filesink location="$outfile" pulsesrc !
audioconvert ! \
       vorbisenc ! mux.

On my computer, the video is laggy, but the audio is not, and the audio
is more
important.

This command displays the time as an image, so it's enough for manually
aligning
the video/audio with the electromyography, but it would be nice if I
could make
it more automatic. I think that getting the start and end times of the
video/audio
recording as text would be fine.

I've never written anything with gstreamer except for hacks with
gst-launch.
It looks like I should use a descendant of GstClock, but that's as far
as I've
gotten. I haven't really written C before.
http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html

Can I do something like this in gst-launch or in something similarly
simple?

Thanks

Tom
_______________________________________________
gstreamer-devel mailing list
gstreamer-devel at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20121210/cb5c933a/attachment-0001.html>


More information about the gstreamer-devel mailing list