Dear all,
I'm trying to access and read a binary patch file (like ?h.full.patch.3d) rather than a converted ascii file. I've found a description of the lay-out of such a file at http://surfer.nmr.mgh.harvard.edu/fswiki/FileFormats that in turn links to http://wideman-one.com/gw/brain/fs/surfacefileformats.htm: Patch File -Binary
*Location (byte)* *Item*
*Types* *Comment* 0 PointCount Int4 Count of points to follow (Updated 2003-07-06) ? + ?n vtx x y z Int4, Int2, Int2, Int2 vtx is special: (mris->vertices[k].border)?-(k+1):k+1; See below for explanation (Updated 2003-07-06)
However, things may have changes over time and I was wondering whether the lay-out is still the same. It would really help if someone could indicate the (correct) order, type and size of the bytes in the binary patch file. I.e., it seems to start with a count of the number of vertices that constitute the patch (int4), followed by a vertex-index (int4), and the coordinates (x,y,z; each int2) for each of the vertices. What I don't know is how many bytes (and their type) are used to code each of those elements.
Note that the description of the w-files (the output of mri_vol2surf) seems to be ok: W ("Weight") Format
*Location (byte)* *Item*
*Type* *Comment* 0 Latency Int2 2 Count Int3 Count of vertex-value pairs to follow
5 + 7n VertexNum
Int3
5 + 7n + 3 VertexVal
Float4 mris_convert uses %f I can read those in easily (although I have no idea what latency means...):
Thanks! Cris
Cris Lanting, PhD
MRC Institute of Hearing Research Science Road, University Park
Nottingham NG7 2RD Phone: +44 - (0)115 9223431 cris@ihr.mrc.ac.uk ana@ihr.mrc.ac.uk