X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-core.git;a=blobdiff_plain;f=dali%2Finternal%2Frender%2Frenderers%2Frender-frame-buffer.cpp;fp=dali%2Finternal%2Frender%2Frenderers%2Frender-texture-frame-buffer.cpp;h=44c00b022819a757f94fe87c06415236e8768f03;hp=24a17f416d791c97bd013f9392f32460402d17a0;hb=79881246746f65474b24ea4fe14151ccef8df3f4;hpb=2fa249687dba04074502ee8b22fb738da437f5cd diff --git a/dali/internal/render/renderers/render-texture-frame-buffer.cpp b/dali/internal/render/renderers/render-frame-buffer.cpp similarity index 81% rename from dali/internal/render/renderers/render-texture-frame-buffer.cpp rename to dali/internal/render/renderers/render-frame-buffer.cpp index 24a17f4..44c00b0 100644 --- a/dali/internal/render/renderers/render-texture-frame-buffer.cpp +++ b/dali/internal/render/renderers/render-frame-buffer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019 Samsung Electronics Co., Ltd. + * Copyright (c) 2020 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. @@ -15,7 +15,7 @@ */ // CLASS HEADER -#include +#include // INTERNAL INCLUDES #include @@ -41,9 +41,8 @@ const GLenum COLOR_ATTACHMENTS[] = }; } -TextureFrameBuffer::TextureFrameBuffer( uint32_t width, uint32_t height, Mask attachments ) -: FrameBuffer(), - mId( 0u ), +FrameBuffer::FrameBuffer( uint32_t width, uint32_t height, Mask attachments ) +: mId( 0u ), mTextureId{ 0u }, mDepthBuffer( attachments & Dali::FrameBuffer::Attachment::DEPTH ), mStencilBuffer( attachments & Dali::FrameBuffer::Attachment::STENCIL ), @@ -53,10 +52,11 @@ TextureFrameBuffer::TextureFrameBuffer( uint32_t width, uint32_t height, Mask at { } -TextureFrameBuffer::~TextureFrameBuffer() -{} +FrameBuffer::~FrameBuffer() +{ +} -void TextureFrameBuffer::Destroy( Context& context ) +void FrameBuffer::Destroy( Context& context ) { if( mId ) { @@ -64,12 +64,12 @@ void TextureFrameBuffer::Destroy( Context& context ) } } -void TextureFrameBuffer::GlContextDestroyed() +void FrameBuffer::GlContextDestroyed() { mId = 0u; } -void TextureFrameBuffer::Initialize(Context& context) +void FrameBuffer::Initialize(Context& context) { context.GenFramebuffers( 1, &mId ); context.BindFramebuffer( GL_FRAMEBUFFER, mId ); @@ -95,7 +95,7 @@ void TextureFrameBuffer::Initialize(Context& context) context.BindFramebuffer( GL_FRAMEBUFFER, 0 ); } -void TextureFrameBuffer::AttachColorTexture( Context& context, Render::Texture* texture, uint32_t mipmapLevel, uint32_t layer ) +void FrameBuffer::AttachColorTexture( Context& context, Render::Texture* texture, uint32_t mipmapLevel, uint32_t layer ) { context.BindFramebuffer( GL_FRAMEBUFFER, mId ); @@ -120,17 +120,17 @@ void TextureFrameBuffer::AttachColorTexture( Context& context, Render::Texture* context.BindFramebuffer( GL_FRAMEBUFFER, 0 ); } -void TextureFrameBuffer::Bind( Context& context ) +void FrameBuffer::Bind( Context& context ) { context.BindFramebuffer( GL_FRAMEBUFFER, mId ); } -uint32_t TextureFrameBuffer::GetWidth() const +uint32_t FrameBuffer::GetWidth() const { return mWidth; } -uint32_t TextureFrameBuffer::GetHeight() const +uint32_t FrameBuffer::GetHeight() const { return mHeight; }