     func bind(#uniform: GLuniform, v: Vec4) {glProgramUniform4fv(id, uniform, 1, toPtr([v]))}
     
     func bind(#uniform: GLuniform, m: Mat4, transpose: GLboolean = GLboolean(GL_FALSE)) {glProgramUniformMatrix4fv(id, uniform, 1, transpose, toPtr([m]))}
+    
+    func bind(#uniform: GLuniform, texture: Texture, index: GLint = 0) {
+        glProgramUniform1i(id, uniform, index)
+        glActiveTexture(GLenum(GL_TEXTURE0 + index))
+        glBindTexture(GLenum(GL_TEXTURE_2D), texture.id)
+    }
     
     // Bind Uniforms using String
     func bind(#uniform: String, x: CFloat) {glProgramUniform1f(id, self.uniform(uniform), x)}

        return CConstPointer<CFloat>(self, data.value)
    }
    
    // Bind Uniforms using Int
    func bind(#uniform: GLuniform, x: CFloat) {glProgramUniform1f(id, uniform, x)}
    func bind(#uniform: GLuniform, x: CFloat, y: CFloat) {glProgramUniform2f(id, uniform, x, y)}
    func bind(#uniform: GLuniform, x: CFloat, y: CFloat, z: CFloat) {glProgramUniform3f(id, uniform, x, y, z)}

    func bind(#uniform: String, v: Vec4) {glProgramUniform4fv(id, self.uniform(uniform), 1, toPtr([v]))}
    
    func bind(#uniform: String, m: Mat4, transpose: GLboolean = GLboolean(GL_FALSE)) {glProgramUniformMatrix4fv(id, self.uniform(uniform), 1, transpose, toPtr([m]))}
    
    func bind(#uniform: String, texture: Texture, index: GLint = 0) {
        glProgramUniform1i(id, self.uniform(uniform), index)
        glActiveTexture(GLenum(GL_TEXTURE0 + index))
        glBindTexture(GLenum(GL_TEXTURE_2D), texture.id)
    }
}
