GithubHelp home page GithubHelp logo

magickslicer's People

Contributors

gitter-badger avatar iangilman avatar jmschrack avatar mfk-smart avatar voidvolker avatar wattapik avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

magickslicer's Issues

Dream - Support GDAL tools

Unfortunately image magick does not work when a dimension is larger than 30000 pixels.
GDAL tools seem to support bigger raster files, but the interface is different from convert.
I am trying to understand how can I tweak your great script to use them.
Cheers!

EDIT: I have portions of the script working with gdalinfo and gdal_translate. But they are tuned for my standard use case, and would need work for other cases. Anyway, would be happy to share them.

http://eremita.di.uminho.pt/~ambs/panoramics/0013-vez/index.html

cache resources exhausted

Default (-a), after 14 sub-folders with 0_0.png images, it stopped and threw:

./magick-slicer.sh heightmap.png 
convert-im6.q16: cache resources exhausted `heightmap.png' @ error/cache.c/OpenPixelCache/4083.
convert-im6.q16: cache resources exhausted `heightmap_files/13.png' @ error/cache.c/OpenPixelCache/4083.
convert-im6.q16: No IDATs written into file `heightmap_files/13.png' @ error/png.c/MagickPNGErrorHandler/1641.
convert-im6.q16: no images defined `heightmap_files/13/%[filename:tile].png' @ error/convert.c/ConvertImageCommand/3258.
convert-im6.q16: cache resources exhausted `heightmap_files/14.png' @ error/cache.c/OpenPixelCache/4083.
convert-im6.q16: No IDATs written into file `heightmap_files/14.png' @ error/png.c/MagickPNGErrorHandler/1641.
convert-im6.q16: no images defined `heightmap_files/14/%[filename:tile].png' @ error/convert.c/ConvertImageCommand/3258.

It' s PC tower running on Ubuntu 20.04 with 16GB RAM and free disk space, i5 CPU and GTX970 GC.
Any idea?

More verbose

/magick-slicer.sh -v3 -b heightmap.png 
Parsing key: -b
Parsing key: heightmap.png
Section: Functions
Section: Slicer A
Section: Slicer B
Section: Programm
Slicer B is running...
    Slicing zoom level "0"; image main size is "256"
    Slicing zoom level "1"; image main size is "512"
    Slicing zoom level "2"; image main size is "1024"
    Slicing zoom level "3"; image main size is "2048"
    Slicing zoom level "4"; image main size is "4096"
convert-im6.q16: cache resources exhausted `heightmap.png' @ error/cache.c/OpenPixelCache/4083.
convert-im6.q16: cache resources exhausted `heightmap_files/4.png' @ error/cache.c/OpenPixelCache/4083.
convert-im6.q16: No IDATs written into file `heightmap_files/4.png' @ error/png.c/MagickPNGErrorHandler/1641.
convert-im6.q16: no images defined `heightmap_files/4/%[filename:tile].png' @ error/convert.c/ConvertImageCommand/3258.
    Slicing zoom level "5"; image main size is "8192"
convert-im6.q16: cache resources exhausted `heightmap.png' @ error/cache.c/OpenPixelCache/4083.
convert-im6.q16: cache resources exhausted `heightmap_files/5.png' @ error/cache.c/OpenPixelCache/4083.
convert-im6.q16: No IDATs written into file `heightmap_files/5.png' @ error/png.c/MagickPNGErrorHandler/1641.
convert-im6.q16: no images defined `heightmap_files/5/%[filename:tile].png' @ error/convert.c/ConvertImageCommand/3258.
Slicer B complete

image

Slicing an 8192x8192 image made folder structure off-by-one for openseadragon

I used a square input file of exactly 2^13, and sliced with no command-line arguments. I got a file structure with folders 0...14, with a 128x128 image in 8/ and a single 256x256 image in 9/. Openseadragon seemed to expect that the image in 8 would be 256x256 and 9 would contain four tiles. I "fixed" by hacking the .dzi file to say the full image size was 8193x8193, or (better!), by removing folder 0/ and renaming all the other folders n/ => n-1/

Optimize size of DZI rendered

Hi

I am currently testing magickSlicer for converting large jpeg files to DZI. It works nice.

However, i am facing a problem with the size of rendered DZI. For exemple, for an orginal jpeg file weighting 10Mo, the rendred DZI folder weight 26.2Mo with default option (-w 256 -h 256).
If I change options width and height to 512x512 the DZI folder weight 18.3Mo. It is yet too big because I have to deal with a huge repository of large files.

I wish to know how can I manage options of conversion for getting a DZI folder weighting less or equals to the weight of original files.

Best regards.

Large .psb files

Hi

What is the largest we can go using this tool?
I have a 121 095 x 52 585 pixel image I am trying to convert
It seems to get stuck at level 4 of the zoom tiles

I tried smaller files and they work great

Support tile overlap for DZI

Specified in pixels. Default should be 1. Default tileSize should be 254.

Overlap is added to the size of a tile. So, a middle tile (with neighbors on all sides) with a tileSize of 254 and an overlap of 1 would have an actual size of 256 (254 + 1 for each side). A tile on the edge (with only 1 neighbor) would have an actual size of 255 (254 + the one neighbor side).

Each overlap row or column is basically taken from the side of the neighboring tile. It's like you sliced all the tiles up without overlap, but then just added rows and columns of pixels from each neighboring tile.

Error with arg

Hello,
i've download magick-slicer.sh and made chmod +x
When i launch sh magick-slicer.sh DJI_0001.jpg i have response ๐Ÿ‘

magick-slicer.sh: 418: [[: not found
No source file present. Canceled.

Without any arg response is ok

mycount@mycount-desktop:/media/4T2M/tvix/www/privft/cportail/ExhibMyDrone/PanoDrone/openseadragon-bin-2.4.2/testimg$ sh magick-slicer.sh
 Map tiles generator. License: MIT.
 Version: 0.004
 Date: 05/08/2015

    Usage:
        magick-slicer.sh -u|--usage
        magick-slicer.sh -?|--help|-m|--man [option_name]
        magick-slicer.sh [options] [-i] /source/image [[-o] result/dir]
        magick-slicer.sh /source/image [options] [result/dir]
        magick-slicer.sh /source/image [result/dir] [options]

    Use quotes for path or options with spaces. First unknown string interpreting as source image, if it not defined. Second unknown string is interpreting as result path, if it not defined. Also, for source and result you can use options '-i' and '-o'.

 Options list: 
    -?, --help [option]
    -m, --man
    [ -v, --verbose <level> ]
    [ -v0, -v1, -v2, -v3 ]
    [ -i, --in <file_path> ]
    [ -o, --out <directory_path> ]
    [ -e, --extension <file_extesion> ]
    [ -w, --width <tile_width> ]
    [ -h, --height <tile_height> ]
    [ -s, --step <zoom_step_value> ]
    [ -p, --options 'imagemagick options string']
    [ -g, --gravity <type> ]
    [ -x, --extent ]
    [ -d, --dzi ]
    [ -a, --slicea ]
    [ -b, --sliceb ]
    [ -c, --scaleover ] 
    [ -r, --horizontal ] 
    [ -t, --vertical ] 

I use ubuntu 20.04 with default GNOME Shell 3.36.9

Have you a idea for resolve this ?
Thank by advance

Slicing appears off by 1px

Normally not really visible, I think this is only exaggerated on the diagonal lines we have on the image itself.

Screenshot 2021-07-06 at 09 46 11

Have tried multiple options but every set of images appears to result in the same thing happening. Any ideas?

This is in use with Open Sea Dragon, and effect is only visible when zoomed it at least 5 times.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.