2 * Copyright (c) 2018 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/devel-api/adaptor-framework/vector-animation-renderer.h>
22 #include <dali/internal/vector-animation/common/vector-animation-renderer-impl.h>
27 VectorAnimationRenderer VectorAnimationRenderer::New( const std::string& url, Renderer renderer, uint32_t width, uint32_t height )
29 Internal::Adaptor::VectorAnimationRendererPtr animationRenderer = Internal::Adaptor::VectorAnimationRenderer::New();
30 if( animationRenderer )
32 animationRenderer->Initialize( url, renderer, width, height );
35 return VectorAnimationRenderer( animationRenderer.Get() );
38 VectorAnimationRenderer::VectorAnimationRenderer()
42 VectorAnimationRenderer::~VectorAnimationRenderer()
46 VectorAnimationRenderer::VectorAnimationRenderer( Internal::Adaptor::VectorAnimationRenderer* internal )
47 : BaseHandle( internal )
51 VectorAnimationRenderer::VectorAnimationRenderer( const VectorAnimationRenderer& handle )
52 : BaseHandle( handle )
56 VectorAnimationRenderer& VectorAnimationRenderer::operator=( const VectorAnimationRenderer& rhs )
58 BaseHandle::operator=( rhs );
62 bool VectorAnimationRenderer::StartRender()
64 return GetImplementation( *this ).StartRender();
67 void VectorAnimationRenderer::StopRender()
69 GetImplementation( *this ).StopRender();
72 void VectorAnimationRenderer::Render( uint32_t frameNumber )
74 GetImplementation( *this ).Render( frameNumber );
77 uint32_t VectorAnimationRenderer::GetTotalFrameNumber()
79 return GetImplementation( *this ).GetTotalFrameNumber();