forked from marfrit/libva-v4l2-request-fourier
Strip HEVC build path
Three changes that together make the build compile cleanly against a current linux-api-headers (>= 5.x post-HEVC-UAPI-rename): - src/meson.build: comment h265.c + h265.h out of sources/headers. - include/hevc-ctrls.h: replace bundled HEVC structs with a single #include <linux/v4l2-controls.h>. The bundled definitions were identical to what later landed in mainline as V4L2_CID_STATELESS_HEVC_* (renamed) and v4l2_ctrl_hevc_* (kept the field names but moved into the kernel public header). Keeping a duplicate copy now triggers redefinition errors. The header is kept as a passthrough rather than deleted so any downstream patch that says #include <hevc-ctrls.h> still compiles. - src/picture.c: drop the four HEVC case blocks. Three of them were in switches that already had `default: break`, so removing them is functionally a no-op. The fourth was the only external reference to h265_set_controls — removing it lets the library link cleanly with h265.c excluded. Why this is OK rather than the more ambitious "fix HEVC properly": RK3566 has no HW HEVC at all (the only decoder block is the Hantro G1 which speaks H.264 / MPEG-2 / VP8). HEVC can come back as a separate effort once we're on RK3588 silicon AND the library is updated to the renamed kernel CIDs. For Fourier's first port milestone (H.264 multi- plane on RK3566 hantro) HEVC is dead weight. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
+3
-24
@@ -91,12 +91,6 @@ static VAStatus codec_store_buffer(struct request_data *driver_data,
|
||||
sizeof(surface_object->params.h264.picture));
|
||||
break;
|
||||
|
||||
case VAProfileHEVCMain:
|
||||
memcpy(&surface_object->params.h265.picture,
|
||||
buffer_object->data,
|
||||
sizeof(surface_object->params.h265.picture));
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -114,12 +108,6 @@ static VAStatus codec_store_buffer(struct request_data *driver_data,
|
||||
sizeof(surface_object->params.h264.slice));
|
||||
break;
|
||||
|
||||
case VAProfileHEVCMain:
|
||||
memcpy(&surface_object->params.h265.slice,
|
||||
buffer_object->data,
|
||||
sizeof(surface_object->params.h265.slice));
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -145,13 +133,6 @@ static VAStatus codec_store_buffer(struct request_data *driver_data,
|
||||
sizeof(surface_object->params.h264.matrix));
|
||||
break;
|
||||
|
||||
case VAProfileHEVCMain:
|
||||
memcpy(&surface_object->params.h265.iqmatrix,
|
||||
buffer_object->data,
|
||||
sizeof(surface_object->params.h265.iqmatrix));
|
||||
surface_object->params.h265.iqmatrix_set = true;
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -189,11 +170,9 @@ static VAStatus codec_set_controls(struct request_data *driver_data,
|
||||
return VA_STATUS_ERROR_OPERATION_FAILED;
|
||||
break;
|
||||
|
||||
case VAProfileHEVCMain:
|
||||
rc = h265_set_controls(driver_data, context, surface_object);
|
||||
if (rc < 0)
|
||||
return VA_STATUS_ERROR_OPERATION_FAILED;
|
||||
break;
|
||||
/* HEVC stripped: kernel V4L2_CID_MPEG_VIDEO_HEVC_* CIDs were renamed
|
||||
* to V4L2_CID_STATELESS_HEVC_* upstream, and ohm's hantro VPU has no
|
||||
* HEVC support anyway. Falls through to the default case below. */
|
||||
|
||||
default:
|
||||
return VA_STATUS_ERROR_UNSUPPORTED_PROFILE;
|
||||
|
||||
Reference in New Issue
Block a user