/// <summary> /// Copy this GraphicsSurface color buffer into a buffer. /// </summary> /// <param name="ctx"> /// A <see cref="GraphicsContext"/> /// </param> /// <param name="attachment"> /// </param> /// <param name="x"> /// A <see cref="Int32"/> that specify the x coordinate of the lower left corder of the rectangle area to read. /// </param> /// <param name="y"> /// A <see cref="Int32"/> that specify the y coordinate of the lower left corder of the rectangle area to read. /// </param> /// <param name="texture"> /// </param> /// <param name="level"> /// </param> public void CopyColorBuffer(GraphicsContext ctx, uint attachment, uint x, uint y, ref Texture texture, uint level) { CopyBuffer(ctx, (ReadBufferMode)(Gl.COLOR_ATTACHMENT0 + (int)attachment), x, y, ref texture, level); }
/// <summary> /// Construct a TextureAttachment specifing the texture. /// </summary> /// <param name="texture"> /// The <see cref="Texture"/> to be attached to a Framebuffer. /// </param> /// <exception cref="ArgumentNullException"> /// Exception thrown if <paramref name="texture"/> is null. /// </exception> public TextureAttachment(Texture texture) : this(texture, 0) { }