(01-13-2019, 01:35 PM)Blighty Wrote: I have been playing with this and have some comments.
Join works if I have 5*3 or 5*4 layers, but fails if I have 17 layers. I need to create some additional blank layers for it to work.
I created an image with 20 layers, named Layer 01 to Layer 20. Did the following 2 tests:
Always good to have external testers. Yes, the script requires all divisions to have no rest. If you look at the error console you should have the appropriate messages. One reason for this is that there are various ways to take this in account: additional layers filled? Transparent? Best leave them to the user instead of having Yet Another List of Choices.
(01-13-2019, 01:35 PM)Blighty Wrote: Test 1
1.1 Join 5 col, 4 rows. Keep layers distinct. [works OK]
1.2 Split by rows and cols
Name just {layerName}; superimpose; fit to result.
I end up with 39 layers instead of 20.
I have Layer 02 to Layer 20 (Layer 01 is missing)
and Layers 01 #1 to Layer 01 #20
Only Layer 01 #1 has content, the other 38 are all blank.
I think that what happened there is that
1) you have 20 layers all at 0,0
2) the first "join" only move layers around (Keep layers distinct) so that they make one image (but not one layer)
3) you split... one of the tiles (Layer 01 from you description) , and not the whole image, so this adds 20 layers as expected, and deletes the source layer. The image is resized around Layer 01 so Layer 02 to Layer 20 that lay outside that are become empty.
(01-13-2019, 01:35 PM)Blighty Wrote: Test 2Good
2.1 Join 5 col, 4 rows. single layer. [works OK]
2.2 Split using width and height [works OK - end up with 20 layers]
PS: OK, there is also a bug, parts of the code use the image size instead of the layer size which explains why the re-tiled layer gives weird results.
PPS: OK, fixed, and new version uploaded.