5 * Copyright (c) 2015 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.
22 #include <dali/public-api/object/handle.h> // Dali::Handle
23 #include <dali/public-api/actors/sampling.h>
28 namespace Internal DALI_INTERNAL
34 * @brief Sampler is a handle to an object that can be used to provide the sampling parameters to sample textures
36 class DALI_IMPORT_API Sampler : public BaseHandle
41 * @brief Creates a new Sampler object
46 * @brief Default constructor, creates an empty handle
56 * @brief Copy constructor, creates a new handle to the same object
58 * @param[in] handle Handle to an object
60 Sampler( const Sampler& handle );
63 * @brief Downcast to a sampler handle.
65 * If not the returned handle is left uninitialized.
66 * @param[in] handle to An object
67 * @return handle or an uninitialized handle
69 static Sampler DownCast( BaseHandle handle );
72 * @brief Assignment operator, changes this handle to point at the same object
74 * @param[in] handle Handle to an object
75 * @return Reference to the assigned object
77 Sampler& operator=( const Sampler& handle );
81 * @brief Set the filter modes for this sampler
83 * Calling this function sets the properties MINIFICATION_FILTER
84 * and MAGNIFICATION_FILTER
86 * @param[in] minFilter The minification filter that will be used
87 * @param[in] magFilter The magnification filter that will be used
89 void SetFilterMode( FilterMode::Type minFilter, FilterMode::Type magFilter );
92 * @brief Set the wrap modes for this sampler
94 * param[in] uWrap Wrap mode for u coordinates
95 * param[in] vWrap Wrap mode for v coordinates
97 void SetWrapMode( WrapMode::Type uWrap, WrapMode::Type vWrap );
100 * @brief Set the wrap modes for this sampler
102 * param[in] rWrap Wrap mode in the z direction
103 * param[in] sWrap Wrap mode for x direction
104 * param[in] tWrap Wrap mode for y direction
106 void SetWrapMode( WrapMode::Type rWrap, WrapMode::Type sWrap, WrapMode::Type tWrap );
110 * @brief The constructor
112 * @param [in] pointer A pointer to a newly allocated Sampler
114 explicit DALI_INTERNAL Sampler( Internal::Sampler* pointer );
119 #endif // DALI_SAMPLER_H