Visual Computing Library
Loading...
Searching...
No Matches
texture_images.h
1/*****************************************************************************
2 * VCLib *
3 * Visual Computing Library *
4 * *
5 * Copyright(C) 2021-2025 *
6 * Visual Computing Lab *
7 * ISTI - Italian National Research Council *
8 * *
9 * All rights reserved. *
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the Mozilla Public License Version 2.0 as published *
13 * by the Mozilla Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 * This program is distributed in the hope that it will be useful, *
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
19 * Mozilla Public License Version 2.0 *
20 * (https://www.mozilla.org/en-US/MPL/2.0/) for more details. *
21 ****************************************************************************/
22
23#ifndef VCL_CONCEPTS_MESH_COMPONENTS_TEXTURE_IMAGES_H
24#define VCL_CONCEPTS_MESH_COMPONENTS_TEXTURE_IMAGES_H
25
26#include "texture_paths.h"
27
28#include <vclib/concepts/space/texture.h>
29
30#include <string>
31
32namespace vcl::comp {
33
42template<typename T>
45 requires (T&& obj, typename RemoveRef<T>::TextureType t) {
46 typename RemoveRef<T>::TextureType;
47 typename RemoveRef<T>::TextureIterator;
48 typename RemoveRef<T>::ConstTextureIterator;
49
50 { obj.texture(uint()) } -> TextureConcept;
51
52 { obj.textureBegin() } -> InputIterator<decltype(t)>;
53 { obj.textureEnd() } -> InputIterator<decltype(t)>;
54 { obj.textures() } -> InputRange<decltype(t)>;
55
56 // non const requirements
57 requires IsConst<T> || requires {
58 { obj.clearTextures() } -> std::same_as<void>;
59 { obj.pushTexture(std::string()) } -> std::same_as<void>;
60 { obj.pushTexture(t) } -> std::same_as<void>;
61
62 { obj.textureBegin() } -> OutputIterator<decltype(t)>;
63 { obj.textureEnd() } -> OutputIterator<decltype(t)>;
64 { obj.textures() } -> OutputRange<decltype(t)>;
65 };
66 };
67
68} // namespace vcl::comp
69
70#endif // VCL_CONCEPTS_MESH_COMPONENTS_TEXTURE_IMAGES_H
The InputIterator concept is satisfied if T is an input iterator that implements the operator* return...
Definition iterators.h:46
Utility concept that is evaluated true the Range R is an Input Range and has a value_type that is con...
Definition range.h:89
The IsConst concept is satisfied if T satisfies one of the following conditions:
Definition const_correctness.h:43
The OutputIterator concept is satisfied if T is an output iterator that implements the operator* retu...
Definition iterators.h:60
Utility concept that is evaluated true the Range R is an Output Range and has a value_type that is T.
Definition range.h:113
Definition texture.h:33
HasTextureImages concept is satisfied only if a Mesh class provides the member functions specified in...
Definition texture_images.h:43
HasTexturePaths concept is satisfied only if a Mesh class provides the member functions specified in ...
Definition texture_paths.h:47