ctt_intel_texture_compressor/bindings/
kernel_astc.rs1#![allow(non_camel_case_types, non_snake_case, dead_code)]
8
9#[repr(C)]
10#[derive(Debug, Copy, Clone)]
11pub struct rgba_surface {
12 pub ptr: *mut u8,
13 pub width: i32,
14 pub height: i32,
15 pub stride: i32,
16}
17#[repr(C)]
18#[derive(Debug, Copy, Clone)]
19pub struct astc_enc_settings {
20 pub block_width: i32,
21 pub block_height: i32,
22 pub channels: i32,
23 pub fastSkipThreshold: i32,
24 pub refineIterations: i32,
25}
26#[repr(C)]
27#[derive(Debug, Copy, Clone)]
28pub struct astc_enc_context {
29 pub width: i32,
30 pub height: i32,
31 pub channels: i32,
32 pub dual_plane: bool,
33 pub partitions: i32,
34 pub color_endpoint_pairs: i32,
35}
36unsafe extern "C" {
37 pub fn get_programCount() -> i32;
38}
39unsafe extern "C" {
40 pub fn astc_rank_ispc(
41 src: *mut rgba_surface,
42 xx: i32,
43 yy: i32,
44 mode_buffer: *mut u32,
45 settings: *mut astc_enc_settings,
46 );
47}
48unsafe extern "C" {
49 pub fn astc_encode_ispc(
50 src: *mut rgba_surface,
51 block_scores: *mut f32,
52 dst: *mut u8,
53 list: *mut u64,
54 list_context: *mut astc_enc_context,
55 settings: *mut astc_enc_settings,
56 );
57}