I\'ve read a texture example in OpenGL 2.1. The fragment shader looks like this:
OpenGL 2.1
#version 120 uniform sampler2D texture; varying vec2 texcoord; vo
The sampler2D is bound to a texture unit. The glUniform call binds it to texture unit zero. The glActiveTexture() call is only needed if you are going to use multiple texture units (because GL_TEXTURE0 is the default anyway).
sampler2D
glUniform
glActiveTexture()
GL_TEXTURE0