View Single Post
Old 05-04-2008, 01:55 PM   #1589
DavidLee
Registered
 
DavidLee's Avatar
 
Join Date: Apr 2008

Posts: 8
To refine your box filter

[quote=Jim Sachs]How do you tell if a 3D surface (transparent or not) is touching another 3D surface?

To start,I would send one fish program to a unique,one colored background.The fish program modified to send it's own preassigned object identifier number to the main object seperation program.

The background would be defined as object "0". Object definition/priority, pixelmap flow tables would be created (one for each object ie.Background, Coral, Fish Ect.). Intercept the X+Y Horizontal/vertical pixel co-ordinate before it's placed on the screen., including the color attribute byte and the theoretical "Z" (3D depth co-ordinate from the fish program output).

Since at this time you only have one fish, all pixel outputs that are not the background color can be mapped as object "1". Adding others each with a greater priority in the same manner. To speed the program Templates of relative. repeating pixel placement patterns for each object could be created from this input using Calculus.

Every object itself a subprogram program subject to it's unique definition/priority pixelmap flow table.

The main program would encapsulate and maintain seperation of objects by comparing the next pixel redirection output request from each self defined subprogram and when two objects attempt to write to identical X+Y (same pixel) their priority table would give overwrite permission to the object with the smallest "Z"(closest to the front 3D perception) allowing fish to pass in front of each other when in horizontal or vertical motion. When fish are intersecting,the upcomming "identical X+Y+Zs"indicate an upcomming collision the priority tables send an order to redirect fish to the object subprogram with the highest priority.
DavidLee is offline   Reply With Quote