wrong endianess decision for EnSight Binary Gold file bigger then 4 Gbytes
This issue was created automatically from an original Mantis Issue. Further discussion may take place here.
I have a 5.6 Gbytes geometry file for an EnSight Gold Binary case. 467 millions cells. The reader falsely estimates that the endianness is wrong based on some code comparing FileSize and grid dimensions. The reader refuses to read the file.
However, this->FileSize is declared as int and assigned with a cast to (int).
When the physical size is greater than 4Gb, the result stored is actually the real size minus 2^32. The tests evaluate to true and execution is interrupted.
I tested declaring FileSize as a long and removing the cast to (int) on line 82 of vtkEnSightGoldBinaryReader.cxx
the test on line 2973 rightfully evaluates to false and execution continues correctly. I am able to visualize my large file.
Can this patch be generalized? and included in future paraview releases? I tested under 2.6.0