[ISL_FORMAT_${format.name}] = {
.format = ISL_FORMAT_${format.name},
.name = "ISL_FORMAT_${format.name}",
- .bs = ${format.bs},
+ .bpb = ${format.bpb},
+ .bs = ${format.bpb // 8},
.bw = ${format.bw},
.bh = ${format.bh},
.bd = ${format.bd},
self.name = line[0].strip()
# Future division makes this work in python 2.
- self.bs = int(line[1]) // 8
+ self.bpb = int(line[1])
self.bw = line[2].strip()
self.bh = line[3].strip()
self.bd = line[4].strip()
enum isl_format format;
const char *name;
+ uint16_t bpb; /**< Bits per block */
uint8_t bs; /**< Block size, in bytes, rounded towards 0 */
uint8_t bw; /**< Block width, in pixels */
uint8_t bh; /**< Block height, in pixels */