Default Coordinate System

Feel free to ask any question here
Post Reply
georef
Posts: 4
Joined: Thu Mar 11, 2021 10:58 pm

Default Coordinate System

Post by georef »

Hi All,

I'm sure this has been asked before but I couldn't find it on the forum or in the manual. What is the are the default axes conventions for CloudCompare? I'm rotating point clouds using MatLab scripts and got the rotations to work assuming an East-North-Up convention but all of the predefined views for the model are off (clicking the bottom view is actually the map view of the point cloud). Does anyone know if CC is ENU, NED, or following some other convention?

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

Re: Default Coordinate System

Post by daniel »

I'm not sure it's a matter of using CC or Meshlab? Isn't it related to your data instead? CC reads the coordinates as they are stored in the input file, and doesn't change the coordinate system nor the units.
Daniel, CloudCompare admin
WargodHernandez
Posts: 187
Joined: Tue Mar 05, 2019 3:59 pm

Re: Default Coordinate System

Post by WargodHernandez »

CC would be ENU, East X, North Y, Up Z
And that should be what you see from the "Top" View when looking at the trihedron in the lower right corner.

if you want more info about how the views are generated you can look at ccGLUtils.cpp

Code: Select all

ccGLMatrixd ccGLUtils::GenerateViewMat(CC_VIEW_ORIENTATION orientation)
{
	CCVector3d eye(0,0,0);
	CCVector3d center(0,0,0);
	CCVector3d top(0,0,0);

	//we look at (0,0,0) by default
	switch (orientation)
	{
	case CC_TOP_VIEW:
		eye.z =  1.0;
		top.y =  1.0;
		break;
	case CC_BOTTOM_VIEW:
		eye.z = -1.0;
		top.y =  1.0;
		break;
	case CC_FRONT_VIEW:
		eye.y = -1.0;
		top.z =  1.0;
		break;
	case CC_BACK_VIEW:
		eye.y =  1.0;
		top.z =  1.0;
		break;
	case CC_LEFT_VIEW:
		eye.x = -1.0;
		top.z =  1.0;
		break;
	case CC_RIGHT_VIEW:
		eye.x =  1.0;
		top.z =  1.0;
		break;
	case CC_ISO_VIEW_1:
		eye.x = -1.0;
		eye.y = -1.0;
		eye.z =  1.0;
		top.x =  1.0;
		top.y =  1.0;
		top.z =  1.0;
		break;
	case CC_ISO_VIEW_2:
		eye.x =  1.0;
		eye.y =  1.0;
		eye.z =  1.0;
		top.x = -1.0;
		top.y = -1.0;
		top.z =  1.0;
		break;
	}

	return ccGLMatrixd::FromViewDirAndUpDir(center-eye,top);
}
WargodHernandez
Posts: 187
Joined: Tue Mar 05, 2019 3:59 pm

Re: Default Coordinate System

Post by WargodHernandez »

Also I based that answer on the ENU system definition I found here http://www.dirsig.org/docs/new/coordina ... ate_system
Post Reply