opensourceBIM / BIMserver

The open source BIMserver platform
GNU Affero General Public License v3.0
1.56k stars 611 forks source link

Transformation matrix problem #106

Closed dlabz closed 10 years ago

dlabz commented 10 years ago

I use geometryInfo.getTransformation() to get transformation matrix of IfcProduct instances. For some elements matrix is correct, while for others rows are messed up.

Sending product 524716 ...IfcMember
  goid: 315753376
--MATRIX--
1.0, 0.0, 0.0, 2115.0
0.0, 1.0, 0.0, 0.0
0.0, 0.0, 1.0, 490.0
0.0, 0.0, 0.0, 1.0

Sending product 66176 ...IfcStairFlight
  goid: 318047136
--MATRIX--
1.0, 0.0, 0.0, 5050.0
0.0, 0.0, 1.0, 1000.0
0.0, -1.0, 0.0, 0.0
0.0, 0.0, 0.0, 1.0

I'm not sure if I'm doing something wrong here. I've tried to reset the position of the byte array, and to extract values by giving position of the value in matrix.

version: BIMServer 1.3 final engine: IfcOpenShell model: IfcOpenHouse

edit: updated endians

dlabz commented 10 years ago

Oh, right... I forgot about quaternions...

gstslxd commented 8 years ago

Hi, I know that geometryInfo.getTransformation()= byte[] transformation = new byte[16 * 8]; How can I parse the 4*4 matrix? is each value double or not?

rubendel commented 8 years ago

Please stop crossposting (https://github.com/opensourceBIM/BIMserver/issues/344)