1 #ifndef __DALI_IMAGE_SAMPLER_H__
2 #define __DALI_IMAGE_SAMPLER_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.
22 #include <dali/public-api/actors/sampling.h>
31 * ImageSampler represents a set of sampling settings that can be applied to a texture.
33 namespace ImageSampler
37 * Determine if the minify component of the bitfield is assigned.
39 * @param[in] bitfield The packed sampler bitfield pattern.
40 * @return Return if the minify component is assigned or not.
42 bool IsMinifyAssigned( unsigned int bitfield );
45 * Determine if the magnify component of the bitfield is assigned.
47 * @param[in] bitfield The packed sampler bitfield pattern.
48 * @return Return if the magnify component is assigned or not.
50 bool IsMagnifyAssigned( unsigned int bitfield );
53 * @brief Return a sampler bitfield with default settings.
55 * @return Return the default sampler bit pattern.
57 unsigned int DefaultOptions();
60 * @brief Pack the filter mode into a bitfield.
62 * @param[in] minify The minification filter.
63 * @param[in] magnify The magnification filter.
64 * @return Return the packed bitfield.
66 unsigned int PackBitfield( FilterMode::Type minify, FilterMode::Type magnify );
69 * @brief Return the minification filter from a packed bitfield.
71 * @return Return the minification filter.
73 FilterMode::Type GetMinifyFilterMode( unsigned int bitfield );
76 * @brief Return the magnification filter from a packed bitfield.
78 * @return Return the magnification filter.
80 FilterMode::Type GetMagnifyFilterMode( unsigned int bitfield );
82 } // namespace ImageSampler
84 } // namespace Internal
89 #endif // __DALI_INTERNAL_IMAGE_SAMPLER_H__