Dear Ben, Rowland Ben <rowland....@claudiusregaud.fr> writes: > I am using PyCUDA to render slices out of a 3D texture which are then > passed to an OpenGL PBO for display on the screen. Everything is going > well except that I cannot get my texture to use the address modes WRAP > or MIRROR correctly, they produce exactly the same effect as CLAMP. I > am confident that I am making a valid function call because when I use > the BORDER mode I get the expected return value of 0 for all lookups > outside the volume, but I can’t get WRAP or MIRROR working. > > The calls simply look like this: > texture.set_address_mode(0, pycuda.driver.address_mode.WRAP) > > I can fake the WRAP behaviour by using "x - floorf(x)” as the coord to > lookup, but this is not as convenient as it is hardcoded into the > kernel, not easily modified in the python side, and it doesn’t let me > use MIRROR either.
If BORDER works, but WRAP and MIRROR do not, it's quite unlikely that this is a bug in PyCUDA--all that it does is expose the constant to Python, everything else is the same between the case of BORDER and WRAP or MIRROR. I've just checked that the right constants get exposed, so that's not likely to be the issue. I'd suggest you either ask Nvidia or try to come up with a self-contained reproducer for the issue so that a variety of people can try and see if it's reproducible. HTH, Andreas
pgp13wnzknbFe.pgp
Description: PGP signature
_______________________________________________ PyCUDA mailing list PyCUDA@tiker.net http://lists.tiker.net/listinfo/pycuda