summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b9314c4)
raw | patch | inline | side by side (parent: b9314c4)
author | cilix42 <cilix42@users.sourceforge.net> | |
Tue, 7 Aug 2007 07:37:23 +0000 (07:37 +0000) | ||
committer | cilix42 <cilix42@users.sourceforge.net> | |
Tue, 7 Aug 2007 07:37:23 +0000 (07:37 +0000) |
src/perspective3d.cpp | patch | blob | history |
diff --git a/src/perspective3d.cpp b/src/perspective3d.cpp
index bb4963d119952f831efc4024b009ea0162453786..421725bdbd40018f6fd25506f773c9ee1ea5b6d7 100644 (file)
--- a/src/perspective3d.cpp
+++ b/src/perspective3d.cpp
SP3DBox *box = SP_3DBOX (i->data);
if (axes & Box3D::X) {
vp = this->get_vanishing_point (Box3D::X);
- new_pt = vp->get_pos() + box->ratio_x * (box->corners[3] - vp->get_pos());
- sp_3dbox_move_corner_in_XY_plane (box, 2, new_pt);
+ if (vp->is_finite()) {
+ new_pt = vp->get_pos() + box->ratio_x * (box->corners[3] - vp->get_pos());
+ sp_3dbox_move_corner_in_XY_plane (box, 2, new_pt);
+ }
}
if (axes & Box3D::Y) {
vp = this->get_vanishing_point (Box3D::Y);
- new_pt = vp->get_pos() + box->ratio_y * (box->corners[0] - vp->get_pos());
- sp_3dbox_move_corner_in_XY_plane (box, 2, new_pt);
+ if (vp->is_finite()) {
+ new_pt = vp->get_pos() + box->ratio_y * (box->corners[0] - vp->get_pos());
+ sp_3dbox_move_corner_in_XY_plane (box, 2, new_pt);
+ }
}
if (axes & Box3D::Z) {
vp = this->get_vanishing_point (Box3D::Z);
- new_pt = vp->get_pos() + box->ratio_z * (box->corners[0] - vp->get_pos());
- sp_3dbox_move_corner_in_Z_direction (box, 4, new_pt);
+ if (vp->is_finite()) {
+ new_pt = vp->get_pos() + box->ratio_z * (box->corners[0] - vp->get_pos());
+ sp_3dbox_move_corner_in_Z_direction (box, 4, new_pt);
+ }
}
sp_3dbox_set_shape (box, true);