diff options
| author | Maximilian Albert <maximilian.albert@gmail.com> | 2007-08-06 07:20:23 +0000 |
|---|---|---|
| committer | cilix42 <cilix42@users.sourceforge.net> | 2007-08-06 07:20:23 +0000 |
| commit | d01e7d7d15cfcc0b603eecc6a0d0b925f00ee003 (patch) | |
| tree | c2a24485c71bc11cd194266d429f13f7313f6297 /src/inkscape.cpp | |
| parent | Convenience for debugging (diff) | |
| download | inkscape-d01e7d7d15cfcc0b603eecc6a0d0b925f00ee003.tar.gz inkscape-d01e7d7d15cfcc0b603eecc6a0d0b925f00ee003.zip | |
Workaround for some segfaults: Store perspectives globally instead of in each desktop (this should probably be reverted later on)
(bzr r3390)
Diffstat (limited to 'src/inkscape.cpp')
| -rw-r--r-- | src/inkscape.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/inkscape.cpp b/src/inkscape.cpp index c167be493..8f76edddf 100644 --- a/src/inkscape.cpp +++ b/src/inkscape.cpp @@ -59,6 +59,7 @@ using Inkscape::Extension::Internal::PrintWin32; #include "prefs-utils.h" #include "xml/repr.h" #include "io/sys.h" +#include "perspective3d.h" #include "extension/init.h" @@ -597,6 +598,21 @@ inkscape_application_init (const gchar *argv0, gboolean use_gui) /* Initialize the extensions */ Inkscape::Extension::init(); + /* Create an initial perspective, append it to the list of existing perspectives and make it current */ + Box3D::Perspective3D *initial_persp = new Box3D::Perspective3D ( + // VP in x-direction + Box3D::VanishingPoint( NR::Point(-50.0, 600.0), + NR::Point( -1.0, 0.0), Box3D::VP_FINITE), + // VP in y-direction + Box3D::VanishingPoint( NR::Point(500.0,1000.0), + NR::Point( 0.0, 1.0), Box3D::VP_INFINITE), + // VP in z-direction + Box3D::VanishingPoint( NR::Point(700.0, 600.0), + NR::Point(sqrt(3.0),1.0), Box3D::VP_FINITE)); + + Box3D::Perspective3D::current_perspective = initial_persp; + Box3D::Perspective3D::add_perspective (initial_persp); + return; } |
