-
Notifications
You must be signed in to change notification settings - Fork 88
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
path options when calling commands #42
Comments
Provide the file as input file together with input images and in the command reference it using the same name / path. The library will create files passed in inputFiles and then execute the commands. Didn't test it but this should work:
See https://github.com/KnicKnic/WASM-ImageMagick/blob/master/apidocs/interfaces/magickinputfile.md https://github.com/KnicKnic/WASM-ImageMagick/tree/master/apidocs#buildinputfile |
Perfect! I got the file upload working, however ICM/ICC files appear to not be currently supported. It kept throwing an unknown file type. Could it be that the delegates precompiled do not include one that supports ICM/ICC file types? |
So you did tried something like this and it didn't work?: convert rgb_image.jpg -profile USCoat.icm cmyk_image.jpg Did you checked http://www.imagemagick.org/Usage/formats/#profiles ? I never done that but this seems to be a common problem for users... Could you share the command you are trying to execute ? not the files, just the command. Also does the command work on the desktop ? Maybe could be useful you to share how are building the file - as a blob? request ? embedded in a .js file as base64 string ? S since other users have the same problem would be awesome to solve the issue and make some notes in the readme. Thanks |
Sure. I first import my ICM file through the file-loader webpack:
The output of 'tester' is: Then on a button click, I run the imagemagick command. I first convert the profile into a byte array: And then I ran the command:
I get this output: Before, I was just using "tester.icm", but it was suggested to use "icm:tester.icm". Neither worked for me. |
Can you clarify, this is no longer a path options bug, but rather a profile issue. Correct? |
@KnicKnic Correct. I have successfully loaded the ICM file. The issue now is that ICM profiles are not supported with the current WebASM-ImageMagick build. That is the error output I am getting in the console. |
I don't have real experience with profiles but did that command works on the server ? According to the profile (link above) is not a trivial topic... first make sure it works on the real thing... But I suspect we are missing to include some IM configuration xml files in the build that supports this since some commands to get configuration are not working like (["convert","-list","configure"]). Hopefully with the new build knik is working on this get's solved. @KnicKnic could you please leave this issue open to track the problem since I and other users are having similar problems ? thanks! |
@cancerberoSgx I can successfully run the command (["convert", "srcFile.jpeg", "-profile", "tester.icm", "out.jpeg"]) on my instance of ImageMagick in windows (from the command prompt) and have it work. EDIT: By server, do you mean the site I am using WASM-ImageMagick on? I specified a couple posts up the input/output of what I'm trying to do already. |
@DevinKott-KA I am closing this due to it being a dupe. |
I'm in a file a couple directories down from the top, ie ./src/app/xxx/yyy/zzz/file.js
I have a profile I'm trying to apply to an image that's located in ./src/filters/tester.icm.
How should I go about locating tester.icm? I tried using the path ./src/filters/tester.icm, it didn't work. I tried moving tester.icm (using gulp) into dist and just trying ./tester.icm and that didn't work either.
I tried -debug All, but that just told me it couldn't find the file, it didn't tell me the full path it was looking for.
The text was updated successfully, but these errors were encountered: