Language:EN
Pages: 2
Rating : ⭐⭐⭐⭐⭐
Price: $10.99
Page 1 Preview
cwidth integer bit width for rows

Cwidth integer bit width for rows

IV.3 A DIGITAL “DISOLVE” EFFECT

procedure dissolve2 (height, width: integer);

rowshift: integer; shift dist to get row from element

colmask: integer; mask to extract column from element

228

how many bits needed for height?

how many bits needed for width? how wide must the register be?

Now cycle through all sequence elements.

seq ← 1; 1st element (could be any nonzero) loop do
begin
row ← rshift(seq, rowshift); find rownumber for this pixel and column number column ← seq bit-and colmask;
if (row < height) doeselement fall in the array?

GRAPHICS GEMS I Edited by ANDREW S. GLASSNER

IV.3 A DIGITAL “DISOLVE” EFFECT

When you code this, here are some reminders that probably apply to most implementations:

• Don't forget the (0, 0)th element of the array, as handled explicitly in Listings 1 and 3.

You are viewing 1/3rd of the document.Purchase the document to get full access instantly

Immediately available after payment
Both online and downloadable
No strings attached
How It Works
Login account
Login Your Account
Place in cart
Add to Cart
send in the money
Make payment
Document download
Download File
img

Uploaded by : Donald Davies

PageId: DOCD6E772E