예제 #1
0
 public static void GetFloat(GetPName pname, out Matrix4 matrix)
 {
     unsafe
     {
         fixed (Matrix4* ptr = &matrix)
             GetFloat(pname, (float*)ptr);
     }
 }
예제 #2
0
 public static double GetGLInfoDouble(GetPName name)
 {
     double res;
     GL.GetDouble(name, out res);
     return res;
 }
예제 #3
0
 public abstract void GetUnsignedByte([Flow(FlowDirection.In)] GetPName pname, [Flow(FlowDirection.Out)] string data);
예제 #4
0
 public static void GetDouble(GetPName pname, out Vector4d vector)
 {
     unsafe
     {
         fixed (Vector4d* ptr = &vector)
             GetDouble(pname, (double*)ptr);
     }
 }
예제 #5
0
 public abstract unsafe void GetInteger64([Flow(FlowDirection.In)] GetPName pname, [Count(Computed = "pname"), Flow(FlowDirection.Out)] long *data);
예제 #6
0
 public static void glGetFloatv(GetPName pname, ref Single[] data)
 {
     i_OpenGL1_0.glGetFloatv(pname, ref data);
 }
예제 #7
0
 internal static Vector2d GetVector2d(GetPName pname)
 {
     lock (doubleArray) {
         using (Lock())
             GL.GetDouble(pname, doubleArray);
         return new Vector2d(doubleArray);
     }
 }
예제 #8
0
 internal static extern void glGetIntegerv(GetPName pname, [OutAttribute] Int32 * @params);
예제 #9
0
        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;
        }
예제 #10
0
        internal static int GetInt32(GetPName pname, int defaultValue)
        {
            int result;

            GL.GetInteger(pname, out result);
            var error = GL.GetError();
            switch (error) {
                case ErrorCode.NoError: return result;
                case ErrorCode.InvalidEnum: return defaultValue;
                default: throw new InvalidOperationException("Exception thrown with GetInt32(GetPName." + pname + "): ", CreateError(error));
            }
        }
예제 #11
0
 internal static double GetDouble(GetPName pname)
 {
     double result; using (Lock()) GL.GetDouble(pname, out result); return result;
 }
예제 #12
0
 public static int GetGLInfoInt(GetPName name)
 {
     int res;
     GL.GetInteger(name, out res);
     return res;
 }
예제 #13
0
 public static float GetGLInfoFloat(GetPName name)
 {
     float res;
     GL.GetFloat(name, out res);
     return res;
 }
 public static unsafe void GetInteger(this ExtMultiviewDrawBuffers thisApi, [Flow(FlowDirection.In)] GetPName target, [Flow(FlowDirection.In)] uint index, [Flow(FlowDirection.Out)] Span <int> data)
 {
     // SpanOverloader
     thisApi.GetInteger(target, index, out data.GetPinnableReference());
 }
예제 #15
0
		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);
		}
예제 #16
0
 internal static extern void glGetDoublev(GetPName pname, [OutAttribute] Double * @params);
예제 #17
0
		public static void Get(GetPName pname, [Out] Int32[] data)
		{
			unsafe {
				fixed (Int32* p_data = data)
				{
					Debug.Assert(Delegates.pglGetIntegerv != null, "pglGetIntegerv not implemented");
					Delegates.pglGetIntegerv((Int32)pname, p_data);
					LogFunction("glGetIntegerv({0}, {1})", pname, LogValue(data));
				}
			}
			DebugCheckErrors(null);
		}
예제 #18
0
 public unsafe partial void GetInteger64([Flow(FlowDirection.In)] GetPName pname, [Flow(FlowDirection.Out)] long * @params);
 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;
 }
예제 #20
0
 public static void glGetBooleanv(GetPName pname, ref Boolean[] data)
 {
     i_OpenGL1_0.glGetBooleanv(pname, ref data);
 }
        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;
        }
예제 #22
0
        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);

        }
예제 #23
0
        /// <summary>
        /// OpenGLのプロパティを取得します。
        /// </summary>
        private static string Analyze(GetPName pname, GLType type)
        {
            string output;

            switch (type)
            {
            case GLType.Boolean:
                bool result1b;
                GL.GetBoolean(pname, out result1b);
                output = pname + ": " + result1b;
                break;

            case GLType.Int:
                int result1i;
                GL.GetInteger(pname, out result1i);
                output = pname + ": " + result1i;
                break;

            case GLType.IntEnum:
                int result1e;
                GL.GetInteger(pname, out result1e);
                output = pname + ": " + (All)result1e;
                break;

            case GLType.IntArray2:
                int[] result2i = new int[2];
                GL.GetInteger(pname, result2i);
                output = pname + ": ( " + result2i[0] + ", " + result2i[1] + " )";
                break;

            case GLType.IntArray4:
                int[] result4i = new int[4];
                GL.GetInteger(pname, result4i);
                output = pname + ": ( " + result4i[0] + ", " + result4i[1] + " ) ( " + result4i[2] + ", " + result4i[3] + " )";
                break;

            case GLType.Float:
                float result1f;
                GL.GetFloat(pname, out result1f);
                output = pname + ": " + result1f;
                break;

            case GLType.FloatArray2:
                Vector2 result2f;
                GL.GetFloat(pname, out result2f);
                output = pname + ": ( " + result2f.X + ", " + result2f.Y + " )";
                break;

            case GLType.FloatArray4:
                Vector4 result4f;
                GL.GetFloat(pname, out result4f);
                output = pname + ": ( " + result4f.X + ", " + result4f.Y + ", " + result4f.Z + ", " + result4f.W + " )";
                break;

            default:
                throw new NotImplementedException();
            }

            var err = GL.GetError();

            if (err != ErrorCode.NoError)
            {
                //Log.Error("Unsupported Token: " + pname);
            }

            return(output);
        }
예제 #24
0
 /// <summary>
 /// Returns the double value of a selected parameter.
 /// </summary>
 /// <param name="pname">A parameter that returns a single double.</param>
 public static double GetDouble(GetPName pname)
 {
     GetDoublev(pname, double1);
     return(double1[0]);
 }
예제 #25
0
 public partial void GetIntegerIndexed([Flow(FlowDirection.In)] GetPName target, [Flow(FlowDirection.In)] uint index, [Count(Computed = "target"), Flow(FlowDirection.Out)] out int data);
예제 #26
0
 /// <summary>
 /// Returns the value or values of a selected parameter.
 /// </summary>
 /// <param name="pname">Supports Blend, CullFace, DepthTest, DepthWriteMask, </param>
 /// <returns></returns>
 public static bool GetBooleanv(GetPName pname)
 {
     GetBooleanv(pname, bool1);
     return(bool1[0]);
 }
 public static unsafe void GetFloat(this OesViewportArray thisApi, [Flow(FlowDirection.In)] GetPName target, [Flow(FlowDirection.In)] uint index, [Count(Computed = "target"), Flow(FlowDirection.Out)] Span <float> data)
 {
     // SpanOverloader
     thisApi.GetFloat(target, index, out data.GetPinnableReference());
 }
예제 #28
0
		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();
		}
 public static extern void GetBooleanv( GetPName pname, [Out]bool[] @params );
예제 #30
0
 public static void GetIntegerv(GetPName pname, int * @params)
 {
     Interop.Calli((int)pname, @params, GetIntegervAddress);
 }
 public static extern void GetDoublev( GetPName pname, [Out]double[] @params );
예제 #32
0
 internal static extern void glGetBooleanv(GetPName pname, [OutAttribute] bool * @params);
 public static extern void GetFloatv( GetPName pname, [Out]float[] @params );
예제 #34
0
 internal static extern void glGetFloatv(GetPName pname, [OutAttribute] Single * @params);
 public static extern void GetIntegerv( GetPName pname, [Out]int[] @params );
예제 #36
0
		public static int GlGetInteger(GetPName Name)
		{
			int Value;
			GL.GetInteger(Name, out Value);
			return Value;
		}
 public static unsafe void GetFixed(this OesFixedPoint thisApi, [Flow(FlowDirection.In)] GetPName pname, [Count(Computed = "pname"), Flow(FlowDirection.Out)] Span <int> @params)
 {
     // SpanOverloader
     thisApi.GetFixed(pname, out @params.GetPinnableReference());
 }
예제 #38
0
 public partial void GetInteger64([Flow(FlowDirection.In)] GetPName pname, [Flow(FlowDirection.Out)] out long @params);
예제 #39
0
 public static unsafe void GetInteger64(this AppleSync thisApi, [Flow(FlowDirection.In)] GetPName pname, [Flow(FlowDirection.Out)] Span <long> @params)
 {
     // SpanOverloader
     thisApi.GetInteger64(pname, out @params.GetPinnableReference());
 }
 public static unsafe void GetIntegerIndexed(this ExtDrawBuffers2 thisApi, [Flow(FlowDirection.In)] GetPName target, [Flow(FlowDirection.In)] uint index, [Count(Computed = "target"), Flow(FlowDirection.Out)] Span <int> data)
 {
     // SpanOverloader
     thisApi.GetIntegerIndexed(target, index, out data.GetPinnableReference());
 }
예제 #41
0
 public abstract unsafe void GetInteger64([Flow(FlowDirection.In)] GetPName pname, [Flow(FlowDirection.Out)] long * @params);
예제 #42
0
 public static void glGetDoublev(GetPName pname, ref Double[] data)
 {
     i_OpenGL1_0.glGetDoublev(pname, ref data);
 }
예제 #43
0
 public abstract void GetInteger64([Flow(FlowDirection.In)] GetPName pname, [Flow(FlowDirection.Out)] Span <long> @params);
예제 #44
0
 public static void glGetIntegerv(GetPName pname, ref Int32[] data)
 {
     i_OpenGL1_0.glGetIntegerv(pname, ref data);
 }
 public static unsafe void GetUnsignedByte(this ExtMemoryObject thisApi, [Flow(FlowDirection.In)] GetPName pname, [Count(Computed = "pname"), Flow(FlowDirection.Out)] Span <byte> data)
 {
     // SpanOverloader
     thisApi.GetUnsignedByte(pname, out data.GetPinnableReference());
 }
예제 #46
0
 public partial void GetInteger64([Flow(FlowDirection.In)] GetPName pname, [Count(Computed = "pname"), Flow(FlowDirection.Out)] out long data);
예제 #47
0
 /// <summary>
 /// Return the value of the selected parameter.
 /// </summary>
 /// <param name="name">Specifies the parameter value to be returned.</param>
 public static int GetInteger(GetPName name)
 {
     GetIntegerv(name, getInteger);
     return(getInteger[0]);
 }
예제 #48
0
 /// <summary>
 /// Returns the float value of a selected parameter.
 /// </summary>
 /// <param name="pname">A parameter that returns a single float.</param>
 public static float GetFloat(GetPName pname)
 {
     GetFloatv(pname, float1);
     return(float1[0]);
 }
예제 #49
0
		internal static extern void glGetBooleanv(GetPName pname, [OutAttribute] bool* @params);
예제 #50
0
 /// <summary>
 /// Returns the integer value of a selected parameter.
 /// </summary>
 /// <param name="name">A parameter that returns a single integer.</param>
 public static int GetInteger(GetPName name)
 {
     GetIntegerv(name, int1);
     return(int1[0]);
 }
예제 #51
0
		internal static extern void glGetDoublev(GetPName pname, [OutAttribute] Double* @params);
예제 #52
0
 public static void GetDouble(GetPName pname, out Matrix4d matrix)
 {
     unsafe
     {
         fixed (Matrix4d* ptr = &matrix)
             GetDouble(pname, (double*)ptr);
     }
 }
예제 #53
0
		internal static extern void glGetFloatv(GetPName pname, [OutAttribute] Single* @params);
예제 #54
0
 public static void GetFloat(GetPName pname, out Vector4 vector)
 {
     unsafe
     {
         fixed (Vector4* ptr = &vector)
             GetFloat(pname, (float*)ptr);
     }
 }
예제 #55
0
		internal static extern void glGetIntegerv(GetPName pname, [OutAttribute] Int32* @params);
예제 #56
0
 public static int GetInteger(GetPName name)
 {
     int outval;
     GL.GetInteger(name, out outval);
     return outval;
 }
예제 #57
0
 public static void GetFloatv(GetPName pname, float * @params)
 {
     Interop.Calli((int)pname, @params, GetFloatvAddress);
 }
예제 #58
0
		public static void Get(GetPName pname, out Int32 data)
		{
			unsafe {
				fixed (Int32* p_data = &data)
				{
					Debug.Assert(Delegates.pglGetIntegerv != null, "pglGetIntegerv not implemented");
					Delegates.pglGetIntegerv((Int32)pname, p_data);
					CallLog("glGetIntegerv({0}, {1})", pname, data);
				}
			}
			DebugCheckErrors();
		}
예제 #59
0
 public static bool GetGLInfoBool(GetPName name)
 {
     bool res;
     GL.GetBoolean(name, out res);
     return res;
 }