Axiom.RenderSystems.OpenGL.GLGpuProgramManager._create C# (CSharp) Метод

_create() защищенный Метод

Create the specified type of GpuProgram.
protected _create ( string name, ulong handle, string group, bool isManual, IManualResourceLoader loader, NameValuePairList createParams ) : Axiom.Core.Resource
name string
handle ulong
group string
isManual bool
loader IManualResourceLoader
createParams NameValuePairList
Результат Axiom.Core.Resource
		protected override Resource _create( string name, ulong handle, string group, bool isManual, IManualResourceLoader loader, NameValuePairList createParams )
		{

			if ( createParams == null || ( createParams.ContainsKey( "syntax" ) == false || createParams.ContainsKey( "type" ) == false ) )
			{
				throw new Exception( "You must supply 'syntax' and 'type' parameters" );
			}

			string syntaxCode = createParams[ "syntax" ];
			string type = createParams[ "type" ];

			// if there is none, this syntax code must not be supported
			// just return the base GL program since it won't be doing anything anyway
			if ( factories[ syntaxCode ] == null )
			{
				return new GLGpuProgram( this, name, handle, group, isManual, loader );
			}

			GpuProgramType gpt;
			if ( type == "vertex_program" )
			{
				gpt = GpuProgramType.Vertex;
			}
			else
			{
				gpt = GpuProgramType.Fragment;
			}

			return ( (IOpenGLGpuProgramFactory)factories[ syntaxCode ] ).Create( this, name, handle, group, isManual, loader, gpt, syntaxCode );

		}

Same methods

GLGpuProgramManager::_create ( string name, ulong handle, string group, bool isManual, IManualResourceLoader loader, GpuProgramType type, string syntaxCode ) : Axiom.Core.Resource