public bool Compile() { GlHelper.ThrowNullException(Id); Gl.CompileShader(Id); GlHelper.GetError(); return(Status); }
public bool Link() { GlHelper.ThrowNullException(Id); Gl.LinkProgram(Id); GlHelper.GetError(); return(Status); }
public override bool Equals(object obj) { GlHelper.ThrowNullException(Id); if (obj is Shader) { return(Equals((Shader)obj)); } return(false); }
public override bool Equals(object obj) { GlHelper.ThrowNullException(Id); if (obj is VertexArray) { return(Equals((VertexArray)obj)); } return(false); }
public override bool Equals(object obj) { GlHelper.ThrowNullException(Target); if (obj is TextureBinding) { return(Equals((TextureBinding)obj)); } return(false); }
public override bool Equals(object obj) { GlHelper.ThrowNullException(Handle); if (obj is Sync) { return(Equals((Sync)obj)); } return(false); }
public void Delete() { GlHelper.ThrowNullException(Id); unsafe { uint id = Id; Gl.DeleteBuffers(1, &id); } }
public void Delete() { GlHelper.ThrowNullException(Id); unsafe { uint id = Id; Gl.DeleteVertexArrays(1, &id); } }
public void Delete() { unsafe { GlHelper.ThrowNullException(Handle); Gl.DeleteSync(Handle.ToPointer()); Handle = IntPtr.Zero; GlHelper.GetError(); } }
public int GetUniformLocation(string name) { GlHelper.ThrowNullException(Id); unsafe { int bytes = Encoding.ASCII.GetByteCount(name); byte *str = stackalloc byte[bytes + 1]; str[bytes] = 0; //null terminated string fixed(char *name_ptr = name) { Encoding.ASCII.GetBytes(name_ptr, name.Length, str, bytes); } var location = Gl.GetUniformLocation(Id, str); GlHelper.GetError(); return(location); } }
public override string ToString() { GlHelper.ThrowNullException(Target); return(string.Format("TextureBinding: {0}", Target.ToString())); }
public override int GetHashCode() { GlHelper.ThrowNullException(Id); return(Id.GetHashCode()); }
public void Delete() { GlHelper.ThrowNullException(Id); Gl.DeleteShader(Id); }
public bool Equals(TextureBinding other) { GlHelper.ThrowNullException(Target); return(Target == other.Target); }
public void DetachShader(Shader shader) { GlHelper.ThrowNullException(Id); Gl.DetachShader(Id, shader.Id); GlHelper.GetError(); }
public bool Equals(Program other) { GlHelper.ThrowNullException(Id); return(Id == other.Id); }
public void Delete() { GlHelper.ThrowNullException(Id); Gl.DeleteProgram(Id); }
public void Bind(Texture texture) { GlHelper.ThrowNullException(Target); Gl.BindTexture(Target, texture.Id); GlHelper.GetError(); }
public bool Equals(Shader other) { GlHelper.ThrowNullException(Id); return(Id == other.Id); }
public override string ToString() { GlHelper.ThrowNullException(Handle); return(string.Format("Sync: {0}", Handle.ToString())); }
public bool Equals(Sync other) { GlHelper.ThrowNullException(Handle); return(Handle == other.Handle); }
public bool Equals(VertexArray other) { GlHelper.ThrowNullException(Id); return(Id == other.Id); }
public override string ToString() { GlHelper.ThrowNullException(Id); return(string.Format("Shader: {0}", Id.ToString())); }
public void Counter() { GlHelper.ThrowNullException(Id); Gl.QueryCounter(Id, Gl.TIMESTAMP); GlHelper.GetError(); }