montageTwoPngLists
Return to directory of Todd's CASA extensions
Takes two (or three or four) lists of N pngs (or other single-page image types), and puts them side-by-side or one-above-the-other on an N-page pdf. See also
buildPdfFromPngs and
montageTwoPdfs.
Usage:
au.montageTwoPngLists(pnglist1, pnglist2, pnglist3=None, pnglist4=None, pdfname='',
sidebyside=True, filter='', sourceFilter=[], maxpages=0, cleanup=True, filetype='png')
- pnglist1/2/3/4: either a python list of filenames, or a single string containing a directory name and/or a template filename with wildcards (e.g. 'DV*.png')
- pdfname: the name of the PDF to prodce
- sidebyside: True (place them left/right), False (place the second above the first)
- filter: remove all pngs that include this string in the name (e.g. 'DV10')
- sourceFilter: only include pngs that contain one of the strings in this list Note: the sourceFilter option overrides the filter option
- cleanup: parameter passed to buildPdfFromPngs
Example:
fields=['G10.34','G11.92','G12.91','G14.33','G14.63',
'G16.59','G18.67','G19.36','G22.04','G24.94',
'G28.83','G35.03']
au.montageTwoPngLists('*24um*.png', '*_70um*.png', '*160um*.png',
'*870um*.png', pdfname='sofia_sample.pdf',
sourceFilter=fields,
geometry='900x600+20+20')
--
ToddHunter - 2013-11-07