TileMerger

class toasty.merge.TileMerger(pio, merger)[source]

Bases: object

A utility for performing a merge operation with a Pyramid.

Parameters:
piotoasty.pyramid.PyramidIO

Handle for image I/O on the pyramid

mergera merger function

Function for merging tile image data, such as averaging_merger().

Notes

This class provides a walk_callback() method that can be passed to the toasty.pyramid.Pyramid.walk() function. This class preserves some state between calls to help speed up processing.

Methods Summary

walk_callback(pos)

A callback for toasty.pyramid.Pyramid.walk().

Methods Documentation

walk_callback(pos)[source]

A callback for toasty.pyramid.Pyramid.walk().

Parameters:
postoasty.pyramid.Pos

A position for a pyramid tile.

Notes

This function loads up the image data for the four children of the specified position, merges them, and writes out the merged image.