From: Seungho, Baek Date: Tue, 12 Nov 2019 11:15:20 +0000 (+0900) Subject: Remove FrameBufferStateCache initialization function. X-Git-Tag: dali_1.4.52~3^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6c2076132a247ef421b2972daeafe8f204896ae5;p=platform%2Fcore%2Fuifw%2Fdali-core.git Remove FrameBufferStateCache initialization function. - Remove GetInitialFrameBufferState function. - Set default state as 0u Change-Id: I3b0d13eed8f26b68ecd9c980c58ca5851631397b Signed-off-by: Seungho, Baek --- diff --git a/dali/internal/render/gl-resources/frame-buffer-state-cache.cpp b/dali/internal/render/gl-resources/frame-buffer-state-cache.cpp index 0ba565f..40fdac1 100644 --- a/dali/internal/render/gl-resources/frame-buffer-state-cache.cpp +++ b/dali/internal/render/gl-resources/frame-buffer-state-cache.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015 Samsung Electronics Co., Ltd. + * Copyright (c) 2019 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -25,6 +25,13 @@ namespace Dali { +namespace +{ + +const uint32_t INITIAL_FRAMEBUFFER_STATE = 0u; + +} + namespace Internal { @@ -120,11 +127,11 @@ void FrameBufferStateCache::FrameBuffersCreated( GLsizei count, const GLuint* co { DALI_LOG_ERROR("FrameBuffer already exists%d \n", id ); // reset its state - state->mState = GetInitialFrameBufferState(); + state->mState = INITIAL_FRAMEBUFFER_STATE; continue; } - FrameBufferState newFrameBuffer( frameBuffers[i], GetInitialFrameBufferState() ); + FrameBufferState newFrameBuffer( frameBuffers[i] ); mFrameBufferStates.PushBack( newFrameBuffer ); } } @@ -213,12 +220,6 @@ void FrameBufferStateCache::DeleteFrameBuffer( GLuint frameBufferId ) DALI_LOG_ERROR("FrameBuffer not found %d \n", frameBufferId); } -unsigned int FrameBufferStateCache::GetInitialFrameBufferState() -{ - return COLOR_BUFFER_CLEAN | DEPTH_BUFFER_CLEAN | STENCIL_BUFFER_CLEAN; -} - - } // namespace Internal } // namespace Dali diff --git a/dali/internal/render/gl-resources/frame-buffer-state-cache.h b/dali/internal/render/gl-resources/frame-buffer-state-cache.h index fc04b08..9ffec1b 100644 --- a/dali/internal/render/gl-resources/frame-buffer-state-cache.h +++ b/dali/internal/render/gl-resources/frame-buffer-state-cache.h @@ -111,9 +111,9 @@ private: /** * Constructor */ - FrameBufferState( GLuint id, unsigned int state) + FrameBufferState( GLuint id ) :mId( id ), - mState( state ) + mState( 0 ) { } GLuint mId; ///< Frame buffer id @@ -142,12 +142,6 @@ private: */ void DeleteFrameBuffer( GLuint frameBufferId ); - /** - * @brief Get the default state of a frame buffer, before it's used - * @return initial state - */ - unsigned int GetInitialFrameBufferState(); - FrameBufferStateCache( const FrameBufferStateCache& ); ///< undefined copy constructor FrameBufferStateCache& operator=( const FrameBufferStateCache& ); ///< undefined assignment operator