-
Notifications
You must be signed in to change notification settings - Fork 125
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
[request] Way to export as webp in a script added in actions #59
Comments
Thank you for the report. I believe Photoshop overrides plug-ins for a given file format, so WebPShop may have to mock another file format (not WebP) for this action to work. I doubt this is worth the effort and user-side confusion since Photoshop has partial built-in WebP support. |
I like your webp better :) |
Could you provide more explicit details? |
I was making an action to export files as webp, the idea was using your webp as extension. But chatgpt said that your extension did not provide any way to pass the current file path to the save as. I tried to make a js function ( pre ES in old style for photoshop ), but still it did not work with your webp. Without that, I would have to keep editing the action everything the folder changes. |
I vaguely remember that the "Save" action was working in Photoshop versions prior to 23.2. Is the "Export" action different?
This part should be handled by Photoshop, not by the WebPShop plug-in.
If automation is an important part of your process, I suggest looking at other solutions than Photoshop scripts, in case it fulfills your needs better. For example you could call the cwebp binary in the command line or from a bash/batch script instead of using Photoshop. |
Look. this is the script I tried to execute, as a workaround to the fact that the webshop does not let me pass the current file path to it in the visual actions panel. but I could not make it work. maybe you have an idea over there. I'm using photoshop 2023
|
Thank you for sharing. Unfortunately I do not have access to any Photoshop environment at the moment and I seemingly know less about Photoshop scripting than you do. I can imagine it is possible to get the value of the
Could it fail because it tries to overwrite the document that is currently opened? What about using |
At 14:55 03/01/2024, you wrote:
Thank you for sharing. Unfortunately I do not
have access to any Photoshop environment at the
moment and I seemingly know less about Photoshop
scripting than you do.
I can imagine it is possible to get the value of
the _path resource within the WebPShop plug-in
and to write the file directly. However, as I
said above, going through the Photoshop SDK API
is probably the safest, most platform-independent option.
I believe your issue or question is related to
Photoshop itself and out of the scope of the
WebPShop plug-in. Does it work with another format plug-in?
// Retrieve the file path of the current document
var filePath = currentDoc.filePath;
...
"_path": filePath
Could it fail because it tries to overwrite the
document that is currently opened? What about
using filePath + ".webp" instead?
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the
thread.Message ID:
***@***.***>
Yes it work with any other extension. I guess
that wepshop would need to listen to the current
document path, so the action knows it, somehow, I
on the other hand am not very skilled in custom
plugin coding. I know some of javascript. I got
the PS to test, and can help you testing if you
like. The optimal way is have the webp grab the
current file path by itself, and pass to the
action, when it gets called, somehow. If you do
this, it's the best outcome.
The script was a workaround attempt of mine, but
as the webpshop does not understand the current
file path, the script is useless.
The only situation the action works with the
webpshop, is if I record the action again, save
any image to the wanted destination path. then
afterwards, the next action saves would remember the path and use it.
|
That is kind of you but I will not have enough time to work on this that way.
Do you have an example of a plug-in that works the way you described it? Maybe it is open source and similar enough to WebPShop to import the necessary parts.
But the current file path |
Hi.
I'm trying to make a script that saves the current file as webp, that will get added in actions. I want to you your webp exporter. But I can't find a way to make the javascript ( ExtendedScript ) reference your extension instead of the regular webp.
Can you make a way of making it, with an example script, if possible!?
Thanks!
The text was updated successfully, but these errors were encountered: