A system, method and computer program product are provided for programmable processing
of fragment data in a computer hardware graphics pipeline. Initially, fragment
data is received in a hardware graphics pipeline. It is then determined whether
the hardware graphics pipeline is operating in a programmable mode. If it is determined
that the hardware graphics pipeline is operating in the programmable mode, programmable
operations are performed on the fragment data in order to generate output. The
programmable operations are performed in a manner/sequence specified in a graphics
application program interface. If it is determined that the hardware graphics pipeline
is not operating in the programmable mode, standard graphics application program
interface (API) operations are performed on the fragment data in order to generate output.