From a146f985695ddaf8ffd2918cba314604111ad5d7 Mon Sep 17 00:00:00 2001 From: David Rose Date: Tue, 11 Dec 2001 19:04:58 +0000 Subject: [PATCH] bring in sync with new lens system --- pandaapp/src/stitchviewer/stitchImageConverter.cxx | 14 +++----------- .../src/stitchviewer/stitchImageVisualizer.cxx | 2 +- 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/pandaapp/src/stitchviewer/stitchImageConverter.cxx b/pandaapp/src/stitchviewer/stitchImageConverter.cxx index 02cce65c31..be120debc3 100644 --- a/pandaapp/src/stitchviewer/stitchImageConverter.cxx +++ b/pandaapp/src/stitchviewer/stitchImageConverter.cxx @@ -26,7 +26,7 @@ #include #include #include -#include +#include #include StitchImageConverter:: @@ -55,16 +55,8 @@ void StitchImageConverter:: setup_camera(const RenderRelation &camera_arc) { PT(Camera) cam = DCAST(Camera, camera_arc.get_child()); - Frustumf frust; - frust._t = 0.5; - frust._b = -0.5; - frust._l = -0.5; - frust._r = 0.5; - frust._fnear = 0.5; - frust._ffar = 2.0; - - PerspectiveProjection proj(frust); - cam->set_projection(proj); + PT(Lens) lens = new PerspectiveLens; + cam->set_lens(lens); } bool StitchImageConverter:: diff --git a/pandaapp/src/stitchviewer/stitchImageVisualizer.cxx b/pandaapp/src/stitchviewer/stitchImageVisualizer.cxx index 9ddc963e3c..fe237b90d4 100644 --- a/pandaapp/src/stitchviewer/stitchImageVisualizer.cxx +++ b/pandaapp/src/stitchviewer/stitchImageVisualizer.cxx @@ -207,7 +207,7 @@ setup() { group_node_index < chanConfig.get_num_groups(); group_node_index++) { DisplayRegion *dr = chanConfig.get_dr(group_node_index); - dr->get_camera()->set_near_far(1.0, 10000.0); + dr->get_camera()->get_lens()->set_near_far(1.0, 10000.0); new RenderRelation(_render, chanConfig.get_group_node(group_node_index)); }