SceneError fromString(const string &s) { char *message = new char[s.length() + 1]; strncpy(message, s.c_str(), s.length()+1); return SceneError(message); }
void Scene::SetCamera( Camera *camera ) { if ( m_camera != NULL && camera != NULL ) throw SceneError( "duplicate camera set" ); camera->SetScene( this ); m_camera = camera; }