문제

I am trying to take an image, say front2.jpg and add "Hello World" arc'd across the top. But I can't seem to figure out how to get this working. I'm getting an errror

-bash: syntax error near unexpected token `('

Command

convert front5.jpg (-gravity north -pointsize 40 -fill '#ffffff' -background none label:'Hello World' -virtual-pixel transparent -distort Arc 320) -geometry +0+0 -composite front2.jpg
도움이 되었습니까?

해결책

Like bash is trying to tell you: take out the parentheses.

convert front5.jpg -gravity north -pointsize 40 -fill '#ffffff' -background none label:'Hello World' -virtual-pixel transparent -distort Arc 320 -geometry +0+0 -composite front2.jpg

I grabbed a random jpg and tried this command on it and got a neat little text arc (that's a pretty cool effect by the way) on the result.

It also works if you escape the parens, but I can't find any noticeable difference in the result, so I'd just use the first one for simplicity.

convert front5.jpg \( -gravity north -pointsize 40 -fill '#ffffff' -background none label:'Hello World' -virtual-pixel transparent -distort Arc 320 \) -geometry +0+0 -composite front2.jpg
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top