<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>I used milli instead of ms so it's not confused with msftime_t.
And so micro and nano seems like logical siblings.<br>
</p>
<br>
<div class="moz-cite-prefix">On 2018-06-15 7:58 PM, Rémi
Denis-Courmont wrote:<br>
</div>
<blockquote type="cite"
cite="mid:540FDAD4-65C1-4742-846F-9D73A48B2164@remlab.net">I'd use
ms, us and ns. Nano is just weird.<br>
<br>
<div class="gmail_quote">Le 15 juin 2018 18:09:15 GMT+03:00, Steve
Lhomme <a class="moz-txt-link-rfc2396E" href="mailto:robux4@ycbcr.xyz"><robux4@ycbcr.xyz></a> a écrit :
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt
0.8ex; border-left: 1px solid rgb(204, 204, 204);
padding-left: 1ex;">
<pre class="k9mail">It will be handy if mtime_t has better precision than microseconds.
---
include/vlc_common.h | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/include/vlc_common.h b/include/vlc_common.h
index d4186883df6..3191d3ce4c8 100644
--- a/include/vlc_common.h
+++ b/include/vlc_common.h
@@ -316,6 +316,15 @@ static inline int64_t milli_from_vtick(mtime_t mt)
return mt / (CLOCK_FREQ / 1000);
}
+static inline mtime_t vtick_from_nano(int64_t nano)
+{
+ return nano / (INT64_C(1000000000) / CLOCK_FREQ);
+}
+static inline int64_t nano_from_vtick(mtime_t tck)
+{
+ return tck * INT64_C(1000000000) / CLOCK_FREQ;
+}
+
/**
* The vlc_fourcc_t type.
*</pre>
</blockquote>
</div>
<br>
-- <br>
Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez
excuser ma brièveté.
<!--'"--><br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
vlc-devel mailing list
To unsubscribe or modify your subscription options:
<a class="moz-txt-link-freetext" href="https://mailman.videolan.org/listinfo/vlc-devel">https://mailman.videolan.org/listinfo/vlc-devel</a></pre>
</blockquote>
<br>
</body>
</html>