Anonymous (not verified) Sat, 03/04/2000 - 01:03 Forums: Other usage issuesHi ! gp_Trsf only support uniform scaling, can I do non uniform scaling of a TopoDS_Shape object ? For example if I would like to make an ellipsoid out of a sphere or something like that ? Mikael Arnaud Magnier (not verified) Mon, 03/06/2000 - 05:13 Mikael, There are two key classes to define a non-uniform transformation on a shape. These are: - Class gp_GTrsf to define the transformation by itself. - Class BRepBuilderAPI_GTransform to modify your shape by applying the transformation. Hoping this will help you, regards, Arnaud. Log in to post comments Thomas Moreau (not verified) Mon, 03/06/2000 - 11:37 As Arnaud Magnier told you, you can define a 3D transformation by itself (with a 4-by-4 matrix). And for non uniform scaling, you just have to use this matrix: M= fx 0 0 0 0 fy 0 0 0 0 fz 0 0 0 0 0 where fx, fy, fz define scaling factor for every axis. Regards, Thomas Log in to post comments
Mon, 03/06/2000 - 05:13
Mikael,
There are two key classes to define a non-uniform transformation on a shape. These are:
- Class gp_GTrsf to define the transformation by itself.
- Class BRepBuilderAPI_GTransform to modify your shape by applying the transformation.
Hoping this will help you, regards,
Arnaud.
Mon, 03/06/2000 - 11:37
As Arnaud Magnier told you, you can define a 3D transformation by itself (with a 4-by-4 matrix).
And for non uniform scaling, you just have to use this matrix:
M= fx 0 0 0
0 fy 0 0
0 0 fz 0
0 0 0 0
where fx, fy, fz define scaling factor for every axis.
Regards, Thomas