#define __DALI_INTERNAL_SCENE_GRAPH_SHADER_H__
/*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2017 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/shader-effects/shader-effect.h>
#include <dali/internal/common/shader-data.h>
#include <dali/internal/update/common/property-owner.h>
#include <dali/internal/update/common/scene-graph-connection-change-propagator.h>
/**
* Constructor
- * @param hints Geometry hints
+ * @param hints Shader hints
*/
- Shader( Dali::ShaderEffect::GeometryHints& hints );
+ Shader( Dali::Shader::Hint::Value& hints );
/**
* Virtual destructor
virtual ~Shader();
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // The following methods are called during UpdateManager::Update()
+ // The following methods are called during Update
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/**
- * Query whether a shader geometry hint is set.
+ * Query whether a shader hint is set.
* @pre The shader has been initialized.
- * @param[in] hint The geometry hint to check.
- * @return True if the given geometry hint is set.
+ * @param[in] hint The hint to check.
+ * @return True if the given hint is set.
*/
- bool GeometryHintEnabled( Dali::ShaderEffect::GeometryHints hint ) const
+ bool HintEnabled( Dali::Shader::Hint::Value hint ) const
{
- return mGeometryHints & hint;
- }
-
- /**
- * Retrieve the set of geometry hints.
- * @return The hints.
- */
- Dali::ShaderEffect::GeometryHints GetGeometryHints() const
- {
- return mGeometryHints;
- }
-
- /**
- * Set the geometry hints.
- * @param[in] hints The hints.
- */
- void SetGeometryHints( Dali::ShaderEffect::GeometryHints hints )
- {
- mGeometryHints = hints;
+ return mHints & hint;
}
/**
}
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- // The following methods are called in Render thread
+ // The following methods are called during Render
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/**
*/
Program* GetProgram();
-public: // Implementation of ObjectOwnerContainer template methods
-
- /**
- * Connect the object to the scene graph
- *
- * @param[in] sceneController The scene controller - used for sending messages to render thread
- * @param[in] bufferIndex The current buffer index - used for sending messages to render thread
- */
- void ConnectToSceneGraph( SceneController& sceneController, BufferIndex bufferIndex );
-
- /**
- * Disconnect the object from the scene graph
- * @param[in] sceneController The scene controller - used for sending messages to render thread
- * @param[in] bufferIndex The current buffer index - used for sending messages to render thread
- */
- void DisconnectFromSceneGraph( SceneController& sceneController, BufferIndex bufferIndex );
-
public: // Implementation of ConnectionChangePropagator
/**
*/
void RemoveConnectionObserver(ConnectionChangePropagator::Observer& observer);
-public:
-
public: // UniformMap::Observer
/**
* @copydoc UniformMap::Observer::UniformMappingsChanged
private: // Data
- Dali::ShaderEffect::GeometryHints mGeometryHints; ///< shader geometry hints for building the geometry
+ Dali::Shader::Hint::Value mHints;
Program* mProgram;