beautypg.com

Motorola DSP96002 User Manual

Page 579

background image

B-60

DSP96002 USER’S MANUAL

MOTOROLA

Registers:

d0 = x d4 = limit

d1 = y d5 = unused

d2 = z d6 = unused

d3 = unused d7 = unused

Memory Map:

X Memory Y Memory

Xmin

r0

Xmax

Ymin

Ymax

Zmin

Zmax

Single Point Accept/Reject

Program

ICycles

Words

ori #$80,ccr ;set accept bit 1 1

move y:(r0)+,d4.s ;get window minimum 1 1

fcmp d4,d0 y:(r0)+,d4.s ;x-Xmin 1 1

fcmp d0,d4 y:(r0)+,d4.s ;Xmax-x 1 1

fcmp d4,d1 y:(r0)+,d4,s ;y-Ymin 1 1

fcmp d1,d4 y:(r0)+,d4.s ;Ymax-y 1 1

fcmp d4,d2 y:(r0)+,d4.s ;z-Zmin 1 1

fcmp d2,d4 ;Zmax-z 1 1

--- ---

Totals:

8

8

If the point is within the limits, then the A bit of the CCR is equal to one, otherwise, the point can be rejected.

B.1.33.2

Line Accept/Reject, floating-point Version

This determines if the line from (x0,y0,z0) to (x1,y1,z1) is within a three-dimensional view cube. If the line

is within the cube, the A (accept) bit of the CCR will be set. If the line is entirely outside of the cube, then

the R bit will be cleared. If the line can not be accepted or rejected, then further processing is required to

clip the line where it intersects with a boundary plane.

Registers:

d0 = dimension d4 = unused

d1 = limit d5 = unused

d2 = unused d6 = unused

d3 = unused d7 = unused

Memory Map: