MCPcopy Create free account
hub / github.com/OGRECave/ogre-next / parseScript

Method parseScript

OgreMain/src/OgreScriptCompiler.cpp:1790–1808  ·  view source on GitHub ↗

-----------------------------------------------------------------------

Source from the content-addressed store, hash-verified

1788 }
1789 //-----------------------------------------------------------------------
1790 void ScriptCompilerManager::parseScript( DataStreamPtr &stream, const String &groupName )
1791 {
1792#if OGRE_THREAD_SUPPORT
1793 // check we have an instance for this thread (should always have one for main thread)
1794 if( !OGRE_THREAD_POINTER_GET( mScriptCompiler ) )
1795 {
1796 // create a new instance for this thread - will get deleted when
1797 // the thread dies
1798 OGRE_THREAD_POINTER_SET( mScriptCompiler, OGRE_NEW ScriptCompiler() );
1799 }
1800#endif
1801 // Set the listener on the compiler before we continue
1802 {
1803 OGRE_LOCK_AUTO_MUTEX;
1804 OGRE_THREAD_POINTER_GET( mScriptCompiler )->setListener( mListener );
1805 }
1806 OGRE_THREAD_POINTER_GET( mScriptCompiler )
1807 ->compile( stream->getAsString(), stream->getName(), groupName );
1808 }
1809
1810 //-------------------------------------------------------------------------
1811 String PreApplyTextureAliasesScriptCompilerEvent::eventType = "preApplyTextureAliases";

Callers

nothing calls this directly

Calls 4

getAsStringMethod · 0.80
setListenerMethod · 0.45
compileMethod · 0.45
getNameMethod · 0.45

Tested by

no test coverage detected