Information Technology Reference
In-Depth Information
efficient if it can create long runs which are linear sequences of triangles between nodes. Starting at a boundary
edge, the run will continue as long as type 01 or 10 triangles are found. If a type 11 triangle is found, there are two
runs from this node.
Figure 5.82: The four types of triangle which can be encountered when scanning.
The encoder must remember the existence of nodes in a stack, and pick one run until it ends at a type 00 triangle.
It must then read the stack and encode the other run. When the current run has reached a 00 triangle and the stack
is empty, all the triangles must have been coded.
There is redundancy in the two-bit code describing the triangles. Except for the end triangles, the triangles in a run
will have the value 01 or 10. By transmitting the run length , the decoder knows where the run ends. As only two
values are possible in the run, 01 can be coded as 0 and 10 can be coded as 1 and only this needs be coded for
each triangle. This bit is, of course, the marching bit which determines whether the run leaves the triangle by the
left edge or the right. Clearly in type 00 or 11 triangles there is no marching bit.
Figure 5.83 shows how the triangles are coded. There are seven runs in the example shown, and so seven run
lengths are transmitted. Marching bits are only transmitted for type 01 or 10 triangles and the decoder can
determine how the sequence of marching bits is to be decoded using the run lengths.
Figure 5.83: An example of triangle coding using the body of Figure 5.80. Runs of triangles are created. See text
for details.
Search WWH ::




Custom Search