parent
dbf9536213
commit
9f80a2a2a9
|
@ -226,10 +226,19 @@ bool OpenGEXParser::parseNextNode() {
|
||||||
//------------------------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------------------------
|
||||||
bool OpenGEXParser::getNodeHeader( std::string &name ) {
|
bool OpenGEXParser::getNodeHeader( std::string &name ) {
|
||||||
bool success( false );
|
bool success( false );
|
||||||
if( m_nodeTypeStack.back() == MetricNode ) {
|
TokenType tokenType( m_nodeTypeStack.back() );
|
||||||
|
if( tokenType == MetricNode ) {
|
||||||
if( getMetricAttributeKey( name ) ) {
|
if( getMetricAttributeKey( name ) ) {
|
||||||
success = true;
|
success = true;
|
||||||
}
|
}
|
||||||
|
} else if( tokenType == GeometryNode ) {
|
||||||
|
|
||||||
|
} else if( tokenType == GeometryObject ) {
|
||||||
|
|
||||||
|
} else if( tokenType == Material ) {
|
||||||
|
|
||||||
|
} else {
|
||||||
|
DefaultLogger::get()->warn( "Unknown token type in file." );
|
||||||
}
|
}
|
||||||
|
|
||||||
return success;
|
return success;
|
||||||
|
@ -307,9 +316,17 @@ bool OpenGEXParser::getNodeData( const std::string &nodeType ) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
TokenType type( m_nodeTypeStack.back() );
|
const TokenType type( m_nodeTypeStack.back() );
|
||||||
if( type == MetricNode ) {
|
if( type == MetricNode ) {
|
||||||
success = onMetricNode( nodeType );
|
success = onMetricNode( nodeType );
|
||||||
|
} else if( type == GeometryNode ) {
|
||||||
|
success = onGeometryNode();
|
||||||
|
} else if( type == GeometryObject ) {
|
||||||
|
success = onGeometryObject();
|
||||||
|
} else if( type == Material ) {
|
||||||
|
success = onMaterial();
|
||||||
|
} else {
|
||||||
|
DefaultLogger::get()->warn( "Unknown token type in file." );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !getBracketClose() ) {
|
if( !getBracketClose() ) {
|
||||||
|
@ -369,6 +386,21 @@ bool OpenGEXParser::onMetricNode( const std::string &attribName ) {
|
||||||
return success;
|
return success;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//------------------------------------------------------------------------------------------------
|
||||||
|
bool OpenGEXParser::onGeometryNode() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
//------------------------------------------------------------------------------------------------
|
||||||
|
bool OpenGEXParser::onGeometryObject() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
//------------------------------------------------------------------------------------------------
|
||||||
|
bool OpenGEXParser::onMaterial() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
//------------------------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
} // Namespace OpenGEX
|
} // Namespace OpenGEX
|
||||||
|
|
|
@ -97,6 +97,9 @@ protected:
|
||||||
bool getNodeData( const std::string &nodeType );
|
bool getNodeData( const std::string &nodeType );
|
||||||
bool getMetricAttributeKey( std::string &attribName );
|
bool getMetricAttributeKey( std::string &attribName );
|
||||||
bool onMetricNode( const std::string &attribName );
|
bool onMetricNode( const std::string &attribName );
|
||||||
|
bool onGeometryNode();
|
||||||
|
bool onGeometryObject();
|
||||||
|
bool onMaterial();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
OpenGEXParser( const OpenGEXParser & );
|
OpenGEXParser( const OpenGEXParser & );
|
||||||
|
|
Loading…
Reference in New Issue