mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-04 04:06:06 -05:00
config: add tweak.min-stride-alignment
This allows the user to configure the value by which a surface buffer's stride must be an even multiple of. This can be used to ensure the stride meets the GPU driver's requirements for direct import. Defaults to 256. Set to 0 to disable. Closes #2182
This commit is contained in:
parent
80951ab7a6
commit
fac3994154
6 changed files with 29 additions and 1 deletions
5
config.c
5
config.c
|
|
@ -2848,6 +2848,10 @@ parse_section_tweak(struct context *ctx)
|
|||
#endif
|
||||
}
|
||||
|
||||
else if (streq(key, "min-stride-alignment")) {
|
||||
return value_to_uint32(ctx, 10, &conf->tweak.min_stride_alignment);
|
||||
}
|
||||
|
||||
else {
|
||||
LOG_CONTEXTUAL_ERR("not a valid option: %s", key);
|
||||
return false;
|
||||
|
|
@ -3496,6 +3500,7 @@ config_load(struct config *conf, const char *conf_path,
|
|||
.font_monospace_warn = true,
|
||||
.sixel = true,
|
||||
.surface_bit_depth = SHM_BITS_AUTO,
|
||||
.min_stride_alignment = 256,
|
||||
},
|
||||
|
||||
.touch = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue