MCPcopy Create free account
hub / github.com/CivilHub/CivilHub / crop_background

Function crop_background

gallery/image.py:81–97  ·  view source on GitHub ↗

Crop background images and display them in thumbs. Both arguments are required. Image is PIL image instance (resized and cropped to fit background dimmensions) and pathname means upload path (excluding MEDIA_ROOT, e.g same as in model's field declaration).

(image, pathname, max_size=(270,150))

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers

nothing calls this directly

Calls 3

rename_background_fileFunction · 0.85
resizeMethod · 0.80
saveMethod · 0.45

Tested by

no test coverage detected