linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
Cc: "media-workshop@linuxtv.org" <media-workshop@linuxtv.org>,
	dev@lists.tizen.org,
	Linux Media Mailing List <linux-media@vger.kernel.org>,
	gstreamer-announce@lists.freedesktop.org
Subject: Re: [media-workshop] [ANNOUNCE] Linux Kernel Media mini-summit on Oct, 16-17 in Düsseldorf, Germany
Date: Tue, 19 Aug 2014 23:00:34 +0200	[thread overview]
Message-ID: <2415405.eYkoJgdMtI@avalon> (raw)
In-Reply-To: <CAPybu_02Mksi53EwsNwebGPcEhGf+TDYcyD=nry1tN1Dz7OTqA@mail.gmail.com>

On Tuesday 19 August 2014 18:29:08 Ricardo Ribalda Delgado wrote:
> Hello Laurent
> 
> > Could you elaborate a bit on that last point ? What kind of timestamps
> > would you need, and what are the use cases ?
> 
> Right now we only have one timestamp field on the buffer structure, it
> might be a good idea to leave space for some more.
> 
> My user case is a camera that is recording a conveyor belt at a very
> high frame rate. Instead of tracking the objects on the image with I
> use one or more encoders on the belt.  The encoder count  is read on
> vsync and kept it on a register(s). When an image is ready, the cpu
> starts the dma and read this "belt timestamps" registers.
> 
> It would be nice to have an standard way to expose this alternative
> timestamps or at least find out if I am the only one with this issue
> and/or how you have solve it :)

I have a similar use cases. UVC transmits a device clock timestamp to the 
host, as well as the corresponding USB SOF counter value. This can be used to 
translate the device clock timestamp to a host timestamp. The uvcvideo driver 
is currently performing that translation in the kernel, but moving it to 
userspace would allow more accurate host timestamp computation by using 
floating-point math.

In a similar fashion CSI2 cameras transmit a 16-bit frame number to the 
receiver. That number is currently expanded to 32-bits by the driver and 
passed to userspace in the v4l2_buffer sequence number. That's fine from a 
kernel point of view, but in userspace the sequence number is lost when using 
the gstreamer v4l2src element.

Have you thought about how you would like to implement those advanced 
timestamps ? Reusing the v4l2_buffer timecode field might be an option, but 
I'm not sure whether it would be the best one. Using a metadata plane also 
comes to mind.

-- 
Regards,

Laurent Pinchart


  reply	other threads:[~2014-08-19 20:59 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-13 13:14 [ANNOUNCE] Linux Kernel Media mini-summit on Oct, 16-17 in Düsseldorf, Germany Mauro Carvalho Chehab
2014-08-14 11:43 ` [media-workshop] " Laurent Pinchart
2014-08-19 14:48   ` Ricardo Ribalda Delgado
2014-08-19 16:12     ` Laurent Pinchart
2014-08-19 16:29       ` Ricardo Ribalda Delgado
2014-08-19 21:00         ` Laurent Pinchart [this message]
2014-08-20  2:12           ` Hans Verkuil
2014-08-20 18:57 ` Guennadi Liakhovetski
2014-08-25 15:07   ` [media-workshop] " Ralph Metzler
2014-08-22 13:09 ` Philipp Zabel
2014-08-25  0:12   ` Pawel Osciak
2014-09-02 10:03 ` Philipp Zabel
2014-09-02 12:58   ` Mauro Carvalho Chehab
2014-09-18 20:25     ` Michael Ira Krufky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2415405.eYkoJgdMtI@avalon \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=dev@lists.tizen.org \
    --cc=gstreamer-announce@lists.freedesktop.org \
    --cc=linux-media@vger.kernel.org \
    --cc=media-workshop@linuxtv.org \
    --cc=ricardo.ribalda@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).