Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PSD: Fix parse issue of layer mask data #1777

Merged
merged 1 commit into from Dec 22, 2017
Merged

PSD: Fix parse issue of layer mask data #1777

merged 1 commit into from Dec 22, 2017

Conversation

ghost
Copy link

@ghost ghost commented Oct 6, 2017

Some PSD files failed to open. I fixed the problem of the PSDInput::load_layer.

Description

The length of the layer mask data was assumed to be several fixed sizes, but it actually varies depending on the mask parameter flags.

We can create this kind of files by using the layer mask options. https://helpx.adobe.com/in/photoshop/using/masking-layers.html#adjust_mask_opacity

Tests

I added new test source which caused the issue to the psd testsuite.

Checklist:

  • I have read the contribution guidelines.
  • If this is more extensive than a small change to existing code, I
    have previously submitted a Contributor License Agreement
    (individual, and if there is any way my
    employers might think my programming belongs to them, then also
    corporate).
  • I have updated the documentation, if applicable.
  • I have ensured that the change is tested somewhere in the testsuite
    (adding new test cases if necessary).
  • My code follows the prevailing code style of this project.

The length of the layer mask data was assumed to be several fixed sizes, but it actually varies depending on the mask parameter flags.
@lgritz
Copy link
Collaborator

lgritz commented Dec 22, 2017

I'm really sorry about letting this languish for so long.

LGTM.

@lgritz lgritz merged commit 239f38c into AcademySoftwareFoundation:master Dec 22, 2017
@ghost ghost deleted the psdlayermaskdata branch December 22, 2017 04:35
GerHobbelt pushed a commit to GerHobbelt/oiio that referenced this pull request Dec 10, 2024
…ependencies (AcademySoftwareFoundation#1777)

* Implementation of ocio_find_package and ocio_install_package macro.
Implemention of minimum, maximum and recommended version.
Refactor the FindOpenImageIO to be inline with the rest of the custom find module (OCIO_USE_OIIO_CMAKE_CONFIG is no longer needed).
Added a new option called OCIO_VERBOSE. It allow the user to tell OCIO to display more information when searching and building the dependencies.
Splitted the find and install part into two files - Find<pkg>.cmake and Install<pkg>.cmake.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Removing a duplicate call to set_property in OpenImageIO find module.
Setting policy CMP0042 when building ZLIB since that project is using an old CMake version as the cmake_minimum_required and that version has no knowledge of the policy.
Fixing a potential issue in Installopenfx. Changing back the version to 1.4 as before.
Ignoring warning from OpenImageIO for imageioapphelpers. The same warning are ignored for ociodisplay, ocioconvert and ociolutimage.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Fixed an issue with FindOpenImageIO that was found while testing on macOS.
Renamed FindOpenShadingLanguage to FindOSL to match the project name used the OSL's CMakefile.
Cleanup the code for FindOSL and removed duplicate warning about needed C++14.

Updated the header comments for all Find and Install modules.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Fixing typo

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Renamed ocio_find_package to ocio_handle_dependency
Renamed ocio_install_package to ocio_install_dependency
The "Installing [...]" message from Install module is now under OCIO_VERBOSE variable. Added a message in ocio_install_dependency instead
Improve the colors usage in the logging

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Changed prefix for ocio_install_dependency since it was conflicting with the prefix of ocio_handle_dependency since they were the same.
Removed FindOpenEXR.cmake and FindOpenImageIO.cmake since they are not needed anymore (for differente reason).
Added PROMOTE_TARGET option for ocio_handle_dependency which promote the target to GLOBAL.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Mostly comments and documentations

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Small update of the Existing Install Hints section

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Changed RECOMMENDED_MIN_VERSION to RECOMMENDED_VERSION
Re-worded some of the comments

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Fixing issue with ocio_handle_dependency macro where it wasn't respecting OCIO_INSTALL_EXT_PACKAGES option correctly.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Adding more documentations and dropping support to look for static zlib since the user can update their cmake in order to do that.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Documentations

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Documentations

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* fixing typo

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Fix typo and fix issue when OCIO is installing ZLIB

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Tentative fix for Linux CI failure

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Ignoring specifics warnings on OpenImageIO target directly.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

* Removing OCIO_USE_OIIO_CMAKE_CONFIG as it is not needed anymore.

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>

---------

Signed-off-by: Cédrik Fuoco <cedrik.fuoco@autodesk.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant