summaryrefslogtreecommitdiff
path: root/win
diff options
context:
space:
mode:
authorleo2004-10-01 05:59:41 +0000
committerleo2004-10-01 05:59:41 +0000
commit92205f43a642bb255e5141d9c471e49e01ac6cb3 (patch)
tree2e773bbcb3ac7b560d982f11079b9fc810c5057c /win
parentc117a3dc16af7346d750475e648252f5dbffce9b (diff)
Better math for the Zoom Extents function.
git-svn-id: http://svn.leocad.org/trunk@359 c7d43263-9d01-0410-8a33-9dba5d9f93d6
Diffstat (limited to 'win')
-rw-r--r--win/Pieceprv.cpp2
-rw-r--r--win/Print.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/win/Pieceprv.cpp b/win/Pieceprv.cpp
index 90fd6e8..5cd68ca 100644
--- a/win/Pieceprv.cpp
+++ b/win/Pieceprv.cpp
@@ -84,7 +84,7 @@ void CPiecePreview::OnPaint()
glLoadIdentity();
if (m_bZoomPreview)
- m_pPieceInfo->ZoomExtents();
+ m_pPieceInfo->ZoomExtents(30.0f, (float)aspect);
else
gluLookAt (-5, -5, 4, 0, 0, 0, 0, 0, 1);
diff --git a/win/Print.cpp b/win/Print.cpp
index 6799913..80c96b2 100644
--- a/win/Print.cpp
+++ b/win/Print.cpp
@@ -293,7 +293,7 @@ static void PrintCatalogThread (CWnd* pParent, CFrameWnd* pMainFrame)
// dlgPrintStatus.SetDlgItemText(AFX_IDC_PRINT_DOCNAME, node->name);
node = node->next;
PieceInfo* pInfo = pLib->GetPieceInfo(node->actual);
- pInfo->ZoomExtents();
+ pInfo->ZoomExtents(30.0f, (float)aspect);
float pos[4] = { 0, 0, 10, 0 };
glLightfv(GL_LIGHT0, GL_POSITION, pos);
@@ -685,7 +685,7 @@ static void PrintPiecesThread(void* pv)
PieceInfo* pInfo = pLib->GetPieceInfo(node->actual);
node = node->next;
- pInfo->ZoomExtents();
+ pInfo->ZoomExtents(30.0f, (float)aspect);
float pos[4] = { 0, 0, 10, 0 };
glLightfv(GL_LIGHT0, GL_POSITION, pos);