Skip to content

Commit 625eb01

Browse files
sm1021.shinHung-ying Tyan
authored andcommitted
Add default maxBufferCount in GraphicBufferProducer
Some modules that inherit and use IGraphicBufferProducer don't set maxBufferCount. As a result, the maxBufferCount value that has been queried in libvulkan is 0, and the creation of swapchain fails. Therefore, the default value (64) is set to maxBufferCount. Test: build, Mcts Bug: 376142095 Bug: 377778846 Change-Id: Ie5c5f747ecd6c15ffae80cc32b9f5a90b1a44df3 Merged-In: Ie5c5f747ecd6c15ffae80cc32b9f5a90b1a44df3 Signed-off-by: sm1021.shin <sm1021.shin@samsung.com> (cherry picked from commit ec1f230)
1 parent e4c3e22 commit 625eb01

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

libs/gui/include/gui/IGraphicBufferProducer.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ class IGraphicBufferProducer : public RefBase {
403403
uint64_t nextFrameNumber{0};
404404
FrameEventHistoryDelta frameTimestamps;
405405
bool bufferReplaced{false};
406-
int maxBufferCount{0};
406+
int maxBufferCount{BufferQueueDefs::NUM_BUFFER_SLOTS};
407407
status_t result{NO_ERROR};
408408
};
409409

0 commit comments

Comments
 (0)