Commit 889dd259 authored by Matvii Zorin's avatar Matvii Zorin
Browse files

drm_hwcomposer: Add rcar-du display backend



ABGR8888 pixel format and layer scaling are unsupported for rcar-du
KMS DRI card. Handle it by overriding the IsClientLayer method for
additional checks.

Signed-off-by: Matvii Zorin's avatarMatvii Zorin <matvii.zorin@globallogic.com>
parent 748bd33a
Pipeline #188043 passed with stage
in 37 seconds
......@@ -98,6 +98,7 @@ cc_library_static {
"backend/backendmanager.cpp",
"backend/displaybackend.cpp",
"backend/displaybackendclient.cpp",
"backend/displaybackendrcardu.cpp",
],
}
......
#include "displaybackendrcardu.h"
#include "backendmanager.h"
#include "drm_fourcc.h"
namespace android {
bool DisplayBackendRCarDu::IsClientLayer(DrmHwcTwo::HwcLayer *layer) {
hwc_drm_bo_t bo;
int ret = importer_->ConvertBoInfo(layer->buffer(), &bo);
if (ret)
return true;
if (bo.format == DRM_FORMAT_ABGR8888)
return true;
if (layer->RequireScalingOrPhasing())
return true;
return DisplayBackend::IsClientLayer(layer);
}
REGISTER_DISPLAY_BACKEND("rcar-du", DisplayBackendRCarDu);
} // namespace android
#ifndef HWC_DISPLAY_BACKEND_RCAR_DU_H
#define HWC_DISPLAY_BACKEND_RCAR_DU_H
#include "displaybackend.h"
#include "drmhwctwo.h"
namespace android {
class DisplayBackendRCarDu : public DisplayBackend {
public:
using DisplayBackend::DisplayBackend;
bool IsClientLayer(DrmHwcTwo::HwcLayer *layer) override;
};
} // namespace android
#endif
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment