Coordinate not correct when using crop and extent together
Posted: 2015-11-16T18:32:03-07:00
Here the command i used to splice an image into multiple:
Here the result:
The last piece of the column was wrong y coordinate. it's return 9.25391 instead of 3. It should be 0_3.png. If i remove "extent 256x256", it's return correctly but some image not fit with size 256x256. I need all image have to be 256x256, if it not, extend the image and add transparent background it as the command above.
Thanks!
Code: Select all
convert "input.jpg" -resize 1135x -crop 256x256 -background transparent -extent 256x256 -set filename:tile "%[fx:page.x/256]_%[fx:page.y/256]" +repage +adjoin "output\%[filename:tile].png"
The last piece of the column was wrong y coordinate. it's return 9.25391 instead of 3. It should be 0_3.png. If i remove "extent 256x256", it's return correctly but some image not fit with size 256x256. I need all image have to be 256x256, if it not, extend the image and add transparent background it as the command above.
Thanks!