Currently the Format doesn't support non-zero origins but it could. In my mind though an image-space coordinate system should always have an origin at (0,0) and extend to the width/height. It seems unnecessarily confusing to do otherwise and I can't think of a reason why we would want to allow it. I could only see it being used for formats that have an integrated sound strip such as cinescope where the image data would start at (0,0) and the strip to the left of it would be in the negative x axis - but why would you want to see it?

Convince me (or pull rank)!

________________________________
From: John Haddon [notifications@github.com]
Sent: Wednesday, May 15, 2013 4:28 PM
To: ImageEngine/gaffer
Cc: Luke Goddard
Subject: Re: [gaffer] Fixed issue #280: Display now obeys the default format. (#297)


In include/GafferImage/ImagePrimitiveSource.inl:

> @@ -163,8 +163,9 @@ GafferImage::Format ImagePrimitiveSource<BaseType>::computeFormat( const Gaffer:
>       if( image )
>       {
>               result = image->getDisplayWindow();
> +             return GafferImage::Format( result.size().x+1, result.size().y+1 );


This seems to ignore non-zero display window origins (it seemed to before as well) - is that right? We could have non-zero origins couldn't we? Format doesn't seem to have a constructor which takes a Box2i but it definitely stores a Box2i internally for the display window...

—
Reply to this email directly or view it on GitHub<https://github.com/ImageEngine/gaffer/pull/297/files#r4246739>.