projects
/
platform
/
core
/
uifw
/
dali-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove RenderSurface from Core
[platform/core/uifw/dali-core.git]
/
dali
/
internal
/
event
/
rendering
/
frame-buffer-impl.h
diff --git
a/dali/internal/event/rendering/frame-buffer-impl.h
b/dali/internal/event/rendering/frame-buffer-impl.h
index
f15b4bd
..
9913b4d
100644
(file)
--- a/
dali/internal/event/rendering/frame-buffer-impl.h
+++ b/
dali/internal/event/rendering/frame-buffer-impl.h
@@
-2,7
+2,7
@@
#define DALI_INTERNAL_FRAME_BUFFER_H
/*
#define DALI_INTERNAL_FRAME_BUFFER_H
/*
- * Copyright (c) 20
16
Samsung Electronics Co., Ltd.
+ * Copyright (c) 20
20
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.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@
-23,11
+23,14
@@
#include <dali/public-api/common/intrusive-ptr.h> // Dali::IntrusivePtr
#include <dali/public-api/object/base-object.h>
#include <dali/public-api/rendering/frame-buffer.h>
#include <dali/public-api/common/intrusive-ptr.h> // Dali::IntrusivePtr
#include <dali/public-api/object/base-object.h>
#include <dali/public-api/rendering/frame-buffer.h>
+#include <dali/devel-api/rendering/frame-buffer-devel.h>
#include <dali/internal/event/common/event-thread-services.h>
#include <dali/internal/event/rendering/texture-impl.h>
namespace Dali
{
#include <dali/internal/event/common/event-thread-services.h>
#include <dali/internal/event/rendering/texture-impl.h>
namespace Dali
{
+using Mask = Dali::FrameBuffer::Attachment::Mask;
+
namespace Internal
{
namespace Render
namespace Internal
{
namespace Render
@@
-42,17
+45,22
@@
class FrameBuffer : public BaseObject
{
public:
{
public:
-
typedef Dali::FrameBuffer::Format Format
;
+
using Mask = Dali::FrameBuffer::Attachment::Mask
;
/**
* @brief Create a new FrameBuffer
*
/**
* @brief Create a new FrameBuffer
*
- * @param[in] width The width of the FrameBuffer
- * @param[in] height The height of the FrameBuffer
- * @param[in]
format The format of the FrameBuffer
+ * @param[in] width
The width of the FrameBuffer
+ * @param[in] height
The height of the FrameBuffer
+ * @param[in]
attachments The attachments comprising the format of the FrameBuffer (bit-mask)
* @return A smart-pointer to the newly allocated Texture.
*/
* @return A smart-pointer to the newly allocated Texture.
*/
- static FrameBufferPtr New( unsigned int width, unsigned int height, Format format );
+ static FrameBufferPtr New( uint32_t width, uint32_t height, Mask attachments );
+
+ /**
+ * A reference counted object may only be deleted by calling Unreference()
+ */
+ virtual ~FrameBuffer();
/**
* @brief Get the FrameBuffer render object
/**
* @brief Get the FrameBuffer render object
@@
-64,22
+72,29
@@
public:
/**
* @copydoc Dali::FrameBuffer::AttachColorTexture()
*/
/**
* @copydoc Dali::FrameBuffer::AttachColorTexture()
*/
- void AttachColorTexture(
NewTexturePtr texture, unsigned int mipmapLevel, unsigned in
t layer );
+ void AttachColorTexture(
TexturePtr texture, uint32_t mipmapLevel, uint32_
t layer );
/**
* @copydoc Dali::FrameBuffer::GetColorTexture()
*/
/**
* @copydoc Dali::FrameBuffer::GetColorTexture()
*/
- NewTexture* GetColorTexture();
+ Texture* GetColorTexture(uint8_t index) const;
+
+ /**
+ * @brief Sets the frame buffer size.
+ * @param[in] width The width size
+ * @param[in] height The height size
+ */
+ void SetSize( uint32_t width, uint32_t height );
private: // implementation
/**
* Constructor
private: // implementation
/**
* Constructor
- * @param[in] width The width of the FrameBuffer
- * @param[in] height The height of the FrameBuffer
- * @param[in]
format The format of the FrameBuffer
+ * @param[in] width
The width of the FrameBuffer
+ * @param[in] height
The height of the FrameBuffer
+ * @param[in]
attachments The attachments comprising the format of the FrameBuffer (bit-mask)
*/
*/
- FrameBuffer( u
nsigned int width, unsigned int height, Format format
);
+ FrameBuffer( u
int32_t width, uint32_t height, Mask attachments
);
/**
* Second stage initialization of the Texture
/**
* Second stage initialization of the Texture
@@
-88,25
+103,22
@@
private: // implementation
protected:
protected:
- /**
- * A reference counted object may only be deleted by calling Unreference()
- */
- virtual ~FrameBuffer();
-
private: // unimplemented methods
private: // unimplemented methods
- FrameBuffer( const FrameBuffer& );
- FrameBuffer& operator=( const FrameBuffer& );
-private: // data
+ FrameBuffer() = delete;
+ FrameBuffer( const FrameBuffer& ) = delete;
+ FrameBuffer& operator=( const FrameBuffer& ) = delete;
- Internal::EventThreadServices& mEventThreadServices; ///<Used to send messages to the render thread via update thread
- Internal::Render::FrameBuffer* mRenderObject; ///<The Render::Texture associated to this texture
+private: // data
- NewTexturePtr mColor;
- unsigned int mWidth;
- unsigned int mHeight;
- Format mFormat;
+ Internal::EventThreadServices& mEventThreadServices; ///< Used to send messages to the render thread via update thread
+ Internal::Render::FrameBuffer* mRenderObject; ///< The Render::Texture associated to this texture
+ TexturePtr mColor[ Dali::DevelFrameBuffer::MAX_COLOR_ATTACHMENTS ];
+ uint32_t mWidth;
+ uint32_t mHeight;
+ Mask mAttachments; ///< Bit-mask of type FrameBuffer::Attachment::Mask
+ uint8_t mColorAttachmentCount;
};
} // namespace Internal
};
} // namespace Internal