node-pdf2img
node-pdf2img copied to clipboard
[Error: Command failed: gm identify -format "%p "
Why do I get this error? [Error: Command failed: gm identify -format "%p "
I have gm and gs packages installed.
I am running locally on a Windows machine, but istalling GraphicsMajik's exe did not help. Any suggestions? Ultimately my goal is to get it running in an Azure Function. Thanks, Donnie
here is my code snippet if you need it `
fs.writeFile(__dirname + "/input/" + fileName, pdfBlob, err => {
if (err) {
context.log(err);
} else {
context.log("The PDF has been saved temporarily since it only works with local file path, not blob!");
let input = __dirname + "/input/" + fileName;
pdf2Img.setOptions({
type: "png",
size: 1024,
density: 600,
quality: 100,
outputdir: __dirname + "/output/",
outputname: null,
page: null
});
pdf2Img.convert(input, function(err, info) {
if (err) {
context.log(err);
context.done();
} else {
context.log(info);
context.done();
}
});
}});
`
so, did you solve this problem,I meet the same error.
so, did you solve this problem,I meet the same error.
i am also having the same problem. If anyone has a solution, can you please help?
pdfBlob
这是我的代码片段如果你需要的话 '
fs.writeFile(__dirname + "/input/" + fileName, pdfBlob, err => { if (err) { context.log(err); } else { context.log("The PDF has been saved temporarily since it only works with local file path, not blob!"); let input = __dirname + "/input/" + fileName; pdf2Img.setOptions({ type: "png", size: 1024, density: 600, quality: 100, outputdir: __dirname + "/output/", outputname: null, page: null }); pdf2Img.convert(input, function(err, info) { if (err) { context.log(err); context.done(); } else { context.log(info); context.done(); } }); }});
`
`
hello, What does pdfBlob mean?