Skip to content

gbm: add gbm_{bo,surface}_create_with_modifiers2

Simon Ser requested to merge emersion/mesa:modifiers2 into main

gbm_{bo,surface}_create_with_modifiers is missing the usage flags. Add a new function which lets library users specify it. Daniel Stone said:

We decided to remove [usage flags] since we decided that modifiers were a good enough proxy for usage; no need to pass SCANOUT or TEXTURE anymore, because we already get the scanout modifiers from KMS and the texture modifiers from EGL.

In hindsight, I think this was a mistake since it only handles buffer layout, and not buffer placement or cache configuration.

Update DRIimageExtension with a new createImageWithModifiers2 function, which is like createImageWithModifiers but with the usage flags added.

Signed-off-by: Simon Ser

cc @daniels

Merge request reports