2 * Copyright (c) 2023 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
19 #include <dali-scene3d/public-api/model-motion/motion-index/motion-property-index.h>
22 #include <dali-scene3d/internal/model-motion/motion-index/motion-property-index-impl.h>
28 MotionPropertyIndex MotionPropertyIndex::New()
30 Internal::MotionPropertyIndexPtr internal = Internal::MotionPropertyIndex::New();
32 return MotionPropertyIndex(internal.Get());
35 MotionPropertyIndex MotionPropertyIndex::New(Property::Key modelNodeId, Property::Key propertyId)
37 Internal::MotionPropertyIndexPtr internal = Internal::MotionPropertyIndex::New();
39 internal->SetModelNodeId(modelNodeId);
40 internal->SetPropertyId(propertyId);
42 return MotionPropertyIndex(internal.Get());
45 MotionPropertyIndex::MotionPropertyIndex()
49 MotionPropertyIndex::MotionPropertyIndex(const MotionPropertyIndex& motionPropertyIndex) = default;
51 MotionPropertyIndex::MotionPropertyIndex(MotionPropertyIndex&& rhs) noexcept = default;
53 MotionPropertyIndex::~MotionPropertyIndex()
57 MotionPropertyIndex& MotionPropertyIndex::operator=(const MotionPropertyIndex& handle) = default;
59 MotionPropertyIndex& MotionPropertyIndex::operator=(MotionPropertyIndex&& rhs) noexcept = default;
61 MotionPropertyIndex MotionPropertyIndex::DownCast(BaseHandle handle)
63 return MotionPropertyIndex(dynamic_cast<Dali::Scene3D::Internal::MotionPropertyIndex*>(handle.GetObjectPtr()));
66 MotionPropertyIndex::MotionPropertyIndex(Dali::Scene3D::Internal::MotionPropertyIndex* internal)
67 : MotionIndex(internal)
73 void MotionPropertyIndex::SetPropertyId(Property::Key blendShapeId)
75 GetImplementation(*this).SetPropertyId(blendShapeId);
78 Property::Key MotionPropertyIndex::GetPropertyId() const
80 return GetImplementation(*this).GetPropertyId();
83 } // namespace Scene3D