|
From: James W. W. <ja...@fr...> - 2006-07-24 18:11:24
|
Roger Holmes <rog...@mi...> wrote: >We have been using Q3RasterizeCameraTransform_New for some time to >draw a square with a background pattern on it, we have also allowed >the user to do the same thing for a foreground pattern, though that >was fairly useless as it hid all the 3D Objects. I have now allowed >patterns with an alpha channel to be used for the foreground, but >nothing appears. > >I have traced the problem down to ir_geom_transparent_add, which >multiplies all the points >by the Local To Camera matrix (which is a unit matrix at this time), >and then checks if any of the >z coordinates are <= zero. None are, they are all 0.0001 (Peter tells >me this is so that they are in front of the clipping plane). Because >now are <= 0 the routines simply returns (presumably it thinks >the triangle is clipped). If I comment out the test, all is well. > >Should this be fixed in ir_geom_transparent_add or should the >Rasterize Camera Transform set the Local To Camera matrix up >differently? The latter. Camera coordinates are supposed to have the camera pointing down the negative z axis. I have committed a fix. It seems to work right in Geom Test if I use a z value of .0001, but let me know if you see any problems. -- James W. Walker, Innoventive Software LLC <http://www.frameforge3d.com/> |