added pixel_buf instead of buffer