cache: allow a lambda on recycling each frame