Hi Andi, The document that Ken referenced (pg 15 onwards are what you need) are actually enough. However if I understand correctly, you probably just want a really quick solution and don't want to wade through all the details. My suggestion would be to load your file in paraview and then re-save it from there.
File > Save Data: vtm/vtp/vtu ... You should get a "Configure Writer" dialog. Select the appropriate data mode (ASCII, unencoded) and this should give you really quick insight into the contents in an easily readable form. Cheers, /mark ________________________________________ From: ParaView <[email protected]> on behalf of Andi Hartarto <[email protected]> Sent: Saturday, January 14, 2017 7:58 AM To: Moreland, Kenneth Cc: [email protected] Subject: Re: [Paraview] [EXTERNAL] Decode a vtu file Dear Kenneth, Thank you for helping but i didn't mean understanding the text document if that is what you mean. I mean I want to access the appended data in base 64. Maybe in command module somehow (code to show the data) data .. Thank you, Andi On 14 January 2017 at 03:49, Moreland, Kenneth <[email protected]<mailto:[email protected]>> wrote: Documentation for vtu file format (and several other standard VTK formats) is here: http://www.vtk.org/VTK/img/file-formats.pdf -Ken From: ParaView [mailto:[email protected]<mailto:[email protected]>] On Behalf Of Andi Hartarto Sent: Thursday, January 12, 2017 7:54 PM To: [email protected]<mailto:[email protected]> Subject: [EXTERNAL] [Paraview] Decode a vtu file Hello all, Can I please have guidance/help in decoding a vtu file? My file is a <?xml version="1.0"?> <VTKFile type="UnstructuredGrid" version="0.1" byte_order="LittleEndian" compressor="vtkZLibDataCompressor"> <UnstructuredGrid> <Piece NumberOfPoints="116" NumberOfCells="1052" > <PointData> </PointData> <CellData> <DataArray type="Int32" Name="TetrahedraRank" format="appended" RangeMin="1" RangeMax="2" offset="0" /> <DataArray type="Int32" Name="TetrahedraNo" format="appended" RangeMin="0" RangeMax="262" offset="188" /> </CellData> <Points> <DataArray type="Float32" Name="Points" NumberOfComponents="3" format="appended" RangeMin="2003013.3465" RangeMax="2003224.1668" offset="812" /> </Points> <Cells> <DataArray type="Int64" Name="connectivity" format="appended" RangeMin="" RangeMax="" offset="1680" /> <DataArray type="Int64" Name="offsets" format="appended" RangeMin="" RangeMax="" offset="5892" /> <DataArray type="UInt8" Name="types" format="appended" RangeMin="" RangeMax="" offset="8116" /> </Cells> </Piece> </UnstructuredGrid> <AppendedData encoding="base64"> (data long list) The file can be found in this link: https://drive.google.com/open?id=0BzmZiSDoM7l3U2poYWNTbUhBWVU I don't understand how to decode a vtk file and couldn't find anything in google. I've tried using some scripts in python for base64 but it didn't work.. The reason why I need to decode this is because somehow this vtk file which load in paraview perfectly becomes a 2d file in another software "MOOSE" .. So I think somehow in the encoded data is telling the other software "only display the 2D intersection of blocks". But I want a 3D cube not a 2D surface. If someone knows about this please tell me . Thank you, Andi _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the ParaView Wiki at: http://paraview.org/Wiki/ParaView Search the list archives at: http://markmail.org/search/?q=ParaView Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/paraview
