1 /* 2 * Copyright (c) 2024 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef META_API_EASING_CURVE_H 17 #define META_API_EASING_CURVE_H 18 19 #include <meta/api/internal/object_api.h> 20 #include <meta/interface/animation/builtin_animations.h> 21 #include <meta/interface/curves/intf_easing_curve.h> 22 META_BEGIN_NAMESPACE()23META_BEGIN_NAMESPACE() 24 25 namespace Curves { 26 namespace Easing { 27 28 #define META_IMPLEMENT_EASING_CURVE_API(name) \ 29 class name : public Internal::ObjectInterfaceAPI<name, META_NS::ClassId::name##EasingCurve> { \ 30 META_API(name) \ 31 META_API_OBJECT_CONVERTIBLE(META_NS::ICurve1D) \ 32 META_API_OBJECT_CONVERTIBLE(META_NS::IEasingCurve) \ 33 }; 34 35 META_IMPLEMENT_EASING_CURVE_API(Linear) 36 META_IMPLEMENT_EASING_CURVE_API(InQuad) 37 META_IMPLEMENT_EASING_CURVE_API(OutQuad) 38 META_IMPLEMENT_EASING_CURVE_API(InOutQuad) 39 META_IMPLEMENT_EASING_CURVE_API(InCubic) 40 META_IMPLEMENT_EASING_CURVE_API(OutCubic) 41 META_IMPLEMENT_EASING_CURVE_API(InOutCubic) 42 META_IMPLEMENT_EASING_CURVE_API(InSine) 43 META_IMPLEMENT_EASING_CURVE_API(OutSine) 44 META_IMPLEMENT_EASING_CURVE_API(InOutSine) 45 META_IMPLEMENT_EASING_CURVE_API(InQuart) 46 META_IMPLEMENT_EASING_CURVE_API(OutQuart) 47 META_IMPLEMENT_EASING_CURVE_API(InOutQuart) 48 META_IMPLEMENT_EASING_CURVE_API(InQuint) 49 META_IMPLEMENT_EASING_CURVE_API(OutQuint) 50 META_IMPLEMENT_EASING_CURVE_API(InOutQuint) 51 META_IMPLEMENT_EASING_CURVE_API(InExpo) 52 META_IMPLEMENT_EASING_CURVE_API(OutExpo) 53 META_IMPLEMENT_EASING_CURVE_API(InOutExpo) 54 META_IMPLEMENT_EASING_CURVE_API(InCirc) 55 META_IMPLEMENT_EASING_CURVE_API(OutCirc) 56 META_IMPLEMENT_EASING_CURVE_API(InOutCirc) 57 META_IMPLEMENT_EASING_CURVE_API(InBack) 58 META_IMPLEMENT_EASING_CURVE_API(OutBack) 59 META_IMPLEMENT_EASING_CURVE_API(InOutBack) 60 META_IMPLEMENT_EASING_CURVE_API(InElastic) 61 META_IMPLEMENT_EASING_CURVE_API(OutElastic) 62 META_IMPLEMENT_EASING_CURVE_API(InOutElastic) 63 META_IMPLEMENT_EASING_CURVE_API(InBounce) 64 META_IMPLEMENT_EASING_CURVE_API(OutBounce) 65 META_IMPLEMENT_EASING_CURVE_API(InOutBounce) 66 META_IMPLEMENT_EASING_CURVE_API(StepStart) 67 META_IMPLEMENT_EASING_CURVE_API(StepEnd) 68 } // namespace Easing 69 } // namespace Curves 70 71 META_END_NAMESPACE() 72 73 #endif // META_API_EASING_CURVE_H 74