[Paraview] VTI AppendData Multi piece

Nsk Nsk nazca.nsk at gmail.com
Fri Feb 20 10:01:36 EST 2015


Hi

I'm trying to manually write a vti file containing many <Piece> blocks,
each one of them containing several appended DataArray, my current file
looks like this:

<?xml version="1.0"?>
<VTKFile type="ImageData" version="0.1" byte_order="LittleEndian" >
    <ImageData WholeExtent="24 40 24 40 24 40" Origin="-2.00000E-03
-2.00000E-03 -2.00000E-03" Spacing="6.25000E-05 6.25000E-05 6.25000E-05">

        <Piece Extent="26 28 26 28 26 28">
            <CellData>
                <DataArray type="Float32" Name="array1" format="appended"
offset="0" />
                <DataArray type="Int32" Name="array2" format="appended"
offset="36" />
                <DataArray type="Int32" Name="array3" format="appended"
offset="72" />
            </CellData>
        </Piece>
        <Piece Extent="28 32 26 28 24 26">
            <CellData>
                <DataArray type="Float32" Name="array1" format="appended"
offset="108" />
                <DataArray type="Int32" Name="array2" format="appended"
offset="176" />
                <DataArray type="Int32" Name="array3" format="appended"
offset="244" />
            </CellData>
        </Piece>

        ....etc

    </ImageData>
    <AppendedData encoding="raw">
   _[#bytes_array1_Piece1][DATA_array1_Piece1][#bytes_array2_Piece1]
[DATA_array2_Piece1][#bytes_array3_Piece1][DATA_array3_Piece1]
[#bytes_array1_Piece2][DATA_array1_Piece2][#bytes_array2_Piece2][DATA_array2
_Piece2][#bytes_array3_Piece2][DATA_array3_Piece2]...etc..
    </AppendedData>
</VTKFile>

Paraview is able to load the file but the array values seem corrupted. Is
there any special requirement for the AppendData block of multiple pieces
ImageData?
Many thanks,

Nick
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20150220/83dd318f/attachment.html>


More information about the ParaView mailing list