/*
-- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
/*
-- * Copyright (c) 2017 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
/*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
- * Copyright (c) 2016 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.
/*
-- * Copyright (c) 2014 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.
/*
-- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
/*
-- * Copyright (c) 2017 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.
/*
-- * Copyright (c) 2014 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.
/*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2016 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
/*
-- * Copyright (c) 2018 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.
#define DALI_ACTOR_DEVEL_H
/*
-- * Copyright (c) 2018 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.
#define DALI_RENDERER_DEVEL_H
/*
-- * Copyright (c) 2018 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.
#define DALI_ENUM_HELPER_H
/*
-- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
#define __DALI_INTEGRATION_KEY_EVENT_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define DALI_INTERNAL_TYPE_ABSTRACTION_ENUMS_H
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define DALI_INTERNAL_ACTOR_H
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define DALI_INTERNAL_CAMERA_ACTOR_H
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_CUSTOM_ACTOR_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_ANIMATOR_CONNECTOR_BASE_H__
/*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_ANIMATOR_CONNECTOR_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_CONSTRAINER_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_ACTIVE_CONSTRAINT_BASE_H__
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_ACTIVE_CONSTRAINT_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_PATH_H__
/*
-- * Copyright (c) 2018 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.
#define __DALI_PROPERTY_CONSTRAINT_H__
/*
-- * Copyright (c) 2018 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.
#define __DALI_PROPERTY_INPUT_ACCESSOR_H__
/*
- * Copyright (c) 2016 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_OBJECT_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_PROPERTY_METADATA_H__
/*
-- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_TYPE_INFO_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_TYPE_REGISTRY_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_GESTURE_DETECTOR_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_GESTURE_EVENT_PROCESSOR_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define DALI_INTERNAL_HIT_TEST_ALGORITHM_H
/*
- * Copyright (c) 2016 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_HOVER_EVENT_PROCESSOR_H__
/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
#define __DALI_INTERNAL_KEY_EVENT_H__
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_LONG_PRESS_GESTURE_EVENT_PROCESSOR_H__
/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_PAN_GESTURE_DETECTOR_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_PAN_GESTURE_EVENT_PROCESSOR_H__
/*
-- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_PINCH_GESTURE_EVENT_PROCESSOR_H__
/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_TOUCH_EVENT_PROCESSOR_H__
/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2016 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * 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.
/*
-- * Copyright (c) 2018 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.
renderFrameBufferPtr = mFrameBuffer->GetRenderObject();
}
- SetFrameBufferMessage( GetEventThreadServices(), *mSceneObject, renderFrameBufferPtr );
+ SetFrameBufferMessage( GetEventThreadServices(), GetRenderTaskSceneObject(), renderFrameBufferPtr );
+
+ if( frameBuffer != nullptr &&
+ EqualsZero( mViewportSize.x ) &&
+ EqualsZero( mViewportSize.y ) )
+ {
+ // No viewport size has been set. Change it to the size of the framebuffer
+ SetViewportSize( Vector2( float(frameBuffer->GetWidth()), float(frameBuffer->GetHeight()) ));
+ }
}
FrameBuffer* RenderTask::GetFrameBuffer() const
#define __DALI_INTERNAL_RENDER_TASK_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_RENDER_TASK_LIST_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
void FrameBuffer::Initialize()
{
- mRenderObject = new Render::FrameBuffer( mWidth, mHeight, mAttachments );
- AddFrameBuffer( mEventThreadServices.GetUpdateManager(), *mRenderObject );
+ mRenderObject = new SceneGraph::FrameBuffer( mWidth, mHeight, mAttachments );
+ OwnerPointer< SceneGraph::FrameBuffer > transferOwnership( mRenderObject );
+ AddFrameBufferMessage( mEventThreadServices.GetUpdateManager(), transferOwnership );
}
- void FrameBuffer::AttachColorTexture( TexturePtr texture, unsigned int mipmapLevel, unsigned int layer )
+ void FrameBuffer::AttachColorTexture( TexturePtr texture, uint32_t mipmapLevel, uint32_t layer )
{
if( ( texture->GetWidth() / ( 1u << mipmapLevel ) == mWidth ) &&
( texture->GetHeight() / ( 1u << mipmapLevel ) == mHeight ) )
#define DALI_INTERNAL_FRAME_BUFFER_H
/*
-- * Copyright (c) 2018 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.
private: // data
- 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
+ EventThreadServices& mEventThreadServices; ///< Used to send messages to the render thread via update thread
+ SceneGraph::FrameBuffer* mRenderObject; ///< The Render::Framebuffer associated with this framebuffer
TexturePtr mColor;
- unsigned int mWidth;
- unsigned int mHeight;
- unsigned int mAttachments; ///< Bit-mask of type FrameBuffer::Attachment::Mask
+ uint32_t mWidth;
+ uint32_t mHeight;
+ Mask mAttachments; ///< Bit-mask of type FrameBuffer::Attachment::Mask
-
};
} // namespace Internal
/*
-- * Copyright (c) 2018 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.
return geometry;
}
- std::size_t Geometry::AddVertexBuffer( PropertyBuffer& vertexBuffer )
+ uint32_t Geometry::AddVertexBuffer( PropertyBuffer& vertexBuffer )
{
mVertexBuffers.push_back( &vertexBuffer );
- SceneGraph::AttachVertexBufferMessage( mEventThreadServices.GetUpdateManager(), *mRenderObject, *vertexBuffer.GetRenderObject() );
+ SceneGraph::AttachVertexBufferMessage( mEventThreadServices, *mRenderObject, *vertexBuffer.GetRenderObject() );
- return mVertexBuffers.size() - 1u;
+ return static_cast<uint32_t>( mVertexBuffers.size() - 1u );
}
- std::size_t Geometry::GetNumberOfVertexBuffers() const
+ uint32_t Geometry::GetNumberOfVertexBuffers() const
{
- return mVertexBuffers.size();
+ return static_cast<uint32_t>( mVertexBuffers.size() );
}
- void Geometry::RemoveVertexBuffer( std::size_t index )
+ void Geometry::RemoveVertexBuffer( uint32_t index )
{
- const Render::PropertyBuffer& renderPropertyBuffer = static_cast<const Render::PropertyBuffer&>( *(mVertexBuffers[index]->GetRenderObject()) );
- SceneGraph::RemoveVertexBufferMessage( mEventThreadServices.GetUpdateManager(), *mRenderObject, renderPropertyBuffer );
+ const SceneGraph::PropertyBuffer& renderPropertyBuffer = static_cast<const SceneGraph::PropertyBuffer&>( *(mVertexBuffers[index]->GetRenderObject()) );
+ SceneGraph::RemoveVertexBufferMessage( mEventThreadServices, *mRenderObject, renderPropertyBuffer );
mVertexBuffers.erase( mVertexBuffers.begin() + index );
}
#define DALI_INTERNAL_GEOMETRY_H
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2016 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.
/*
-- * Copyright (c) 2018 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.
// INTERNAL INCLUDES
#include <dali/devel-api/scripting/scripting.h>
- #include <dali/devel-api/rendering/renderer-devel.h>
#include <dali/public-api/object/type-registry.h>
- #include <dali/internal/event/common/object-impl-helper.h> // Dali::Internal::ObjectHelper
+#include <dali/integration-api/debug.h>
#include <dali/internal/event/common/property-helper.h> // DALI_PROPERTY_TABLE_BEGIN, DALI_PROPERTY, DALI_PROPERTY_TABLE_END
#include <dali/internal/event/common/property-input-impl.h>
-#include <dali/internal/render/renderers/render-geometry.h>
+#include <dali/internal/update/rendering/stencil-parameters.h>
+#include <dali/internal/update/rendering/scene-graph-geometry.h>
#include <dali/internal/update/manager/update-manager.h>
#include <dali/internal/update/rendering/scene-graph-renderer.h>
{
mGeometry = &geometry;
- const Render::Geometry* geometrySceneObject = geometry.GetRenderObject();
+ const SceneGraph::Geometry* geometrySceneObject = geometry.GetRenderObject();
- SetGeometryMessage( GetEventThreadServices(), *mSceneObject, *geometrySceneObject );
+ SetGeometryMessage( GetEventThreadServices(), GetRendererSceneObject(), *geometrySceneObject );
}
- Geometry* Renderer::GetGeometry() const
+ GeometryPtr Renderer::GetGeometry() const
{
- return mGeometry.Get();
+ return mGeometry;
}
void Renderer::SetTextures( TextureSet& textureSet )
{
mBlendMode = mode;
- SetBlendModeMessage( GetEventThreadServices(), *mSceneObject, mBlendMode );
+ DALI_LOG_INFO( gLogFilter, Debug::Verbose, "Renderer::SetBlendMode( %s )\n", Scripting::GetEnumerationName<BlendMode::Type>( mBlendMode, BLEND_MODE_TABLE, BLEND_MODE_TABLE_COUNT ) );
+
+ SetBlendModeMessage( GetEventThreadServices(), GetRendererSceneObject(), mBlendMode );
}
}
}
case Dali::Renderer::Property::STENCIL_FUNCTION:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.stencilFunction;
break;
}
case Dali::Renderer::Property::STENCIL_FUNCTION_MASK:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.stencilFunctionMask;
break;
}
case Dali::Renderer::Property::STENCIL_FUNCTION_REFERENCE:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.stencilFunctionReference;
break;
}
case Dali::Renderer::Property::STENCIL_MASK:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.stencilMask;
break;
}
case Dali::Renderer::Property::RENDER_MODE:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.renderMode;
break;
}
case Dali::Renderer::Property::STENCIL_OPERATION_ON_FAIL:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.stencilOperationOnFail;
break;
}
case Dali::Renderer::Property::STENCIL_OPERATION_ON_Z_FAIL:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.stencilOperationOnZFail;
break;
}
case Dali::Renderer::Property::STENCIL_OPERATION_ON_Z_PASS:
{
- SceneGraph::StencilParameters stencilParameters = mSceneObject->GetStencilParameters();
- Render::Renderer::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
++ SceneGraph::StencilParameters stencilParameters = sceneObject.GetStencilParameters();
value = stencilParameters.stencilOperationOnZPass;
break;
}
#define DALI_INTERNAL_RENDERER_H
/*
-- * Copyright (c) 2018 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.
*/
// INTERNAL INCLUDES
-#include <dali/public-api/common/dali-common.h> // DALI_ASSERT_ALWAYS
-#include <dali/public-api/common/intrusive-ptr.h> // Dali::IntrusivePtr
-#include <dali/public-api/rendering/renderer.h> // Dali::Renderer
+#include <dali/public-api/common/dali-common.h>
+#include <dali/public-api/common/intrusive-ptr.h>
+#include <dali/public-api/rendering/renderer.h>
+ #include <dali/devel-api/rendering/renderer-devel.h>
#include <dali/internal/common/blending-options.h>
-#include <dali/internal/event/common/object-connector.h> // Dali::Internal::ObjectConnector
-#include <dali/internal/event/common/object-impl.h> // Dali::Internal::Object
-#include <dali/internal/event/rendering/texture-set-impl.h> // Dali::Internal::TextureSet
-#include <dali/internal/event/rendering/geometry-impl.h> // Dali::Internal::Geometry
-#include <dali/internal/render/renderers/render-renderer.h> // Dali::Render::Renderer::StencilParameters
+#include <dali/internal/event/common/object-connector.h>
+#include <dali/internal/event/common/object-impl.h>
+#include <dali/internal/event/rendering/texture-set-impl.h>
+#include <dali/internal/event/rendering/geometry-impl.h>
+#include <dali/internal/update/rendering/stencil-parameters.h>
namespace Dali
{
Renderer& operator=( const Renderer& );
private: // data
- SceneGraph::Renderer* mSceneObject;
- GeometryPtr mGeometry; ///< Connector that holds the geometry used by this renderer
- TextureSetPtr mTextureSet; ///< Connector that holds the texture set used by this renderer
- ShaderPtr mShader; ///< Connector that holds the shader used by this renderer
- int mDepthIndex;
+ GeometryPtr mGeometry; ///< Intrusive pointer to the geometry used by this renderer
+ TextureSetPtr mTextureSet; ///< Intrusive pointer to the texture set used by this renderer
+ ShaderPtr mShader; ///< Intrusive pointer to the shader used by this renderer
+
+ int32_t mDepthIndex;
- uint32_t mIndexedDrawFirstElement; ///< Offset of first element to draw from bound index buffer
- uint32_t mIndexedDrawElementCount; ///< Number of elements to draw
+ uint32_t mIndexedDrawFirstElement; ///< Offset of first element to draw from bound index buffer
+ uint32_t mIndexedDrawElementCount; ///< Number of elements to draw
- Render::Renderer::StencilParameters mStencilParameters; ///< Struct containing all stencil related options
+ SceneGraph::StencilParameters mStencilParameters; ///< Struct containing all stencil related options
- BlendingOptions mBlendingOptions; ///< Local copy of blending options bitmask
-
- float mOpacity; ///< Local copy of the opacity
- DepthFunction::Type mDepthFunction:4; ///< Local copy of the depth function
- FaceCullingMode::Type mFaceCullingMode:3; ///< Local copy of the mode of face culling
- BlendMode::Type mBlendMode:3; ///< Local copy of the mode of blending
- DepthWriteMode::Type mDepthWriteMode:3; ///< Local copy of the depth write mode
- DepthTestMode::Type mDepthTestMode:3; ///< Local copy of the depth test mode
- bool mPremultipledAlphaEnabled:1; ///< Flag indicating whether the Pre-multiplied Alpha Blending is required
+ BlendingOptions mBlendingOptions; ///< Local copy of blending options bitmask
+
+ float mOpacity; ///< Local copy of the opacity
+ DepthFunction::Type mDepthFunction:4; ///< Local copy of the depth function
+ FaceCullingMode::Type mFaceCullingMode:3; ///< Local copy of the mode of face culling
+ BlendMode::Type mBlendMode:3; ///< Local copy of the mode of blending
+ DepthWriteMode::Type mDepthWriteMode:3; ///< Local copy of the depth write mode
+ DepthTestMode::Type mDepthTestMode:3; ///< Local copy of the depth test mode
+ DevelRenderer::Rendering::Type mRenderingBehavior:2; ///< The rendering behavior
+ bool mPremultipledAlphaEnabled:1; ///< Flag indicating whether the Pre-multiplied Alpha Blending is required
};
} // namespace Internal
/*
-- * Copyright (c) 2018 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.
// INTERNAL INCLUDES
#include <dali/public-api/object/type-registry.h>
#include <dali/devel-api/scripting/scripting.h>
- #include <dali/internal/event/common/object-impl-helper.h> // Dali::Internal::ObjectHelper
+#include <dali/devel-api/rendering/shader-devel.h>
#include <dali/internal/event/common/property-helper.h> // DALI_PROPERTY_TABLE_BEGIN, DALI_PROPERTY, DALI_PROPERTY_TABLE_END
#include <dali/internal/event/common/thread-local-storage.h>
#include <dali/internal/event/effects/shader-factory.h>
const std::string& fragmentShader,
Dali::Shader::Hint::Value hints )
{
- ShaderPtr shader( new Shader() );
- shader->Initialize( vertexShader, fragmentShader, hints );
+ // create scene object first so it's guaranteed to exist for the event side
+ auto sceneObject = new SceneGraph::Shader( hints );
+ OwnerPointer< SceneGraph::Shader > transferOwnership( sceneObject );
+ // pass the pointer to base for message passing
+ ShaderPtr shader( new Shader( sceneObject ) );
+ // transfer scene object ownership to update manager
+ auto&& services = shader->GetEventThreadServices();
+ SceneGraph::UpdateManager& updateManager = services.GetUpdateManager();
+ AddShaderMessage( updateManager, transferOwnership );
+
+ services.RegisterObject( shader.Get() );
+ shader->SetShader( vertexShader, fragmentShader, hints );
+ return shader;
+}
- ShaderPtr shader( new Shader() );
- shader->Initialize(vertexShader, fragmentShader, language, specializationConstants, hints );
- return shader;
- }
+ShaderPtr Shader::New( std::vector<char>& vertexShader,
+ std::vector<char>& fragmentShader,
+ DevelShader::ShaderLanguage language,
+ const Property::Map& specializationConstants,
+ Dali::Shader::Hint::Value hints )
+{
- const SceneGraph::Shader* Shader::GetShaderSceneObject() const
- {
- return mSceneObject;
++ // create scene object first so it's guaranteed to exist for the event side
++ auto sceneObject = new SceneGraph::Shader( hints );
++ OwnerPointer< SceneGraph::Shader > transferOwnership( sceneObject );
++ // pass the pointer to base for message passing
++ ShaderPtr shader( new Shader( sceneObject ) );
++ // transfer scene object ownership to update manager
++ auto&& services = shader->GetEventThreadServices();
++ SceneGraph::UpdateManager& updateManager = services.GetUpdateManager();
++ AddShaderMessage( updateManager, transferOwnership );
+
++ services.RegisterObject( shader.Get() );
++ shader->SetShader(vertexShader, fragmentShader, language, specializationConstants, hints );
+ return shader;
}
- SceneGraph::Shader* Shader::GetShaderSceneObject()
+ const SceneGraph::Shader& Shader::GetShaderSceneObject() const
{
- return mSceneObject;
+ return static_cast<const SceneGraph::Shader&>( GetSceneObject() );
}
- void Shader::SetDefaultProperty( Property::Index index,
- const Property::Value& propertyValue )
+ void Shader::SetDefaultProperty( Property::Index index, const Property::Value& propertyValue )
{
switch(index)
{
size_t shaderHash;
mShaderData = shaderFactory.Load( vertexSource, fragmentSource, hints, shaderHash );
-- // Add shader program to scene-object using a message to the UpdateManager
- SetShaderProgramMessage( eventThreadServices, *mSceneObject, mShaderData, (hints & Dali::Shader::Hint::MODIFIES_GEOMETRY) != 0x0 );
-
- eventThreadServices.RegisterObject( this );
+ EventThreadServices& eventThreadServices = GetEventThreadServices();
- SceneGraph::UpdateManager& updateManager = eventThreadServices.GetUpdateManager();
- SetShaderProgramMessage( updateManager, GetShaderSceneObject(), mShaderData, (hints & Dali::Shader::Hint::MODIFIES_GEOMETRY) != 0x0 );
++ SetShaderProgramMessage( eventThreadServices, *const_cast<SceneGraph::Shader*>(&GetShaderSceneObject()), mShaderData, (hints & Dali::Shader::Hint::MODIFIES_GEOMETRY) != 0x0 );
+}
+
- void Shader::Initialize( std::vector<char>& vertexShader,
- std::vector<char>& fragmentShader,
- DevelShader::ShaderLanguage language,
- const Property::Map& specializationConstants,
- Dali::Shader::Hint::Value hints )
++
++void Shader::SetShader( std::vector<char>& vertexShader,
++ std::vector<char>& fragmentShader,
++ DevelShader::ShaderLanguage language,
++ const Property::Map& specializationConstants,
++ Dali::Shader::Hint::Value hints )
+{
+ EventThreadServices& eventThreadServices = GetEventThreadServices();
- SceneGraph::UpdateManager& updateManager = eventThreadServices.GetUpdateManager();
- mSceneObject = new SceneGraph::Shader( hints );
-
- OwnerPointer< SceneGraph::Shader > transferOwnership( mSceneObject );
- AddShaderMessage( updateManager, transferOwnership );
+
+ mShaderData = new ShaderData( vertexShader, fragmentShader, hints );
++ SetShaderProgramMessage( eventThreadServices, *const_cast<SceneGraph::Shader*>(&GetShaderSceneObject()), mShaderData, (hints & Dali::Shader::Hint::MODIFIES_GEOMETRY) != 0x0 );
+
- // Add shader program to scene-object using a message to the UpdateManager
- bool shaderModifiesGeometry = (hints & Dali::Shader::Hint::MODIFIES_GEOMETRY) != 0x00;
- SetShaderProgramMessage( eventThreadServices, *mSceneObject, mShaderData, shaderModifiesGeometry );
-
- eventThreadServices.RegisterObject( this );
}
Shader::~Shader()
#define DALI_INTERNAL_SHADER_H
/*
-- * Copyright (c) 2018 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.
const std::string& fragmentShader,
Dali::Shader::Hint::Value hints );
- /**
- * @brief Get the shader scene object
- *
- * @return the shader scene object
- */
- const SceneGraph::Shader* GetShaderSceneObject() const;
-
+ /**
+ * Create a new shader object
+ *
+ * @param[in] vertexShader
+ * @param[in] fragmentShader
+ * @param[in] language
+ * @param[in] specializationConstants
+ * @param[in] hints Hints to define the geometry of the rendered object
+ * @return
+ */
+ static ShaderPtr New( std::vector<char>& vertexShader,
+ std::vector<char>& fragmentShader,
+ DevelShader::ShaderLanguage language,
+ const Property::Map& specializationConstants,
+ Dali::Shader::Hint::Value hints );
+
/**
* Retrieve the scene-graph shader added by this object.
* @return A pointer to the shader.
/**
* Second stage initialization
*/
- void Initialize( const std::string& vertexShader, const std::string& fragmentShader, Dali::Shader::Hint::Value hints );
+ void SetShader( const std::string& vertexShader, const std::string& fragmentShader, Dali::Shader::Hint::Value hints );
- void Initialize( std::vector<char>& vertexShader,
+ /**
+ *
+ * Second stage initialization, devel initialiser
+ *
+ *
+ * @param vertexShader
+ * @param fragmentShader
+ * @param language
+ * @param specializationConstants
+ * @param[in] hints Hints to define the geometry of the rendered object
+ */
++ void SetShader( std::vector<char>& vertexShader,
+ std::vector<char>& fragmentShader,
+ DevelShader::ShaderLanguage language,
+ const Property::Map& specializationConstants,
+ Dali::Shader::Hint::Value hints );
+
protected:
/**
* A reference counted object may only be deleted by calling Unreference()
#define __DALI_INTERNAL_SCENE_GRAPH_PROPERTY_ACCESSOR_H__
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_SCENE_GRAPH_PROPERTY_COMPONENT_ACCESSOR_H__
/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_SCENE_GRAPH_ANIMATION_H__
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_SCENE_GRAPH_ANIMATOR_H__
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_SCENE_GRAPH_CONSTRAINT_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#include <dali/internal/update/render-tasks/scene-graph-render-task.h>
#include <dali/internal/update/render-tasks/scene-graph-render-task-list.h>
#include <dali/internal/update/nodes/scene-graph-layer.h>
-#include <dali/internal/render/common/render-item.h>
-#include <dali/internal/render/common/render-tracker.h>
-#include <dali/internal/render/common/render-instruction.h>
-#include <dali/internal/render/common/render-instruction-container.h>
-#include <dali/internal/render/renderers/render-renderer.h>
+#include <dali/internal/update/rendering/render-item.h>
+#include <dali/internal/update/rendering/render-tracker.h>
+#include <dali/internal/update/rendering/render-instruction.h>
+#include <dali/internal/update/rendering/render-instruction-container.h>
++#include <dali/internal/update/rendering/scene-graph-renderer.h>
#include <dali/integration-api/debug.h>
#if defined(DEBUG_ENABLED)
#define DALI_INTERNAL_SCENE_GRAPH_RENDER_TASK_PROCESSOR_H
/*
-- * Copyright (c) 2017 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.
namespace
{
- /**
- * Helper to reset animate-able objects to base values
- * @param container to iterate over
- * @param updateBufferIndex to use
- */
- template< class T >
- inline void ResetToBaseValues( OwnerContainer<T*>& container, BufferIndex updateBufferIndex )
- {
- // Reset animatable properties to base values
- // use reference to avoid extra copies of the iterator
- for( auto&& iter : container )
- {
- iter->ResetToBaseValues( updateBufferIndex );
- }
- }
-
+#if defined(DEBUG_ENABLED)
+Debug::Filter* gLogFilter = Debug::Filter::New(Debug::NoLogging, false, "LOG_UPDATE" );
+#endif
+
/**
* Helper to Erase an object from OwnerContainer using discard queue
* @param container to remove from
//Process Touches & Gestures
const bool gestureUpdated = ProcessGestures( bufferIndex, lastVSyncTimeMilliseconds, nextVSyncTimeMilliseconds );
+ const bool resumed = mImpl->graphicsController.IsDrawOnResumeRequired();
- bool updateScene = // The scene-graph requires an update if..
- (mImpl->nodeDirtyFlags & RenderableUpdateFlags) || // ..nodes were dirty in previous frame OR
- IsAnimationRunning() || // ..at least one animation is running OR
- mImpl->messageQueue.IsSceneUpdateRequired() || // ..a message that modifies the scene graph node tree is queued OR
- gestureUpdated; // ..a gesture property was updated
+ bool updateScene = // The scene-graph requires an update if..
+ (mImpl->nodeDirtyFlags & RenderableUpdateFlags) || // ..nodes were dirty in previous frame OR
+ IsAnimationRunning() || // ..at least one animation is running OR
+ mImpl->messageQueue.IsSceneUpdateRequired() || // ..a message that modifies the scene graph node tree is queued OR
- gestureUpdated; // ..a gesture property was updated OR
++ gestureUpdated; // ..a gesture property was updated
-
- // Although the scene-graph may not require an update, we still need to synchronize double-buffered
- // values if the scene was updated in the previous frame.
+ bool keepRendererRendering = false;
+ // Although the scene-graph may not require an update, we still need to synchronize
+ // double-buffered values if the scene was updated in the previous frame.
if( updateScene || mImpl->previousUpdateScene )
{
//Reset properties from the previous update
// Check whether further updates are required
uint32_t keepUpdating = KeepUpdatingCheck( elapsedSeconds );
+ // we need new flag to rerun update on idle and execute potential idle code
+ if( updateScene )
+ {
+ keepUpdating |= KeepUpdating::DISCARD_RESOURCES;
+ }
+
++
+ if( keepRendererRendering )
+ {
+ keepUpdating |= KeepUpdating::STAGE_KEEP_RENDERING;
+ }
+
// tell the update manager that we're done so the queue can be given to event thread
mImpl->notificationManager.UpdateCompleted();
new (slot) LocalType( &manager, &UpdateManager::AddShader, shader );
}
- inline void RemoveShaderMessage( UpdateManager& manager, Shader& shader )
-// The render thread can safely change the Shader
+ inline void RemoveShaderMessage( UpdateManager& manager, const Shader* shader )
{
typedef MessageValue1< UpdateManager, Shader* > LocalType;
uint32_t* slot = manager.ReserveMessageSlot( sizeof( LocalType ) );
// Construct message in the message queue memory; note that delete should not be called on the return value
- new (slot) LocalType( &manager, &UpdateManager::RemoveShader, &shader );
+ new (slot) LocalType( &manager, &UpdateManager::RemoveShader, const_cast<Shader*>( shader ) );
}
-inline void SetShaderProgramMessage( UpdateManager& manager,
- const Shader& shader,
- Internal::ShaderDataPtr shaderData,
- bool modifiesGeometry )
-{
- typedef MessageValue3< UpdateManager, Shader*, Internal::ShaderDataPtr, bool > LocalType;
-
- // Reserve some memory inside the message queue
- uint32_t* slot = manager.ReserveMessageSlot( sizeof( LocalType ) );
-
- // Construct message in the message queue memory; note that delete should not be called on the return value
- new (slot) LocalType( &manager, &UpdateManager::SetShaderProgram, const_cast<Shader*>( &shader ), shaderData, modifiesGeometry );
-}
-
inline void SetBackgroundColorMessage( UpdateManager& manager, const Vector4& color )
{
typedef MessageValue1< UpdateManager, Vector4 > LocalType;
/*
-- * Copyright (c) 2018 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.
#define DALI_INTERNAL_SCENE_GRAPH_NODE_H
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_INTERNAL_UPDATE_MESSAGE_QUEUE_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
RenderTask::~RenderTask()
{
- // Remove exclusive flag from source node
- if( mExclusive )
+ if ( mSourceNode )
{
- if( mSourceNode && (this == mSourceNode->GetExclusiveRenderTask() ) )
+ mSourceNode->RemoveObserver( *this );
+ if( mExclusive )
{
- mSourceNode->SetExclusiveRenderTask( NULL );
+ mSourceNode->SetExclusiveRenderTask( nullptr );
}
}
- if( mRenderSyncTracker )
- {
- mRenderMessageDispatcher->RemoveRenderTracker( *mRenderSyncTracker );
- }
+ if ( mCameraNode )
+ {
+ mCameraNode->RemoveObserver( *this );
+ }
+ // @todo remove any hard sync object
}
-void RenderTask::Initialize( RenderMessageDispatcher& renderMessageDispatcher )
+void RenderTask::Initialize()
{
- mRenderMessageDispatcher = &renderMessageDispatcher;
}
void RenderTask::SetSourceNode( Node* node )
void RenderTask::SetCamera( Node* cameraNode, Camera* camera )
{
+ if ( mCameraNode )
+ {
+ mCameraNode->RemoveObserver( *this );
+ }
+
mCameraNode = cameraNode;
mCamera = camera;
+
+ if ( mCameraNode )
+ {
+ mCameraNode->AddObserver( *this );
+ }
+ SetActiveStatus();
}
-void RenderTask::SetFrameBuffer( Render::FrameBuffer* frameBuffer )
+void RenderTask::SetFrameBuffer( SceneGraph::FrameBuffer* frameBuffer )
{
mFrameBuffer = frameBuffer;
}
return mCamera->GetProjectionMatrix( bufferIndex );
}
-void RenderTask::PrepareRenderInstruction( RenderInstruction& instruction, BufferIndex updateBufferIndex )
+RenderInstruction& RenderTask::PrepareRenderInstruction( BufferIndex updateBufferIndex )
{
- DALI_ASSERT_DEBUG( NULL != mCamera );
+ DALI_ASSERT_DEBUG( nullptr != mCamera );
TASK_LOG(Debug::General);
Viewport viewport;
bool viewportSet = QueryViewport( updateBufferIndex, viewport );
- instruction.Reset( mCamera,
- GetFrameBuffer(),
+ mRenderInstruction[updateBufferIndex].Reset( mCamera,
+ GetFrameBuffer(),
- viewportSet ? &viewport : NULL,
- mClearEnabled ? &GetClearColor( updateBufferIndex ) : NULL );
+ viewportSet ? &viewport : nullptr,
+ mClearEnabled ? &GetClearColor( updateBufferIndex ) : nullptr );
if( mRequiresSync &&
mRefreshRate == Dali::RenderTask::REFRESH_ONCE )
: mViewportPosition( Vector2::ZERO),
mViewportSize( Vector2::ZERO),
mClearColor( Dali::RenderTask::DEFAULT_CLEAR_COLOR ),
- mRenderMessageDispatcher( nullptr ),
- mRenderSyncTracker( nullptr ),
+ //mRenderSyncTracker( NULL ),
- mSourceNode( NULL ),
- mCameraNode( NULL ),
- mCamera( NULL ),
+ mSourceNode( nullptr ),
+ mCameraNode( nullptr ),
+ mCamera( nullptr ),
mFrameBuffer(0),
+ mRefreshRate( Dali::RenderTask::DEFAULT_REFRESH_RATE ),
+ mFrameCounter( 0u ),
+ mRenderedOnceCounter( 0u ),
+ mState( (Dali::RenderTask::DEFAULT_REFRESH_RATE == Dali::RenderTask::REFRESH_ALWAYS)
+ ? RENDER_CONTINUOUSLY
+ : RENDER_ONCE_WAITING_FOR_RESOURCES ),
+ mRequiresSync( false ),
+ mActive( false ),
mWaitingToRender( false ),
mNotifyTrigger( false ),
mExclusive( Dali::RenderTask::DEFAULT_EXCLUSIVE ),
#define DALI_INTERNAL_SCENE_GRAPH_RENDER_TASK_H
/*
-- * Copyright (c) 2018 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.
*/
void SetSyncRequired( bool requiresSync );
+ RenderInstruction& GetRenderInstruction( BufferIndex updateBufferIndex )
+ {
+ return mRenderInstruction[updateBufferIndex];
+ }
+
+ private: // from PropertyOwner::Observer
+
+ /**
+ * @copydoc PropertyOwner::Observer::PropertyOwnerConnected( PropertyOwner& owner )
+ */
+ void PropertyOwnerConnected( PropertyOwner& owner );
+
+ /**
+ * @copydoc PropertyOwner::Observer::PropertyOwnerDisconnected( BufferIndex updateBufferIndex, PropertyOwner& owner )
+ */
+ void PropertyOwnerDisconnected( BufferIndex updateBufferIndex, PropertyOwner& owner );
+
+ /**
+ * @copydoc PropertyOwner::Observer::PropertyOwnerDestroyed( PropertyOwner& owner )
+ */
+ void PropertyOwnerDestroyed( PropertyOwner& owner );
+
private:
+ void SetActiveStatus();
+
/**
- * Protected constructor.
+ * Constructor.
*/
RenderTask();
Node* mSourceNode;
Node* mCameraNode;
SceneGraph::Camera* mCamera;
- Render::FrameBuffer* mFrameBuffer;
+ SceneGraph::FrameBuffer* mFrameBuffer;
+
+ RenderInstruction mRenderInstruction[2]; ///< Owned double buffered render instruction. (Double buffered because this owns render commands for the currently drawn frame)
- bool mWaitingToRender:1; ///< True when an render once to FBO is waiting
- bool mNotifyTrigger:1; ///< True if a render once render task has finished renderering
- bool mExclusive: 1; ///< Whether the render task has exclusive access to the source actor (node in the scene graph implementation).
- bool mClearEnabled: 1; ///< Whether previous results are cleared.
- bool mCullMode: 1; ///< Whether renderers should be frustum culled
+ uint32_t mRefreshRate; ///< REFRESH_ONCE, REFRESH_ALWAYS or render every N frames
+ uint32_t mFrameCounter; ///< counter for rendering every N frames
+ uint32_t mRenderedOnceCounter;///< Incremented whenever state changes to RENDERED_ONCE_AND_NOTIFIED
- State mState; ///< Render state.
- uint32_t mRefreshRate; ///< REFRESH_ONCE, REFRESH_ALWAYS or render every N frames
- uint32_t mFrameCounter; ///< counter for rendering every N frames
+ State mState; ///< Render state.
- uint32_t mRenderedOnceCounter; ///< Incremented whenever state changes to RENDERED_ONCE_AND_NOTIFIED
- bool mRequiresSync; ///< Whether sync is needed to track the render
+ bool mRequiresSync:1; ///< Whether sync is needed to track the render
+ bool mActive:1; ///< True when the task is active, i.e. has valid source and camera
+ bool mWaitingToRender:1;///< True when an render once to FBO is waiting
+ bool mNotifyTrigger:1; ///< True if a render once render task has finished renderering
+ bool mExclusive:1; ///< Whether the render task has exclusive access to the source actor (node in the scene graph).
+ bool mClearEnabled:1; ///< Whether previous results are cleared.
+ bool mCullMode:1; ///< Whether renderers should be frustum culled
};
// Messages for RenderTask
- inline void SetFrameBufferMessage( EventThreadServices& eventThreadServices, RenderTask& task, SceneGraph::FrameBuffer* frameBuffer )
-inline void SetFrameBufferMessage( EventThreadServices& eventThreadServices, const RenderTask& task, Render::FrameBuffer* frameBuffer )
++inline void SetFrameBufferMessage( EventThreadServices& eventThreadServices, const RenderTask& task, SceneGraph::FrameBuffer* frameBuffer )
{
- typedef MessageValue1< RenderTask, Render::FrameBuffer*> LocalType;
+ typedef MessageValue1< RenderTask, SceneGraph::FrameBuffer*> LocalType;
// Reserve some memory inside the message queue
uint32_t* slot = eventThreadServices.ReserveMessageSlot( sizeof( LocalType ) );
--- /dev/null
+/*
+ * 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.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+// CLASS HEADER
+#include <dali/internal/update/rendering/scene-graph-frame-buffer.h>
+
+// INTERNAL INCLUDES
+#include <dali/internal/update/rendering/scene-graph-texture.h>
+#include <dali/graphics-api/graphics-api-texture-details.h>
+#include <dali/graphics-api/graphics-api-framebuffer.h>
+#include <dali/graphics-api/graphics-api-framebuffer-factory.h>
+
+namespace Dali
+{
+namespace Internal
+{
+namespace SceneGraph
+{
+
+FrameBuffer::FrameBuffer( unsigned int width, unsigned int height, unsigned int attachments )
+: mGraphicsController( nullptr ),
+ mGraphicsFramebuffer( nullptr ),
+ mWidth( width ),
+ mHeight( height )
+{
+}
+
+FrameBuffer::~FrameBuffer() = default;
+
+void FrameBuffer::Initialize( Graphics::Controller& graphicsController )
+{
+ mGraphicsController = &graphicsController;
+ // Defer creation of framebuffer until a render instruction uses it
+}
+
+void FrameBuffer::AttachColorTexture( SceneGraph::Texture* texture, unsigned int mipmapLevel, unsigned int layer )
+{
+ mColorAttachment.texture = texture;
+ mColorAttachment.mipmapLevel = mipmapLevel;
+ mColorAttachment.layer = layer;
+}
+
+void FrameBuffer::AttachDepthStencilTexture( SceneGraph::Texture* texture,
+ Dali::FrameBuffer::Attachment::Mask format,
+ unsigned int mipmapLevel,
+ unsigned int layer )
+{
+ mDepthAttachment.texture = texture;
+ mDepthAttachment.format = format;
+ mDepthAttachment.mipmapLevel = mipmapLevel;
+ mDepthAttachment.layer = layer;
+}
+
+unsigned int FrameBuffer::GetWidth() const
+{
+ return mWidth;
+}
+
+unsigned int FrameBuffer::GetHeight() const
+{
+ return mHeight;
+}
+
+void FrameBuffer::PrepareFramebuffer()
+{
+ // @todo Check if the color attachments or depth attachments have changed since the graphics object was created
+ if( !mGraphicsFramebuffer )
+ {
+ auto& factory = mGraphicsController->GetFramebufferFactory();
+ factory.SetSize( Graphics::Extent2D{ mWidth, mHeight } );
+
+ /**
+ * If the framebuffer has a color attachment without a graphics object, create one
+ */
+ if( mColorAttachment.texture != nullptr )
+ {
+ auto graphicsTexture = mColorAttachment.texture->GetGfxObject();
+ //@todo check if the texture has the right creation flags - if it's already been uploaded, it
+ // needs the layout & usage changing appropriately.
+ if( !graphicsTexture )
+ {
+ mColorAttachment.texture->CreateTexture( Texture::Usage::COLOR_ATTACHMENT );
+ graphicsTexture = mColorAttachment.texture->GetGfxObject();
+ }
+
+ factory.SetColorAttachment( 0, // index of attachment (could have multiple attachments)
+ *graphicsTexture, mColorAttachment.mipmapLevel, mColorAttachment.layer );
+ }
+
+ if( mDepthAttachment.texture != nullptr )
+ {
+ auto graphicsTexture = mDepthAttachment.texture->GetGfxObject();
+ if( graphicsTexture )
+ {
+ auto depthStencilFormat = Graphics::TextureDetails::DepthStencilFlag::NONE;
+ switch( mDepthAttachment.format )
+ {
+ case Dali::FrameBuffer::Attachment::NONE:
++ case Dali::FrameBuffer::Attachment::COLOR:
+ {
+ depthStencilFormat = Graphics::TextureDetails::DepthStencilFlag::NONE;
+ break;
+ }
++ case Dali::FrameBuffer::Attachment::COLOR_DEPTH:
+ case Dali::FrameBuffer::Attachment::DEPTH:
+ {
+ depthStencilFormat = Graphics::TextureDetails::DepthStencilFlag::DEPTH;
+ break;
+ }
++ case Dali::FrameBuffer::Attachment::COLOR_STENCIL:
+ case Dali::FrameBuffer::Attachment::STENCIL:
+ {
+ depthStencilFormat = Graphics::TextureDetails::DepthStencilFlag::STENCIL;
+ break;
+ }
++ case Dali::FrameBuffer::Attachment::COLOR_DEPTH_STENCIL:
+ case Dali::FrameBuffer::Attachment::DEPTH_STENCIL:
+ {
+ depthStencilFormat = Graphics::TextureDetails::DepthStencilFlag::DEPTH_STENCIL;
+ break;
+ }
+ }
+
+ factory.SetDepthStencilAttachment( *graphicsTexture, mDepthAttachment.mipmapLevel, mDepthAttachment.layer,
+ depthStencilFormat );
+ }
+ }
+
+ mGraphicsFramebuffer = mGraphicsController->CreateFramebuffer( factory );
+ }
+}
+
+const Graphics::Framebuffer* FrameBuffer::GetGfxObject() const
+{
+ return mGraphicsFramebuffer.get();
+}
+
+void FrameBuffer::DestroyGraphicsObjects()
+{
+ mGraphicsFramebuffer.reset();
+}
+
+} //Render
+
+} //Internal
+
+} //Dali
mBlendMode( BlendMode::AUTO ),
mDepthWriteMode( DepthWriteMode::AUTO ),
mDepthTestMode( DepthTestMode::AUTO ),
+ mRenderingBehavior( DevelRenderer::Rendering::IF_REQUIRED ),
mPremultipledAlphaEnabled( false ),
+ mRenderCommands{},
+ mTextureBindings{},
mOpacity( 1.0f ),
mDepthIndex( 0 )
{
{
return mOpacity[updateBufferIndex];
}
-
+ void Renderer::SetRenderingBehavior( DevelRenderer::Rendering::Type renderingBehavior )
+ {
+ mRenderingBehavior = renderingBehavior;
+ }
+
+ DevelRenderer::Rendering::Type Renderer::GetRenderingBehavior() const
+ {
+ return mRenderingBehavior;
+ }
+
-//Called when SceneGraph::Renderer is added to update manager ( that happens when an "event-thread renderer" is created )
-void Renderer::ConnectToSceneGraph( SceneController& sceneController, BufferIndex bufferIndex )
-{
- mRegenerateUniformMap = REGENERATE_UNIFORM_MAP;
- mSceneController = &sceneController;
-
- mRenderDataProvider = new RenderDataProvider( mOpacity );
- mRenderDataProvider->mUniformMapDataProvider = this;
-
- mRenderer = Render::Renderer::New( mRenderDataProvider, mGeometry, mBlendBitmask, GetBlendColor(), static_cast< FaceCullingMode::Type >( mFaceCullingMode ),
- mPremultipledAlphaEnabled, mDepthWriteMode, mDepthTestMode, mDepthFunction, mStencilParameters );
-
- OwnerPointer< Render::Renderer > transferOwnership( mRenderer );
- mSceneController->GetRenderMessageDispatcher().AddRenderer( transferOwnership );
-}
-
-//Called just before destroying the scene-graph renderer ( when the "event-thread renderer" is no longer referenced )
-void Renderer::DisconnectFromSceneGraph( SceneController& sceneController, BufferIndex bufferIndex )
-{
- //Remove renderer from RenderManager
- if( mRenderer )
- {
- mSceneController->GetRenderMessageDispatcher().RemoveRenderer( *mRenderer );
- mRenderer = NULL;
- }
- mSceneController = NULL;
- mRenderDataProvider = NULL;
-}
-
-void Renderer::UpdateTextureSet()
-{
- if( mRenderDataProvider )
- {
- if( mTextureSet )
- {
- uint32_t textureCount = mTextureSet->GetTextureCount();
- mRenderDataProvider->mTextures.resize( textureCount );
- mRenderDataProvider->mSamplers.resize( textureCount );
- for( uint32_t i = 0; i<textureCount; ++i )
- {
- mRenderDataProvider->mTextures[i] = mTextureSet->GetTexture(i);
- mRenderDataProvider->mSamplers[i] = mTextureSet->GetTextureSampler(i);
- }
- }
- else
- {
- mRenderDataProvider->mTextures.clear();
- mRenderDataProvider->mSamplers.clear();
- }
- }
-}
-
-Render::Renderer& Renderer::GetRenderer()
-{
- return *mRenderer;
-}
+
-const CollectedUniformMap& Renderer::GetUniformMap( BufferIndex bufferIndex ) const
-{
- return mCollectedUniformMap[bufferIndex];
-}
Renderer::OpacityType Renderer::GetOpacityType( BufferIndex updateBufferIndex, const Node& node ) const
{
* @return The opacity
*/
float GetOpacity( BufferIndex updateBufferIndex ) const;
--
++
+ /**
+ * Helper function to update the uniform map.
+ * @param[in] bufferIndex The buffer to read from.
+ * @param[in] node NodeDataProvider to get uniform map
+ */
+ void UpdateUniformMap( BufferIndex bufferIndex, Node& node );
++
+ /**
+ * Sets the rendering behavior
+ * @param[in] renderingBehavior The rendering behavior required.
+ */
+ void SetRenderingBehavior( DevelRenderer::Rendering::Type renderingBehavior );
+
+ /**
+ * Gets the rendering behavior
+ * @return The rendering behavior
+ */
+ DevelRenderer::Rendering::Type GetRenderingBehavior() const;
/**
* Prepare the object for rendering.
uint32_t mRegenerateUniformMap; ///< 2 if the map should be regenerated, 1 if it should be copied.
uint32_t mResendFlag; ///< Indicate whether data should be resent to the renderer
+ BlendingOptions mBlendOptions; ///< The blending options
+
DepthFunction::Type mDepthFunction:4; ///< Local copy of the depth function
FaceCullingMode::Type mFaceCullingMode:3; ///< Local copy of the mode of face culling
+
BlendMode::Type mBlendMode:3; ///< Local copy of the mode of blending
+
DepthWriteMode::Type mDepthWriteMode:3; ///< Local copy of the depth write mode
DepthTestMode::Type mDepthTestMode:3; ///< Local copy of the depth test mode
+ DevelRenderer::Rendering::Type mRenderingBehavior:2; ///< The rendering behavior
- bool mUniformMapChanged[2]; ///< Records if the uniform map has been altered this frame
bool mPremultipledAlphaEnabled:1; ///< Flag indicating whether the Pre-multiplied Alpha Blending is required
-public:
+ RenderCommandContainer mRenderCommands;
+ std::vector<Graphics::RenderCommand::TextureBinding> mTextureBindings;
+public:
AnimatableProperty< float > mOpacity; ///< The opacity value
- int mDepthIndex; ///< Used only in PrepareRenderInstructions
+ int32_t mDepthIndex; ///< Used only in PrepareRenderInstructions
-
};
uint32_t* slot = eventThreadServices.ReserveMessageSlot( sizeof( LocalType ) );
// Construct message in the message queue memory; note that delete should not be called on the return value
- new (slot) LocalType( &renderer, &Renderer::SetGeometry, const_cast<Render::Geometry*>(&geometry) );
+ new (slot) LocalType( &renderer, &Renderer::SetGeometry, const_cast<SceneGraph::Geometry*>(&geometry) );
}
- inline void SetShaderMessage( EventThreadServices& eventThreadServices, const Renderer& renderer, Shader& shader )
+ inline void SetShaderMessage( EventThreadServices& eventThreadServices, const Renderer& renderer, const Shader& shader )
{
typedef MessageValue1< Renderer, Shader* > LocalType;
#define DALI_ACTOR_ENUMERATIONS_H
/*
-- * Copyright (c) 2017 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.
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
- * Copyright (c) 2017 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.
#define DALI_ACTOR_H
/*
-- * Copyright (c) 2018 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.
#define __DALI_CUSTOM_ACTOR_IMPL_H__
/*
-- * Copyright (c) 2018 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.
#define __DALI_DRAW_MODE_H__
/*
-- * 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.
#define DALI_LAYER_H
/*
-- * Copyright (c) 2018 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.
/*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
- * Copyright (c) 2018 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.
#define __DALI_VIEW_MODE_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_MATH_UTILS_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define __DALI_TYPE_INFO_H__
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
#define DALI_FRAMEBUFFER_H
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2018 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.
/*
-- * Copyright (c) 2016 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.
#define DALI_SHADER_H
/*
-- * Copyright (c) 2018 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.
-Name: dali
+Name: dali-vk
Summary: DALi 3D Engine
- Version: 1.3.52
+ Version: 1.4.5
Release: 1
Group: System/Libraries
License: Apache-2.0 and BSD-3-Clause and MIT