Flushing image file after write; perhaps that fixes the delay issue.