frame.compressed(quality=35) 改为frame.to_jpeg(quality=35, copy=True)