diff options
author | Michael Tretter <m.tretter@pengutronix.de> | 2019-09-18 19:05:55 +0200 |
---|---|---|
committer | Michael Tretter <m.tretter@pengutronix.de> | 2019-12-19 10:29:34 +0100 |
commit | ec2eeec2bc138bafbea1c9ef41c004b4bd5fe90c (patch) | |
tree | a23b8a522f964e6ac79a254066502969517816f1 | |
parent | e814879fd64084ac4f2e1917a2439dbc8351732d (diff) |
v4l2: print pixelformat as stringm.tretter/pipewire-fixes
The pixelformats are actual 4 letter sequences. Print the letters
instead of the hex value to make the output more readable.
-rw-r--r-- | spa/plugins/v4l2/v4l2-utils.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spa/plugins/v4l2/v4l2-utils.c b/spa/plugins/v4l2/v4l2-utils.c index 9ea6f6a5..9539e7bd 100644 --- a/spa/plugins/v4l2/v4l2-utils.c +++ b/spa/plugins/v4l2/v4l2-utils.c @@ -881,7 +881,7 @@ static int spa_v4l2_set_format(struct impl *this, struct spa_video_info *format, streamparm.parm.capture.timeperframe.numerator = framerate->denom; streamparm.parm.capture.timeperframe.denominator = framerate->num; - spa_log_info(this->log, "v4l2: set %08x %dx%d %d/%d", fmt.fmt.pix.pixelformat, + spa_log_info(this->log, "v4l2: set %.4s %dx%d %d/%d", (char *)&fmt.fmt.pix.pixelformat, fmt.fmt.pix.width, fmt.fmt.pix.height, streamparm.parm.capture.timeperframe.denominator, streamparm.parm.capture.timeperframe.numerator); @@ -902,7 +902,7 @@ static int spa_v4l2_set_format(struct impl *this, struct spa_video_info *format, if (xioctl(dev->fd, VIDIOC_S_PARM, &streamparm) < 0) spa_log_warn(this->log, "VIDIOC_S_PARM: %m"); - spa_log_info(this->log, "v4l2: got %08x %dx%d %d/%d", fmt.fmt.pix.pixelformat, + spa_log_info(this->log, "v4l2: got %.4s %dx%d %d/%d", (char *)&fmt.fmt.pix.pixelformat, fmt.fmt.pix.width, fmt.fmt.pix.height, streamparm.parm.capture.timeperframe.denominator, streamparm.parm.capture.timeperframe.numerator); |