Added image collection function- needs C support.