allows jpegs to work but removed check for correct format
allowed for dynamic picture types