-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added support for compression and decompression (feature gated by the "compression" feature which is enabled by default). - LZMA, LZ4 and Zlib compression are now all supported for base64 encoded appended data blobs. - Compression level is currently ignored on LZ4 until either the `lz4_flex` crate implements support, or the `lz4` crate supports LZ4 block format. - Binary appended data blobs are currently not supported until [#253](tafia/quick-xml#253) is merged into the `quick-xml` crate. - Note that solutions to either of the above problems should only cause a minor version bumb. Also The VTK file API was changed to include an optional `file_path`, which encodes the original path to the VTK file. This allows relative paths when reading in "parallel" XML files. This is how ParaView deals with "parallel" XML files for instance. Note that the "parallel" files refers to how they are defined in the VTK documentation; async file loading is not yet supprted, but it is planned. bytemuck is not made a mandatory dependency to fix non xml build. The xml feature flag is also now used to disable all xml features in the non-xml build. Added a load_all_pieces function to simplify loading parallel xml VTK files. Renamed `load_piece_data` to `into_loaded_piece_data` and added a `load_piece_data_in_place`. Added a `try_into_xml_format` function to allow compression before exporting.
- Loading branch information
Showing
17 changed files
with
1,077 additions
and
219 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<VTKFile type="PUnstructuredGrid" version="1.0" byte_order="LittleEndian" header_type="UInt64"> | ||
<PUnstructuredGrid GhostLevel="1"> | ||
<PPoints> | ||
<PDataArray type="Float32" Name="Points" NumberOfComponents="3"/> | ||
</PPoints> | ||
<Piece Source="hexahedron_parallel_0.vtu"/> | ||
</PUnstructuredGrid> | ||
</VTKFile> |
Binary file not shown.
4 changes: 2 additions & 2 deletions
4
assets/cube_compressed.pvtu → assets/hexahedron_parallel_lzma.pvtu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
<?xml version="1.0"?> | ||
<VTKFile type="PUnstructuredGrid" version="1.0" byte_order="LittleEndian" header_type="UInt64" compressor="vtkZLibDataCompressor"> | ||
<VTKFile type="PUnstructuredGrid" version="1.0" byte_order="LittleEndian" header_type="UInt32" compressor="vtkLZMADataCompressor"> | ||
<PUnstructuredGrid GhostLevel="1"> | ||
<PPoints> | ||
<PDataArray type="Float32" Name="Points" NumberOfComponents="3"/> | ||
</PPoints> | ||
<Piece Source="cube_compressed/cube_compressed_0.vtu"/> | ||
<Piece Source="hexahedron_parallel_lzma_0.vtu"/> | ||
</PUnstructuredGrid> | ||
</VTKFile> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?xml version="1.0"?> | ||
<VTKFile type="UnstructuredGrid" version="1.0" byte_order="LittleEndian" header_type="UInt32" compressor="vtkLZMADataCompressor"> | ||
<UnstructuredGrid> | ||
<Piece NumberOfPoints="8" NumberOfCells="1" > | ||
<PointData> | ||
</PointData> | ||
<CellData> | ||
</CellData> | ||
<Points> | ||
<DataArray type="Float32" Name="Points" NumberOfComponents="3" format="appended" RangeMin="0" RangeMax="1.7320508076" offset="0" > | ||
<InformationKey name="L2_NORM_FINITE_RANGE" location="vtkDataArray" length="2"> | ||
<Value index="0"> | ||
0 | ||
</Value> | ||
<Value index="1"> | ||
1.7320508076 | ||
</Value> | ||
</InformationKey> | ||
<InformationKey name="L2_NORM_RANGE" location="vtkDataArray" length="2"> | ||
<Value index="0"> | ||
0 | ||
</Value> | ||
<Value index="1"> | ||
1.7320508076 | ||
</Value> | ||
</InformationKey> | ||
</DataArray> | ||
</Points> | ||
<Cells> | ||
<DataArray type="Int64" Name="connectivity" format="appended" RangeMin="" RangeMax="" offset="132" /> | ||
<DataArray type="Int64" Name="offsets" format="appended" RangeMin="" RangeMax="" offset="260" /> | ||
<DataArray type="UInt8" Name="types" format="appended" RangeMin="" RangeMax="" offset="364" /> | ||
</Cells> | ||
</Piece> | ||
</UnstructuredGrid> | ||
<AppendedData encoding="base64"> | ||
_AQAAAACAAABgAAAAUAAAAA==/Td6WFoAAAFpIt42AsAgYCEBHADVyr+K4ABfABhdAABuBMhFyK1W9uD9tSdenv6myo1MgjQtAAAt9fkxAAEwYIDicrKQQpkNAQAAAAABWVo=AQAAAACAAABAAAAATAAAAA==/Td6WFoAAAFpIt42AsAcQCEBHAAHIsY44AA/ABRdAABqf3sRcnVE9tuf42GTc5gyx1nDAFJBZZwAASxAFZ9rb5BCmQ0BAAAAAAFZWg==AQAAAACAAAAIAAAAPAAAAA==/Td6WFoAAAFpIt42AsAMCCEBHAAUM5NTAQAHCAAAAAAAAAAA3MTHtgABHAhEYCrIkEKZDQEAAAAAAVlaAQAAAACAAAABAAAAOAAAAA==/Td6WFoAAAFpIt42AsAFASEBHACtAIx5AQAADAAAAACmo7TbAAEVAaljNGCQQpkNAQAAAAABWVo= | ||
</AppendedData> | ||
</VTKFile> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.