Changeset 151 for osgVisual/src/distortion
- Timestamp:
- Nov 9, 2010, 10:37:40 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
osgVisual/src/distortion/visual_distortion.cpp
r150 r151 49 49 if(config) 50 50 { 51 51 OSG_NOTIFY( osg::ALWAYS ) << "Using distortion." << std::endl; 52 52 53 xmlNode* a_node = config->children; 53 54 … … 55 56 { 56 57 std::string node_name=reinterpret_cast<const char*>(cur_node->name); 57 OSG_ALWAYS << "----visual_distortion::processXMLConfiguration() - node type="<< cur_node->type <<", name=" << cur_node->name << std::endl;58 //OSG_ALWAYS << "----visual_distortion::processXMLConfiguration() - node type="<< cur_node->type <<", name=" << cur_node->name << std::endl; 58 59 59 60 // Check for distortion node … … 68 69 { 69 70 std::string channelname = attr_value; 70 OSG_NOTIFY(osg::ALWAYS) << " channelname:" << channelname << std::endl;71 OSG_NOTIFY(osg::ALWAYS) << "visual_distortion: Channelname:" << channelname << std::endl; 71 72 72 73 std::string pre_cfg("..\\resources\\distortion\\view_"); … … 136 137 distortMapFileName = attr_value; 137 138 } 138 139 139 attr = attr->next; 140 140 } … … 153 153 blendMapFileName = attr_value; 154 154 } 155 156 155 attr = attr->next; 157 156 } … … 159 158 } // FOR all nodes END 160 159 161 160 // clean up 161 xmlFreeDoc(tmpDoc); xmlCleanupParser(); 162 return true; 162 163 } // IF Config valid END 163 164 else 164 OSG_WARN << "ERROR: visual_distortion::processXMLConfiguration() - Invalid module configuration!" << std::endl; 165 166 167 168 // clean up 169 if(tmpDoc) 170 { 171 xmlFreeDoc(tmpDoc); xmlCleanupParser(); 172 return true; 165 { 166 OSG_WARN << "WARNING: visual_distortion::processXMLConfiguration() - Module configuration not found or module disabled!" << std::endl; 167 return false; 173 168 } 169 170 174 171 175 172 return true; … … 191 188 192 189 // Process XML configuration 193 processXMLConfiguration(); 190 if(!processXMLConfiguration()) 191 return NULL; // Abort distortion initialization. 194 192 195 193 // Add this node to the scenegraph to get updated during update traversal.
Note: See TracChangeset
for help on using the changeset viewer.