I want to use VIPS to append a directory of many smaller images in to one massive image. The node module "sharp" uses libvips. Is there any way to use sharp to append 2 images together? VIPS has a "LRJOIN" function but I don't see a sharp implementation of it.
I really just to know the fastest possible way to have VIPS append a directory of images to one big TIFF. The image is too big to use ImageMagick etc. because of memory issues.
Edit:
I used ruby-vips to join the images and call the VIPS command line tool to generate the DZI.
#!/usr/bin/ruby
require 'rubygems'
require 'vips'
a = VIPS::Image.new(ARGV[1])
ARGV[2..-1].each {|name| a = a.tbjoin(VIPS::Image.tiff(name, :compression => :deflated))}
a.write("output.tiff", :compression => :deflated)
system("vips dzsave output.tiff '#{ARGV[0]}'/output_dz.zip --overlap=0 --suffix=.jpg")
I found the code on a ruby-sharp github issue and modified it a bit. The results (just the joining part) for 550 4096x256 images:
real 0m17.283s
user 0m47.045s
sys 0m2.139s