Hi,
when exporting a LAS point cloud file to a PLY file, I lose decimals, ending with only intergers on X, Y coordinates.
Z seems to still have two digits.
Is this normal ?
There is no particular options while saving the file.
Thanks.
Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
-
- Posts: 28
- Joined: Sun Aug 30, 2015 12:11 pm
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
Did you accept to apply the 'Shift on Load' strategy when loading the LAS file? (I guess it has big coordinates?). Are you sure the points still have digits after they have been loaded from the LAS file? (simply shift-click on a point to display its coordinates).
Daniel, CloudCompare admin
-
- Posts: 28
- Joined: Sun Aug 30, 2015 12:11 pm
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
Hello,
Yes I'm applying the shift. I have rather huge coordinates (~ 2 million along X and ~1 million along Y).
I manually entered "rounded" (i.e. with 3 decimal zeros, but they probably do not become integers ?) the X and Y shifts, and setting 0 for the Z values.
And when using the point picking tool, I have the X,X,Y "shifted" coordinates on the left. And the Xg,Yg,Zg "real" coordinates on the right.
All these values have a sufficient amount of decimals (6 digits). And they are not zeros at all.
They correspond to the original data.
Yes I'm applying the shift. I have rather huge coordinates (~ 2 million along X and ~1 million along Y).
I manually entered "rounded" (i.e. with 3 decimal zeros, but they probably do not become integers ?) the X and Y shifts, and setting 0 for the Z values.
And when using the point picking tool, I have the X,X,Y "shifted" coordinates on the left. And the Xg,Yg,Zg "real" coordinates on the right.
All these values have a sufficient amount of decimals (6 digits). And they are not zeros at all.
They correspond to the original data.
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
Do you export the PLY file in ASCII or BINARY format?
Daniel, CloudCompare admin
-
- Posts: 28
- Joined: Sun Aug 30, 2015 12:11 pm
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
In PLY > ASCII.
I have tried the PLY > binary now; there is no problem with it.
But I needed the ASCII to import the points in a human readable format in a GIS software.
A workaround for the moment is to export it as ASCII text file (not PLY); there is the option to set the precision for the output.
And every digits are present in the exported file.
:)
I have tried the PLY > binary now; there is no problem with it.
But I needed the ASCII to import the points in a human readable format in a GIS software.
A workaround for the moment is to export it as ASCII text file (not PLY); there is the option to set the precision for the output.
And every digits are present in the exported file.
:)
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
Indeed, RPly (the third-party library that we use to export PLY files) don't let us define the output precision for ASCII files... I guess we should hack it to allow this.
Daniel, CloudCompare admin
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
Same "problem" here.
I've been working on a cloud from a .las file with local data +/-50m
I set the global shift parameter to output directly in UTM.
however, in the .ply file (ascii), the exported data does not have all the meaningful figures:
It doesn't work (for me) in binary neither.
The workaround would be to export the data in ply format in the local coordinate system, and find another way (via a GIS software?) to shift in the UTM coordinate system.
It would be a nice feature to be able to export large coordinates directly from CC.
I've been working on a cloud from a .las file with local data +/-50m
I set the global shift parameter to output directly in UTM.
however, in the .ply file (ascii), the exported data does not have all the meaningful figures:
Code: Select all
448500 5.40653e+06 60.4567 255 255 255 .......
448500 5.40653e+06 60.4489 255 255 255 .......
The workaround would be to export the data in ply format in the local coordinate system, and find another way (via a GIS software?) to shift in the UTM coordinate system.
It would be a nice feature to be able to export large coordinates directly from CC.
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
Do you mean you can't use Binary PLY files or the global shift mechanism doesn't work in your case?
Daniel, CloudCompare admin
Re: Losing all decimals on coordinates (integers only) when exporting a LAS file to a PLY file
my mistake. Clouds with global shifting to big coordinates are correctly exported to binary ply files (but not ascii ply).daniel wrote:Do you mean you can't use Binary PLY files or the global shift mechanism doesn't work in your case?
The problem was the importation of the binary ply to another software. If I re-open it in CC, the file is correct.