-/* $Id$
-
-This file is part of R²C²
-Copyright © 2010 Mikkosoft Productions, Mikko Rasa
-Distributed under the GPL
-*/
-
#include <msp/gl/matrix.h>
#include <msp/gl/renderer.h>
#include "libr2c2/tracktype.h"
#include "track.h"
#include "tracktype.h"
+using namespace std;
using namespace Msp;
namespace R2C2 {
void Path3D::set_path(unsigned p)
{
if(!(track.get_track().get_type().get_paths()&(1<<p)))
- throw InvalidParameterValue("Invalid path");
+ throw invalid_argument("Path3D::set_path");
automatic = false;
paths = 1<<p;
}
void Path3D::set_mask(unsigned p)
{
if(p&~track.get_track().get_type().get_paths())
- throw InvalidParameterValue("Invalid path mask");
+ throw invalid_argument("Path3D::set_mask");
automatic = false;
paths = p;
}
return;
GL::MatrixStack::Push push_mtx(renderer.matrix_stack());
- GL::Matrix matrix = track.get_matrix();
+ GL::Matrix matrix = track.create_matrix();
matrix.translate(0, 0, z_offs);
renderer.matrix_stack() *= matrix;