#define DALI_OFFSCREEN_WINDOW_H
/*
- * Copyright (c) 2020 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2023 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/public-api/actors/actor.h>
#include <dali/public-api/math/uint-16-pair.h>
#include <dali/public-api/object/any.h>
-#include <dali/public-api/signals/dali-signal.h>
// INTERNAL INCLUDES
#include <dali/public-api/dali-adaptor-common.h>
class DALI_ADAPTOR_API OffscreenWindow : public Dali::BaseHandle
{
public:
- using WindowSize = Uint16Pair;
- using PostRenderSignalType = Signal<void(OffscreenWindow, Any)>;
+ using WindowSize = Uint16Pair;
public:
/**
OffscreenWindow& operator=(const OffscreenWindow& window);
/**
+ * @brief Move constructor
+ *
+ * @param [in] window A reference to the moved handle
+ */
+ OffscreenWindow(OffscreenWindow&& window);
+
+ /**
+ * @brief Move assignment operator
+ *
+ * @param [in] window A reference to the moved handle
+ * @return A reference to this
+ */
+ OffscreenWindow& operator=(OffscreenWindow&& window);
+
+ /**
* @brief Destructor
*/
~OffscreenWindow();
*/
Uint16Pair GetDpi() const;
-public: // Signals
/**
- * @brief This signal is emitted when the OffscreenWindow is rendered.
+ * @brief Sets the PostRenderCallback of the OffscreenWindow.
+ *
+ * @param[in] callback The PostRenderCallback function
+ * @code
+ * void MyFunction( OffscreenWindow window, Any nativeSurface );
+ * @endcode
+ *
+ * @note Ownership of the callback is passed onto this class.
+ *
+ */
+ void SetPostRenderCallback(CallbackBase* callback);
+
+ /**
+ * @brief Sets a callback that is called when the frame rendering is done by the graphics driver.
+ *
+ * @param[in] callback The function to call
+ *
+ * @note A callback of the following type may be used:
+ * @code
+ * void MyFunction();
+ * @endcode
*
- * @return The signal
+ * @note Ownership of the callback is passed onto this class.
*/
- PostRenderSignalType& PostRenderSignal();
+ void SetFrameRenderedCallback(CallbackBase* callback);
public: // Not intended for application developers
/**