Commit 0484ec79 authored by Jan Möbius's avatar Jan Möbius
Browse files

Fixed some windows crashes with VS2010

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@9078 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 359ad20e
......@@ -155,7 +155,7 @@ void SelectionPlugin::initializePlugin() {
emit addToolbox("Selections",tool_);
// create sphere for paint sphere selection
sphere_mat_node_ = new ACG::SceneGraph::MaterialNode(0, tr("Selection Plugin: Selection Sphere Material").toStdString());
sphere_mat_node_ = new ACG::SceneGraph::MaterialNode(0, tr("Selection Plugin: Selection Sphere Material").toAscii().constData() );
PluginFunctions::addGlobalNode(sphere_mat_node_);
sphere_mat_node_->applyProperties( MaterialNode::Blending |
MaterialNode::Material |
......@@ -166,7 +166,8 @@ void SelectionPlugin::initializePlugin() {
sphere_mat_node_->disable_alpha_test();
sphere_mat_node_->enable_backface_culling();
sphere_node_ = new ACG::SceneGraph::GlutPrimitiveNode(ACG::SceneGraph::GlutPrimitiveNode::SPHERE, sphere_mat_node_, tr("Selection Plugin: Selection Sphere").toStdString());
std::string nodeName = std::string( tr("Selection Plugin: Selection Sphere").toUtf8() );
sphere_node_ = new ACG::SceneGraph::GlutPrimitiveNode(ACG::SceneGraph::GlutPrimitiveNode::SPHERE, sphere_mat_node_,nodeName);
sphere_node_->drawMode(ACG::SceneGraph::DrawModes::SOLID_SMOOTH_SHADED);
sphere_node_->get_primitive(0).color = ACG::Vec4f(1.0, 0.0, 0.0,0.3);
sphere_node_->hide();
......@@ -175,7 +176,8 @@ void SelectionPlugin::initializePlugin() {
sphere_selection_ = false;
line_node_ = new ACG::SceneGraph::LineNode (ACG::SceneGraph::LineNode::PolygonMode,0, tr("Selection Plugin: Lasso Selection Line").toStdString());
nodeName = std::string( tr("Selection Plugin: Lasso Selection Line").toUtf8() );
line_node_ = new ACG::SceneGraph::LineNode (ACG::SceneGraph::LineNode::PolygonMode,0, nodeName );
PluginFunctions::addGlobalNode(line_node_);
line_node_->set_line_width (2.0);
line_node_->depthFunc (GL_ALWAYS);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment