Photoshop engine saving and publishing

Can we save something other than photoshop files?


  • 0
    Rob Blau

    Hi Steven,

    It is possible to save other formats via the Photoshop API that the Photoshop engine makes available to its apps.  We have code examples on how to use that API here: https://support.shotgunsoftware.com/entries/95442348

    Right now there isn't anything we have as part of our default configuration that implements saving as something else, but it would be possible to write publish hooks or your own app to do that.

    What are you hoping to be able to do?  With more details we should be able to give you a better recommendation on how to set it up.

  • 0
    Steven Quinones

    We can't use .psd files in MentalRay, I asume is the same with most renderers. So to stay in the published stream it would be good to have other formats. But I'll look at the documentation. Thanks for the link.


  • 0
    Rob Blau

    Now I understand what you are trying to do.  We do have it on our list to provide this very example, but unfortunately right now the right instructions are scattered a little.

    The example we do have on how to setup a new kind of publish (secondary publish) covers publishing Alembic from Maya and is here:

    It at least walks you through the steps of how to update your config and hooks to add a new type of publish to the system.

    From the Photoshop engine docs, here is the code to save to a different format from photoshop:

    # Export the current doc for the web with default options
    temp_thumb_file = photoshop.RemoteObject('flash.filesystem::File', out_path)
    save_for_web = photoshop.flexbase.requestStatic('com.adobe.photoshop.ExportType', 'SAVEFORWEB')
    export_options = photoshop.RemoteObject('com.adobe.photoshop::ExportOptionsSaveForWeb')
    photoshop.app.activeDocument.exportDocument(temp_thumb_file, save_for_web, export_options)

    For an example of publishing out files other than jpgs, you can see the secondary photoshop publish from our perforce work:

    Once you get past the various perforce commands in that hook, it does save out each layer as a tiff with a thumbnail generated for it.

    Hopefully those examples are enough to pull together the workflow you are looking for!

Please sign in to leave a comment.