From: Pieter Palmers <pieterp@joow.be>
To: ALSA Development Mailing List <alsa-devel@alsa-project.org>
Subject: Re: Monotonic timestamps
Date: Thu, 10 Apr 2008 19:20:08 +0200 [thread overview]
Message-ID: <47FE4C48.6030308@joow.be> (raw)
In-Reply-To: <20080410141513.GA5852@tango.0pointer.de>
Lennart Poettering wrote:
> On Thu, 10.04.08 09:03, Pieter Palmers (pieterp@joow.be) wrote:
>
>>> I find it very strange that ALSA just switches to monotonic timestamps
>>> just like that, anyway. Programs written for wallclack timestamps will
>>> break if they run on a system where ALSA uses monotonic timestamps!
>>>
>>> There's a function missing that enables monotonic timestamps
>>> explicitly, or at least one that can be used to query if they are
>>> monotonic or not.
>> The clean solution would (IMHO) be to have ALSA provide a function to
>> obtain 'current time', thereby making the timestamp system
>> self-contained. Maybe it already does...
>
> This wouldn't help much since timestamps might also come from other
> libraries. i.e. being able to relate timestamps from ALSA with
> timestamps from the application itself is not enough. They also need
> to be relatable to timestamps from other code, which might not
> necessarily be linked against ALSA.
>
> i.e. think of gstreamer that uses timestamps attached to each video
> frame. Do you really expect gst to move their timestamp source over to
> ALSA just because one of the plugins for gst supports ALSA?
Let me put it another way: if some library provides timestamps, it
should also provide a mechanism to obtain the current time. That way the
application is able to relate the timestamps to whatever clock it wants.
On the other hand, the "mechanism to obtain the current time" could
equally well be "use CLOCK_MONOTONIC". In that sense your original post
points out the issue, since obviously ALSA doesn't provide this info.
Never mind the noise.
Pieter
next prev parent reply other threads:[~2008-04-10 17:20 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-09 21:36 Monotonic timestamps Lennart Poettering
2008-04-10 7:03 ` Pieter Palmers
2008-04-10 14:15 ` Lennart Poettering
2008-04-10 17:20 ` Pieter Palmers [this message]
2008-04-10 7:48 ` Jaroslav Kysela
2008-04-10 14:26 ` Lennart Poettering
2008-04-11 12:16 ` Jaroslav Kysela
2008-04-11 12:56 ` Lennart Poettering
2008-04-21 10:47 ` Jaroslav Kysela
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=47FE4C48.6030308@joow.be \
--to=pieterp@joow.be \
--cc=alsa-devel@alsa-project.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.