moved image decode into if check - much faster pic adding now.