1 // Copyright 2022 The ChromiumOS Authors
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 /// The allow list of VA functions, structures and enum values.
6 const ALLOW_LIST_TYPE : &str = ".*ExternalBuffers.*|.*PRIME.*|.*MPEG2.*|.*VP8.*|.*VP9.*|.*H264.*|.*HEVC.*|VACodedBufferSegment|.*AV1.*|VAEncMisc.*|VASurfaceDecodeMBErrors|VADecodeErrorType";
7 
8 // The common bindgen builder for VA-API.
vaapi_gen_builder(builder: bindgen::Builder) -> bindgen::Builder9 pub fn vaapi_gen_builder(builder: bindgen::Builder) -> bindgen::Builder {
10     builder
11         .derive_default(true)
12         .derive_eq(true)
13         .layout_tests(false)
14         .constified_enum_module("VA.*")
15         .allowlist_var("VA.*")
16         .allowlist_function("va.*")
17         .allowlist_type(ALLOW_LIST_TYPE)
18 }
19