• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# IManualResourceLoader类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中IManualResourceLoader的典型用法代码示例。如果您正苦于以下问题:C# IManualResourceLoader类的具体用法?C# IManualResourceLoader怎么用?C# IManualResourceLoader使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IManualResourceLoader类属于命名空间,在下文中一共展示了IManualResourceLoader类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: ARBGpuProgram

		public ARBGpuProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual,
		                      IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{
			// generate a new program
			Gl.glGenProgramsARB( 1, out programId );
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:7,代码来源:ARBGpuProgram.cs


示例2: _create

		/// <summary>
		///    Create the specified type of GpuProgram.
		/// </summary>
		/// <param name="name"></param>
		/// <param name="type"></param>
		/// <returns></returns>
		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 ( this.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)this.factories[ syntaxCode ] ).Create( this, name, handle, group, isManual, loader,
			                                                                          gpt,
			                                                                          syntaxCode );
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:39,代码来源:GLGpuProgramManager.cs


示例3: GLES2Texture

		private List<Image> loadedImages; //Used to hold images between calls to prepare and load.

		public GLES2Texture( ResourceManager creator, string name, ulong handle, string group, bool isManual, IManualResourceLoader loader, GLES2Support support )
			: base( creator, name, handle, group, isManual, loader )
		{
			this.textureID = 0;
			this.glSupport = support;
			this.surfaceList = new List<HardwarePixelBuffer>();
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:9,代码来源:GLES2Texture.cs


示例4: ATIFragmentShaderGpuProgram

		public ATIFragmentShaderGpuProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{
            throw new AxiomException("This needs upgrading");
			programType = Gl.GL_FRAGMENT_SHADER_ATI;
			programId = Gl.glGenFragmentShadersATI( 1 );
		}
开发者ID:WolfgangSt,项目名称:axiom,代码行数:7,代码来源:ATIFragmentShaderGpuProgram.cs


示例5: ATIFragmentShaderGpuProgram

		public ATIFragmentShaderGpuProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{

			programType = Gl.GL_FRAGMENT_SHADER_ATI;
			programId = Gl.glGenFragmentShadersATI( 1 );
		}
开发者ID:mono-soc-2011,项目名称:axiom,代码行数:7,代码来源:ATIFragmentShaderGpuProgram.cs


示例6: D3DTextureManager

        /*
		public D3DTextureManager(D3D.Direct3D manager, D3D.Device device)
		{
           
		}
         */
         

		protected override Resource _create( string name, ulong handle, string group, bool isManual, IManualResourceLoader loader, NameValuePairList createParams )
		{
            // temporary hack
            manager = D3DRenderSystem.Direct3D9;
            device = D3DRenderSystem.ActiveD3D9Device;
			return new D3DTexture( this, name, handle, group, isManual, loader, this.device, this.manager );
		}
开发者ID:WolfgangSt,项目名称:axiom,代码行数:15,代码来源:D3DTextureManager.cs


示例7: NvparseFragmentProgram

		public NvparseFragmentProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{

			// create a display list
			programId = Gl.glGenLists( 1 );
		}
开发者ID:mono-soc-2011,项目名称:axiom,代码行数:7,代码来源:NvparseFragmentProgram.cs


示例8: GLSLESCgProgram

		public GLSLESCgProgram( ResourceManager creator, string name, ulong handle, string group, bool isManual, IManualResourceLoader loader )
			: base( creator, name, handle, group, isManual, loader )
		{
			/*Port notes
			 * Ogre does something odd with a dictionary here, it looks like it has to do with Material serialization 
			 */

			syntaxCode = "cg";
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:9,代码来源:GLSLESCgProgram.cs


示例9: NV3xGpuProgram

		public NV3xGpuProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{

			// generate the program and store the unique name
			Gl.glGenProgramsNV( 1, out programId );

			// find the GL enum for the type of program this is
			programType = ( Type == GpuProgramType.Vertex ) ? Gl.GL_VERTEX_PROGRAM_NV : Gl.GL_FRAGMENT_PROGRAM_NV;
		}
开发者ID:mono-soc-2011,项目名称:axiom,代码行数:10,代码来源:NV3xGpuProgram.cs


示例10: _create

		protected override Resource _create( string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader, GpuProgramType type, string syntaxCode )
		{
			if ( type == GpuProgramType.Vertex )
			{
				return new D3DVertexProgram( this, name, handle, group, isManual, loader, device );
			}
			else
			{
				return new D3DFragmentProgram( this, name, handle, group, isManual, loader, device );
			}
		}
开发者ID:WolfgangSt,项目名称:axiom,代码行数:11,代码来源:D3DGpuProgramManager.cs


示例11: HLSLProgram

        public HLSLProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual,
                            IManualResourceLoader loader )
            : base( parent, name, handle, group, isManual, loader )
        {
            //var device = ( (XnaRenderWindow)Root.Instance.AutoWindow ).Driver.XnaDevice;
            //switch(type)
            //{
            //    case GpuProgramType.Fragment:
            //        assemblerProgram = new XnaFragmentProgram(parent, name, handle, group, isManual, loader, device);
            //        break;
            //    case GpuProgramType.Vertex:
            //        assemblerProgram = new XnaVertexProgram( parent, name, handle, group, isManual, loader, device );
            //        break;
            //    case GpuProgramType.Geometry:
            //        break;
            //}

            preprocessorDefines = string.Empty;
        }
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:19,代码来源:HLSLProgram.cs


示例12: _create

		protected override Resource _create( string name, ulong handle, string group, bool isManual, IManualResourceLoader loader, Collections.NameValuePairList createParams )
		{
			string paramSyntax = string.Empty;
			string paramType = string.Empty;

			if ( createParams == null || createParams.ContainsKey( "syntax" ) == false || createParams.ContainsKey( "type" ) == false )
			{
				throw new AxiomException( "You must supply 'syntax' and 'type' parameters" );
			}
			else
			{
				paramSyntax = createParams[ "syntax" ];
				paramType = createParams[ "type" ];
			}
			CreateGpuProgramDelegate iter = null;
			if ( this._programMap.ContainsKey( paramSyntax ) )
			{
				iter = this._programMap[ paramSyntax ];
			}
			else
			{
				// No factory, this is an unsupported syntax code, probably for another rendersystem
				// Create a basic one, it doesn't matter what it is since it won't be used
				return new GLES2GpuProgram( this, name, handle, group, isManual, loader );
			}
			GpuProgramType gpt;
			if ( paramType == "vertex_program" )
			{
				gpt = GpuProgramType.Vertex;
			}
			else
			{
				gpt = GpuProgramType.Fragment;
			}

			return iter( this, name, handle, group, isManual, loader, gpt, paramSyntax );
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:37,代码来源:GLES2GpuProgramManager.cs


示例13: D3D9HLSLProgram

		public D3D9HLSLProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual,
		                        IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{
			UseColumnMajorMatrices = true;
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:6,代码来源:HLSLProgram.cs


示例14: XnaFragmentProgram

        internal XnaFragmentProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader, XFG.GraphicsDevice device )
			: base( parent, name, handle, group, isManual, loader, device )
		{
		}
开发者ID:WolfgangSt,项目名称:axiom,代码行数:4,代码来源:XnaGpuProgram.cs


示例15: _create

		protected override Resource _create( string name, ulong handle, string group, bool isManual,
		                                     IManualResourceLoader loader, NameValuePairList createParams )
		{
			throw new NotImplementedException( "Base class needs update to 1.7.2790" );
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:5,代码来源:D3D9ResourceManager.cs


示例16: _create

		protected override Resource _create( string name, ulong handle, string group, bool isManual, IManualResourceLoader loader, Axiom.Collections.NameValuePairList createParams )
		{
			return new Mesh( this, name, handle, group, isManual, loader );
		}
开发者ID:WolfgangSt,项目名称:axiom,代码行数:4,代码来源:MeshManager.cs


示例17: Create

		public GLGpuProgram Create( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual,
		                            IManualResourceLoader loader, GpuProgramType type, string syntaxCode )
		{
			// creates and returns a new ATI fragment shader implementation
			GLGpuProgram ret = new ATIFragmentShaderGpuProgram( parent, name, handle, group, isManual, loader );
			ret.Type = type;
			ret.SyntaxCode = syntaxCode;
			return ret;
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:9,代码来源:ATIFragmentShaderGpuProgram.cs


示例18: Create

		public GLGpuProgram Create( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader, GpuProgramType type, string syntaxCode )
		{
			GLGpuProgram ret = new NvparseFragmentProgram( parent, name, handle, group, isManual, loader );
			ret.SyntaxCode = syntaxCode;
			ret.Type = type;
			return ret;
		}
开发者ID:mono-soc-2011,项目名称:axiom,代码行数:7,代码来源:NvparseFragmentProgram.cs


示例19: GLSLProgram

		/// <summary>
		///		Constructor.
		/// </summary>
		public GLSLProgram( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual, IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{
		    InputOperationType = OperationType.TriangleList;
            OutputOperationType = OperationType.TriangleList;
		    MaxOutputVertices = 3;
            
            // Manually assign language now since we use it immediately
            SyntaxCode = "glsl";
		}
开发者ID:mono-soc-2011,项目名称:axiom,代码行数:13,代码来源:GLSLProgram.cs


示例20: Mesh

		public Mesh( ResourceManager parent, string name, ResourceHandle handle, string group, bool isManual,
		             IManualResourceLoader loader )
			: base( parent, name, handle, group, isManual, loader )
		{
			// This will be set to false by serializers 1.3 and above
			this._autoBuildEdgeLists = true;

			// default to static write only for speed
			this._vertexBufferUsage = BufferUsage.StaticWriteOnly;
			this._indexBufferUsage = BufferUsage.StaticWriteOnly;

			// default to having shadow buffers
			this._useVertexShadowBuffer = true;
			this._useIndexShadowBuffer = true;

			// Initialize to default strategy
			this._lodStrategy = LodStrategyManager.Instance.DefaultStrategy;

			// Init first (manual) lod
			var lod = new MeshLodUsage();
			lod.UserValue = float.NaN; // User value not used for base lod level
			lod.Value = this._lodStrategy.BaseValue;
			lod.EdgeData = null;
			lod.ManualMesh = null;
			this.meshLodUsageList.Add( lod );


			// always use software blending for now
			this.useSoftwareBlending = true;

			SkeletonName = "";
		}
开发者ID:ryan-bunker,项目名称:axiom3d,代码行数:32,代码来源:Mesh.cs



注:本文中的IManualResourceLoader类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# IManufacturerService类代码示例发布时间:2022-05-24
下一篇:
C# IMansionContext类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap