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

C# GetPName类代码示例

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

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



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

示例1: Get

		public static void Get(GetPName pname, [Out] float[] data)
		{
			unsafe {
				fixed (float* p_data = data)
				{
					Debug.Assert(Delegates.pglGetFloatv != null, "pglGetFloatv not implemented");
					Delegates.pglGetFloatv((Int32)pname, p_data);
					CallLog("glGetFloatv({0}, {1})", pname, data);
				}
			}
			DebugCheckErrors();
		}
开发者ID:MagmaiKH,项目名称:OpenGL.Net,代码行数:12,代码来源:Gl.VERSION_1_0.cs


示例2: GetGLInfoDouble

 public static double GetGLInfoDouble(GetPName name)
 {
     double res;
     GL.GetDouble(name, out res);
     return res;
 }
开发者ID:LukaHorvat,项目名称:Electric,代码行数:6,代码来源:Firefly.cs


示例3: GetFloat

 public static void GetFloat(GetPName pname, out Matrix4 matrix)
 {
     unsafe
     {
         fixed (Matrix4* ptr = &matrix)
             GetFloat(pname, (float*)ptr);
     }
 }
开发者ID:SnowmanTackler,项目名称:OpenTK,代码行数:8,代码来源:Helper.cs


示例4: glGetIntegerv

		internal static extern void glGetIntegerv(GetPName pname, [OutAttribute] Int32* @params);
开发者ID:nagyist,项目名称:Pencil.Gaming,代码行数:1,代码来源:GLCore.cs


示例5: Analyze

        public void Analyze(GetPName pname, eType type)
        {
            bool result1b;
            int result1i;
            int[] result2i = new int[2];
            int[] result4i = new int[4];
            float result1f;
            Vector2 result2f;
            Vector4 result4f;
            string output;

            switch (type)
            {
                case eType.Boolean:
                    GL.GetBoolean(pname, out result1b);
                    output = pname + ": " + result1b;
                    break;
                case eType.Int:
                    GL.GetInteger(pname, out result1i);
                    output = pname + ": " + result1i;
                    break;
                case eType.IntEnum:
                    GL.GetInteger(pname, out result1i);
                    output = pname + ": " + (All)result1i;
                    break;
                case eType.IntArray2:
                    GL.GetInteger(pname, result2i);
                    output = pname + ": ( " + result2i[0] + ", " + result2i[1] + " )";
                    break;
                case eType.IntArray4:
                    GL.GetInteger(pname, result4i);
                    output = pname + ": ( " + result4i[0] + ", " + result4i[1] + " ) ( " + result4i[2] + ", " + result4i[3] + " )";
                    break;
                case eType.Float:
                    GL.GetFloat(pname, out result1f);
                    output = pname + ": " + result1f;
                    break;
                case eType.FloatArray2:
                    GL.GetFloat(pname, out result2f);
                    output = pname + ": ( " + result2f.X + ", " + result2f.Y + " )";
                    break;
                case eType.FloatArray4:
                    GL.GetFloat(pname, out result4f);
                    output = pname + ": ( " + result4f.X + ", " + result4f.Y + ", " + result4f.Z + ", " + result4f.W + " )";
                    break;
                default: throw new NotImplementedException();
            }

            ErrorCode err = GL.GetError();
            if (err != ErrorCode.NoError)
                Trace.WriteLine("Unsupported Token: " + pname);
            else
                Trace.WriteLine(output);

        }
开发者ID:RetroAchievements,项目名称:opentk,代码行数:55,代码来源:OpenGLDiagnostics.cs


示例6: GetVector2d

 internal static Vector2d GetVector2d(GetPName pname)
 {
     lock (doubleArray) {
         using (Lock())
             GL.GetDouble(pname, doubleArray);
         return new Vector2d(doubleArray);
     }
 }
开发者ID:Burton-Radons,项目名称:Alexandria,代码行数:8,代码来源:Device.cs


示例7: glGetDoublev

		internal static extern void glGetDoublev(GetPName pname, [OutAttribute] Double* @params);
开发者ID:nagyist,项目名称:Pencil.Gaming,代码行数:1,代码来源:GLCore.cs


示例8: GetInt32

        internal static int GetInt32(GetPName pname)
        {
            int result;

            try {
                using (Lock())
                    GL.GetInteger(pname, out result);
            } catch (Exception exception) {
                throw new InvalidOperationException("Exception thrown with GetInt32(GetPName." + pname + ")", exception);
            }

            return result;
        }
开发者ID:Burton-Radons,项目名称:Alexandria,代码行数:13,代码来源:Device.cs


示例9: GetDouble

 internal static double GetDouble(GetPName pname)
 {
     double result; using (Lock()) GL.GetDouble(pname, out result); return result;
 }
开发者ID:Burton-Radons,项目名称:Alexandria,代码行数:4,代码来源:Device.cs


示例10: GetGLInfoInt

 public static int GetGLInfoInt(GetPName name)
 {
     int res;
     GL.GetInteger(name, out res);
     return res;
 }
开发者ID:LukaHorvat,项目名称:Electric,代码行数:6,代码来源:Firefly.cs


示例11: GetGLInfoFloat

 public static float GetGLInfoFloat(GetPName name)
 {
     float res;
     GL.GetFloat(name, out res);
     return res;
 }
开发者ID:LukaHorvat,项目名称:Electric,代码行数:6,代码来源:Firefly.cs


示例12: GetIntegerv

 public static extern void GetIntegerv( GetPName pname, [Out]int[] @params );
开发者ID:werwolfby,项目名称:Managed-OpenGL,代码行数:1,代码来源:OpenGLNative.state-req.cs


示例13: Get

		public static void Get(GetPName pname, out float data)
		{
			unsafe {
				fixed (float* p_data = &data)
				{
					Debug.Assert(Delegates.pglGetFloatv != null, "pglGetFloatv not implemented");
					Delegates.pglGetFloatv((Int32)pname, p_data);
					LogFunction("glGetFloatv({0}, {1})", pname, data);
				}
			}
			DebugCheckErrors(null);
		}
开发者ID:rhynodegreat,项目名称:OpenGL.Net,代码行数:12,代码来源:Gl.VERSION_1_0.cs


示例14: glGetBooleanv

		internal static extern void glGetBooleanv(GetPName pname, [OutAttribute] bool* @params);
开发者ID:nagyist,项目名称:Pencil.Gaming,代码行数:1,代码来源:GLCore.cs


示例15: glGetFloatv

		internal static extern void glGetFloatv(GetPName pname, [OutAttribute] Single* @params);
开发者ID:nagyist,项目名称:Pencil.Gaming,代码行数:1,代码来源:GLCore.cs


示例16: PipelineShaderStageCapabilities

 internal PipelineShaderStageCapabilities(ShaderStage stage, GetPName maxAtomicCounterBuffers, GetPName maxAtomicCounters, GetPName maxCombinedUniformComponents, GetPName maxImageUniforms, GetPName maxShaderStorageBlocks, GetPName maxTextureImageUnits, GetPName maxUniformBlocks, GetPName maxUniformComponents)
     : base(stage, maxAtomicCounterBuffers, maxAtomicCounters, maxImageUniforms, maxShaderStorageBlocks, maxTextureImageUnits, maxUniformBlocks)
 {
     this.maxCombinedUniformComponents = maxCombinedUniformComponents;
     this.maxUniformComponents = maxUniformComponents;
 }
开发者ID:Burton-Radons,项目名称:Alexandria,代码行数:6,代码来源:Capabilities.ShaderStage.cs


示例17: GlGetInteger

		public static int GlGetInteger(GetPName Name)
		{
			int Value;
			GL.GetInteger(Name, out Value);
			return Value;
		}
开发者ID:shin527,项目名称:cspspemu,代码行数:6,代码来源:OpenglGpuImpl.Init.cs


示例18: ShaderStageCapabilities

        internal ShaderStageCapabilities(ShaderStage stage, GetPName maxAtomicCounterBuffers, GetPName maxAtomicCounters, GetPName maxImageUniforms, GetPName maxShaderStorageBlocks, GetPName maxTextureImageUnits, GetPName maxUniformBlocks)
        {
            this.stage = stage;

            this.maxAtomicCounterBuffers = maxAtomicCounterBuffers;
            this.maxAtomicCounters = maxAtomicCounters;
            this.maxImageUniforms = maxImageUniforms;
            this.maxShaderStorageBlocks = maxShaderStorageBlocks;
            this.maxTextureImageUnits = maxTextureImageUnits;
            this.maxUniformBlocks = maxUniformBlocks;
        }
开发者ID:Burton-Radons,项目名称:Alexandria,代码行数:11,代码来源:Capabilities.ShaderStage.cs


示例19: GetBooleanv

 public static extern void GetBooleanv( GetPName pname, [Out]bool[] @params );
开发者ID:werwolfby,项目名称:Managed-OpenGL,代码行数:1,代码来源:OpenGLNative.state-req.cs


示例20: GetDoublev

 public static extern void GetDoublev( GetPName pname, [Out]double[] @params );
开发者ID:werwolfby,项目名称:Managed-OpenGL,代码行数:1,代码来源:OpenGLNative.state-req.cs



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C# GetUrlArgs类代码示例发布时间:2022-05-24
下一篇:
C# GetNextHandlerDelegate类代码示例发布时间: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