Lost Y Coordinates of a Cloud after importing

Feel free to ask any question here
thp
Posts: 9
Joined: Mon Nov 19, 2012 12:14 pm

Lost Y Coordinates of a Cloud after importing

Post by thp »

Hello,
Ive converted an .obj Data into a Pointcloud and saved it as an txt. After Importing it to Solidworks 2012 it lost the Y Expansions. I cant figure out what ive messed up. Would be nice if somone could tell me if I made a mistake while exporting the Cloud, or if this is a Bug.

Many thanks

thp
daniel
Site Admin
Posts: 7707
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Lost Y Coordinates of a Cloud after importing

Post by daniel »

Can't reproduce the bug on my side (with the last online version).

When you open the ASCII file with a text editor, what do you see? Does the second column only contains 0?
Daniel, CloudCompare admin
thp
Posts: 9
Joined: Mon Nov 19, 2012 12:14 pm

Re: Lost Y Coordinates of a Cloud after importing

Post by thp »

The entire File is this this (only tried a small platonian Objekt to test)

-------------------------------------------------------------

0,000000 30,000000 50,000000 0,010756 0,527065 0,849757
0,000000 -30,000000 50,000000 0,010756 -0,527065 0,849757
50,000000 0,000000 30,000000 0,849757 0,010756 0,527065
50,000000 0,000000 -30,000000 0,849757 0,010756 -0,527065
0,000000 30,000000 -50,000000 0,010756 0,527065 -0,849757
0,000000 -30,000000 -50,000000 0,010756 -0,527065 -0,849757
-50,000000 0,000000 -30,000000 -0,849757 0,010756 -0,527065
-50,000000 0,000000 30,000000 -0,849757 0,010756 0,527065
30,000000 50,000000 0,000000 0,527065 0,849757 0,010756
-30,000000 50,000000 0,000000 -0,527065 0,849757 0,010756
-30,000000 -50,000000 0,000000 -0,527065 -0,849757 0,010756
30,000000 -50,000000 0,000000 0,527065 -0,849757 0,010756

--------------------------------------------------
Attachments
Platonischer_Koerper.7z
(442 Bytes) Downloaded 430 times
daniel
Site Admin
Posts: 7707
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Lost Y Coordinates of a Cloud after importing

Post by daniel »

When I do the test I got:
0.000000 30.901699 50.000000 0.010756 0.527065 0.849757
0.000000 -30.901699 50.000000 0.010756 -0.527065 0.849757
50.000000 0.000000 30.901699 0.849757 0.010756 0.527065
50.000000 0.000000 -30.901699 0.849757 0.010756 -0.527065
0.000000 30.901699 -50.000000 0.010756 0.527065 -0.849757
0.000000 -30.901699 -50.000000 0.010756 -0.527065 -0.849757
-50.000000 0.000000 -30.901699 -0.849757 0.010756 -0.527065
-50.000000 0.000000 30.901699 -0.849757 0.010756 0.527065
30.901699 50.000000 0.000000 0.527065 0.849757 0.010756
-30.901699 50.000000 0.000000 -0.527065 0.849757 0.010756
-30.901699 -50.000000 0.000000 -0.527065 -0.849757 0.010756
30.901699 -50.000000 0.000000 0.527065 -0.849757 0.010756

The 'Y' coordinate corresponds to the 2nd column (1st = 'X', 2nd = 'Y', 3rd = 'Z', 4th = 'Nx', 5th = 'Ny', 6th = 'Nz'). So it seems ok to me. But in your example you have lost the fractional part?! What version do you use?
Daniel, CloudCompare admin
thp
Posts: 9
Joined: Mon Nov 19, 2012 12:14 pm

Re: Lost Y Coordinates of a Cloud after importing

Post by thp »

The last one I found on github - I installed it on saturday

(the obj file Ive attached and transformed in a cloud was generated in Cinema 4d)
thp
Posts: 9
Joined: Mon Nov 19, 2012 12:14 pm

Re: Lost Y Coordinates of a Cloud after importing

Post by thp »

Was the .obj file already messed up?
daniel
Site Admin
Posts: 7707
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Lost Y Coordinates of a Cloud after importing

Post by daniel »

No the obj file is good. And my own generated cloud is ok. But your cloud file has 'almost ' good Y coordinates, but the fractional part that is missing...

I've tested with the last github version (on Windows) and I still get the right result. Can't reproduce the ASCII file you've posted.

Are you working on Linux? Do you save the 'vertices' cloud directly or do you perform additional steps?
Daniel, CloudCompare admin
thp
Posts: 9
Joined: Mon Nov 19, 2012 12:14 pm

Re: Lost Y Coordinates of a Cloud after importing

Post by thp »

generated it on OSX Snow Leopard. Ill try to redo it again when Im at home where it is installed (Im not sure what I did after opening the .obj).
daniel
Site Admin
Posts: 7707
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Lost Y Coordinates of a Cloud after importing

Post by daniel »

Oh, so you are one of the very first user of CC on OS X... There's good chances it's a bug in the OS X version only.

I'll ask you to check one thing: does the round-off on the points coordinates occurs when reading the OBJ file or when saving the ASCII one?

To check this:
  • 'show' the vertices cloud of your OBJ mesh (you may also have to increase the point size to see them)
  • then SHIFT+click on several vertices (or equivalently use the 'point picking tool')
  • assess that the coordinates are at their original position (or not, i.e. "rounded-off")
Thanks,
Daniel, CloudCompare admin
thp
Posts: 9
Joined: Mon Nov 19, 2012 12:14 pm

Re: Lost Y Coordinates of a Cloud after importing

Post by thp »

Hi,
Ive tried some objects and got this information in the console:

Platonischer Koerper.obj
[18:02:28] [ObjFilter::Load] 12 points, 20 faces
[18:02:28] [ObjFilter::Load] 32 tex. coords, 0 normals
[18:02:28] [ObjFilter::Load] 1 mesh(es) loaded
[18:02:28] [ObjFilter::Load] Mesh has no normal! We will compute them automatically


This one looks stange in the preview window

Orange_2.obj
[18:25:36] [ObjFilter::Load] /Volumes/USB 8 GIG/Punktwolken/Orange_2.obj
[18:25:36] [ObjFilter::Load] 32930 points, 65856 faces
[18:29:48] [ObjFilter::Load] 1 mesh(es) loaded
[18:25:36] [ObjFilter::Load] Mesh has no normal! We will compute them automatically

This is the same one but scaled by factor 10 in cinema 4d before exporting as an .obj (looks normal now)

Orange_2Big.obj
[18:29:48] [ObjFilter::Load] /Volumes/USB 8 GIG/Punktwolken/Orange_2Big.obj
[18:29:48] [ObjFilter::Load] 32930 points, 65856 faces
[18:29:48] [ObjFilter::Load] 1 mesh(es) loaded
[18:29:48] [ObjFilter::Load] Mesh has no normal! We will compute them automatically

I didnt do anything to them except opening and exporting...

I also got no idea how to exit the picking point tool (bug) - i had do close the program to get out of it.


thp
Last edited by thp on Tue Nov 20, 2012 9:42 am, edited 2 times in total.
Post Reply