mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2026-04-17 06:46:39 -04:00
Merge branch 'gbm-flags' into 'master'
Draft: render/allocator/gbm: add bo_flags arg to create function See merge request wlroots/wlroots!4472
This commit is contained in:
commit
ef3cf54af4
4 changed files with 22 additions and 7 deletions
|
|
@ -15,6 +15,7 @@
|
|||
#include "render/wlr_renderer.h"
|
||||
|
||||
#if WLR_HAS_GBM_ALLOCATOR
|
||||
#include <gbm.h>
|
||||
#include "render/allocator/gbm.h"
|
||||
#endif
|
||||
|
||||
|
|
@ -107,7 +108,8 @@ struct wlr_allocator *allocator_autocreate_with_drm_fd(
|
|||
if (gbm_fd < 0) {
|
||||
return NULL;
|
||||
}
|
||||
if ((alloc = wlr_gbm_allocator_create(gbm_fd)) != NULL) {
|
||||
uint32_t bo_flags = GBM_BO_USE_SCANOUT | GBM_BO_USE_RENDERING;
|
||||
if ((alloc = wlr_gbm_allocator_create_with_drm_fd(gbm_fd, bo_flags)) != NULL) {
|
||||
return alloc;
|
||||
}
|
||||
close(gbm_fd);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue