1 #ifndef __DALI_INTERNAL_RESOURCE_TRACKER_H__
2 #define __DALI_INTERNAL_RESOURCE_TRACKER_H__
5 * Copyright (c) 2014 Samsung Electronics Co., Ltd.
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
21 #include <dali/integration-api/resource-declarations.h>
22 #include <dali/internal/update/common/scene-graph-buffers.h>
28 class GlSyncAbstraction;
37 class RenderMessageDispatcher;
41 * Class to track completion of a resource.
42 * Created for resource objects that can change completion status during update passes,
43 * such as chained framebuffers. This base class is designed to be used on resources that
44 * change completion in the update thread.
57 virtual ~ResourceTracker();
60 * Second stage initialization
62 virtual void Initialize();
65 * first stage destruction
66 * Called from CompleteStatusManager when the object is about to be deleted
68 virtual void OnDestroy();
76 * Set the tracker to be complete (Derived types may ignore this)
81 * @return TRUE if the resource is complete
87 * Do the reset. Allows derived types to handle the reset themselves.
89 virtual void DoReset();
92 * Do the SetComplete. Allows derived types to handle the completeness themselves.
94 virtual void DoSetComplete();
97 * Do the IsComplete. Allows derived types to perform their own handling
99 virtual bool DoIsComplete();
101 bool mComplete; ///< TRUE if tracked resource has completed
105 * Undefined Copy Constructor and assignment operator
107 ResourceTracker(const ResourceTracker& rhs);
108 ResourceTracker& operator=(const ResourceTracker& rhs);
116 #endif // __DALI_INTERNAL_RESOURCE_TRACKER_H__