示例#1
0
        private void FormSatelliteRotation_Load(object sender, EventArgs e)
        {
            {
                var items = new TexImage2DFormats[] { TexImage2DFormats.Alpha, TexImage2DFormats.Luminance, TexImage2DFormats.LuminanceAlpha, TexImage2DFormats.RGB, TexImage2DFormats.RGBA };

                foreach (var item in items)
                {
                    this.cmbFormat.Items.Add(item);
                    this.cmbInternalformat.Items.Add(item);
                }
            }

            this.lblCameraType.Text = string.Format("camera type: {0}", this.camera.CameraType);

            MessageBox.Show("Use 'c' to switch camera types between perspective and ortho");
        }
示例#2
0
 /// <summary>
 /// This function sets the image for the currently binded texture.
 /// </summary>
 /// <param name="target">The type of texture, TEXTURE_2D or PROXY_TEXTURE_2D.</param>
 /// <param name="level">For mip-map textures, ordinary textures should be '0'.</param>
 /// <param name="internalformat">The format of the data you are want OpenGL to create, e.g  RGB16.</param>
 /// <param name="width">The width of the texture image (must be a power of 2, e.g 64).</param>
 /// <param name="height">The height of the texture image (must be a power of 2, e.g 32).</param>
 /// <param name="border">The width of the border (0 or 1).</param>
 /// <param name="format">The format of the data you are passing, e.g. RGBA.</param>
 /// <param name="type">The type of data you are passing, e.g GL_BYTE.</param>
 /// <param name="pixels">The actual pixel data.</param>
 public static void TexImage2D(TexImage2DTargets target, int level, TexImage2DFormats internalformat, int width, int height, int border, TexImage2DFormats format, TexImage2DTypes type, IntPtr pixels)
 {
     GL.TexImage2D((uint)target, level, (uint)internalformat, width, height, border, (uint)format, (uint)type, pixels);
 }
示例#3
0
        private void FormSatelliteRotation_Load(object sender, EventArgs e)
        {
            {
                var items = new TexImage2DFormats[] { TexImage2DFormats.Alpha, TexImage2DFormats.Luminance, TexImage2DFormats.LuminanceAlpha, TexImage2DFormats.RGB, TexImage2DFormats.RGBA };

                foreach (var item in items)
                {
                    this.cmbFormat.Items.Add(item);
                    this.cmbInternalformat.Items.Add(item);
                }

            }

            this.lblCameraType.Text = string.Format("camera type: {0}", this.camera.CameraType);

            MessageBox.Show("Use 'c' to switch camera types between perspective and ortho");
        }
示例#4
0
 /// <summary>
 /// This function sets the image for the currently binded texture.
 /// </summary>
 /// <param name="target">The type of texture, TEXTURE_2D or PROXY_TEXTURE_2D.</param>
 /// <param name="level">For mip-map textures, ordinary textures should be '0'.</param>
 /// <param name="internalformat">The format of the data you are want OpenGL to create, e.g  RGB16.</param>
 /// <param name="width">The width of the texture image (must be a power of 2, e.g 64).</param>
 /// <param name="height">The height of the texture image (must be a power of 2, e.g 32).</param>
 /// <param name="border">The width of the border (0 or 1).</param>
 /// <param name="format">The format of the data you are passing, e.g. RGBA.</param>
 /// <param name="type">The type of data you are passing, e.g GL_BYTE.</param>
 /// <param name="pixels">The actual pixel data.</param>
 public static void TexImage2D(TexImage2DTargets target, int level, TexImage2DFormats internalformat, int width, int height, int border, TexImage2DFormats format, TexImage2DTypes type, IntPtr pixels)
 {
     GL.TexImage2D((uint)target, level, (uint)internalformat, width, height, border, (uint)format, (uint)type, pixels);
 }