[M3devel] JVideo/struct_timeval?

Jay K jay.krell at cornell.edu
Mon Apr 19 16:04:39 CEST 2010


I went ahead and put in a local type.

Utime.struct_timeval is now gone.

 

 - Jay

 


From: jay.krell at cornell.edu
To: m3devel at elegosoft.com
Subject: JVideo/struct_timeval?
Date: Mon, 12 Apr 2010 13:03:26 +0000



This seems wierd:
 
 
C:\dev2\cm3.2\m3-ui\jvideo\src\POSIX\jvprotocol.i3(193):      timestamp: Utime.struct_timeval;

I think they are defining a wire protocol, but embedding platform-specific types in it.
How about I just change to Time.T? (64bit floating point, seconds since 1970).
We could do like:
 
C:\dev2\cm3.2\m3-ui\jvideo\src\POSIX\decunix\JVSink.m3(440):    jvb.timestamp.tv_sec := signed_ntohl(hdr.timestamp.tv_sec);

and define it to be transferred as a network order 64bit integer (big endian LONGINT), or maybe an array of 8 bytes.
 
Or maybe define a local struct_timeval separate from Utime that hardcodes the sizes..and maybe using LONGINT?
  32bit time_t is apparently still very common, though it seems obviously a big mistake..
 
 - Jay
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20100419/e9c98342/attachment-0002.html>


More information about the M3devel mailing list