Digital Clipping

The digital world is not as forgiving. When a floating point value larger than what can be held in a 16 bit short integer gets converted into a short, nasty things happen.

First the float gets converted to a 32 bit integer, then the least significant two bytes get copied into the memory allocated for the short.

clipping_d.gif

Try the demo program clip .


back.png next.png