I think this is correct. Here is the comment at the declaration of do_wrap:
// Given x,y,z known to be outside the pixel data range, and a wrap // mode, alter xyz to implement the wrap. Return true if the resulting // x,y,z is within the valid pixel data window, false if it still is // not. bool do_wrap(int& x, int& y, int& z, WrapMode wrap) const; This is a private method, and so if it's only called when x,y,z is outside the data window, then by definition the union of the data window and the display window is... the display window. > On Mar 28, 2022, at 8:30 PM, Nathan Rusch <nathanru...@gmail.com> wrote: > > I was looking at the source of `ImageBufImpl::do_wrap` today, and I noticed > that `WrapClamp` always clamps the input coordinates using the display window > coordinates (`full_x`, `full_y`, `full_width`, `full_height`, etc.). > > I always assumed `WrapClamp` would clamp out-of-bounds coordinates to the > available image area (i.e. the union of the data and display windows), but is > that not the intended behavior? > > Thanks, > -Nathan > _______________________________________________ > Oiio-dev mailing list > Oiio-dev@lists.openimageio.org > http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org -- Larry Gritz l...@larrygritz.com
_______________________________________________ Oiio-dev mailing list Oiio-dev@lists.openimageio.org http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org