hit counter

Timeline

My development logbook

OpenGL ES: Vsh and Fsh

Again, learn something new today.

OpenGL ES 2.0 contains a kind of mini-language to define vertex and fragment shader. They are usually stored in files with extension vsh and fsh respectively.

iOS and OpenGL ES

As a newcomer on the iOS platform, it really takes a while to understand the support of the OpenGL ES standard on the iPhone/iPad platform.

According to the Apple doc,

Apple offers hardware that supports both OpenGL ES 1.1 and OpenGL ES 2.0.

I suppose it means both ES 1.1 and 2.0 are supported by iPhone and iPad.

glColor3f and OpenGL ES 2.0

glColor3f is not available in OpenGL ES.

Now I realised that OpenGL ES should be regarded as a standard in its own right, not a subset of the OpenGL.

KVO - Key Value Observation

Use

1
addObserver:forKeyPath:options:context:

to register an observer to the observed object.

Use

1
observeValueForKeyPath:ofObject:change:context:

to capture the fired, observing events.