mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-08-23 18:27:20 +02:00
hle: nvflinger: Add IConsumerListener interface.
This commit is contained in:
parent
81e143a3d2
commit
b9cbc708e8
@ -538,6 +538,7 @@ add_library(core STATIC
|
||||
hle/service/nvflinger/buffer_queue.cpp
|
||||
hle/service/nvflinger/buffer_queue.h
|
||||
hle/service/nvflinger/buffer_transform_flags.h
|
||||
hle/service/nvflinger/consumer_listener.h
|
||||
hle/service/nvflinger/nvflinger.cpp
|
||||
hle/service/nvflinger/nvflinger.h
|
||||
hle/service/nvflinger/pixel_format.h
|
||||
|
26
src/core/hle/service/nvflinger/consumer_listener.h
Normal file
26
src/core/hle/service/nvflinger/consumer_listener.h
Normal file
@ -0,0 +1,26 @@
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||
// Copyright 2021 yuzu Emulator Project
|
||||
// Copyright 2014 The Android Open Source Project
|
||||
// Parts of this implementation were base on:
|
||||
// https://cs.android.com/android/platform/superproject/+/android-5.1.1_r38:frameworks/native/include/gui/IConsumerListener.h
|
||||
|
||||
#pragma once
|
||||
|
||||
namespace android {
|
||||
|
||||
class BufferItem;
|
||||
|
||||
/// ConsumerListener is the interface through which the BufferQueue notifies the consumer of events
|
||||
/// that the consumer may wish to react to.
|
||||
class IConsumerListener {
|
||||
public:
|
||||
IConsumerListener() = default;
|
||||
virtual ~IConsumerListener() = default;
|
||||
|
||||
virtual void OnFrameAvailable(const BufferItem& item) = 0;
|
||||
virtual void OnFrameReplaced(const BufferItem& item) = 0;
|
||||
virtual void OnBuffersReleased() = 0;
|
||||
virtual void OnSidebandStreamChanged() = 0;
|
||||
};
|
||||
|
||||
}; // namespace android
|
Loading…
Reference in New Issue
Block a user