Open mcilroyc opened 8 years ago
@pineapplespatula, are you about to check in a fix for this?
this may be addressed by PR #406
I think this is not addressed by 406. One fix for this issue (which I've tested) is to force "exact bounds" for all top-level or document exports.
like:
if ((!layer && !layerComp) ||
isInvisible ||
hasComplexTransform ||
....
Here is another case where exported dimensions are not correct due to layer extending beyond canvas bounds: sjshare/Photoshop/Bugfiles/git/generator-assets/404/
This bug was originally reported in watson # 4136380 via pre-release user.
See attached test file.
transparent-texture-clipping.zip
Note the "texture" layer is larger than the canvas. If it is >50% opacity, the entire layer will be included in the PS thumbnail pixmap and the resultant exported asset is correct. But at <50% Opacity, the PS thumbnail will have slightly smaller bounds (because it clips to visible pixels, and the some outermost pixels fall of the end of the clif at some opacity level).
The problem does not exist if we are using "exact bounds", but in the commonly-used "approximate bounds" approach, it results in the odd clipping behavior. There is a poorly handled mismatch between the full "expected" bounds vs. the slightly-reduced pixmap bounds actually returned by PS. The result is a file less than the 800x800 document size.