Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <jacques@blender.org>2020-08-07 11:04:57 +0300
committerJacques Lucke <jacques@blender.org>2020-08-07 11:04:57 +0300
commit7283e6fb73490ddd23425ba2cf06cda7ac8f9458 (patch)
tree7c0c7069a44743b7462d3ed271bedeb09300ec4f /source/blender/gpu
parent21fec951396982807d9cbe3852c58dbc898a809c (diff)
parent91694b9b58ab953f3b313be9389cc1303e472fc2 (diff)
Merge branch 'blender-v2.90-release' into master
Diffstat (limited to 'source/blender/gpu')
-rw-r--r--source/blender/gpu/GPU_attr_binding.h5
-rw-r--r--source/blender/gpu/GPU_batch.h5
-rw-r--r--source/blender/gpu/GPU_batch_presets.h5
-rw-r--r--source/blender/gpu/GPU_batch_utils.h5
-rw-r--r--source/blender/gpu/GPU_buffers.h5
-rw-r--r--source/blender/gpu/GPU_common.h5
-rw-r--r--source/blender/gpu/GPU_context.h5
-rw-r--r--source/blender/gpu/GPU_debug.h5
-rw-r--r--source/blender/gpu/GPU_element.h5
-rw-r--r--source/blender/gpu/GPU_extensions.h5
-rw-r--r--source/blender/gpu/GPU_framebuffer.h5
-rw-r--r--source/blender/gpu/GPU_glew.h5
-rw-r--r--source/blender/gpu/GPU_immediate.h5
-rw-r--r--source/blender/gpu/GPU_immediate_util.h5
-rw-r--r--source/blender/gpu/GPU_init_exit.h5
-rw-r--r--source/blender/gpu/GPU_legacy_stubs.h5
-rw-r--r--source/blender/gpu/GPU_material.h5
-rw-r--r--source/blender/gpu/GPU_matrix.h5
-rw-r--r--source/blender/gpu/GPU_platform.h5
-rw-r--r--source/blender/gpu/GPU_primitive.h5
-rw-r--r--source/blender/gpu/GPU_select.h5
-rw-r--r--source/blender/gpu/GPU_shader.h5
-rw-r--r--source/blender/gpu/GPU_shader_interface.h5
-rw-r--r--source/blender/gpu/GPU_state.h5
-rw-r--r--source/blender/gpu/GPU_texture.h5
-rw-r--r--source/blender/gpu/GPU_uniformbuffer.h5
-rw-r--r--source/blender/gpu/GPU_vertex_buffer.h5
-rw-r--r--source/blender/gpu/GPU_vertex_format.h5
-rw-r--r--source/blender/gpu/GPU_viewport.h5
-rw-r--r--source/blender/gpu/intern/gpu_attr_binding_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_batch_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_codegen.h5
-rw-r--r--source/blender/gpu/intern/gpu_context_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_material_library.h5
-rw-r--r--source/blender/gpu/intern/gpu_matrix_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_node_graph.h5
-rw-r--r--source/blender/gpu/intern/gpu_primitive_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_select_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_shader_private.h5
-rw-r--r--source/blender/gpu/intern/gpu_vertex_format_private.h5
41 files changed, 41 insertions, 164 deletions
diff --git a/source/blender/gpu/GPU_attr_binding.h b/source/blender/gpu/GPU_attr_binding.h
index 8093e02cab6..e7c3dcbce05 100644
--- a/source/blender/gpu/GPU_attr_binding.h
+++ b/source/blender/gpu/GPU_attr_binding.h
@@ -23,8 +23,7 @@
* GPU vertex attribute binding
*/
-#ifndef __GPU_ATTR_BINDING_H__
-#define __GPU_ATTR_BINDING_H__
+#pragma once
#include "GPU_common.h"
@@ -42,5 +41,3 @@ typedef struct GPUAttrBinding {
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_ATTR_BINDING_H__ */
diff --git a/source/blender/gpu/GPU_batch.h b/source/blender/gpu/GPU_batch.h
index 85d9c037b38..71a29d0b178 100644
--- a/source/blender/gpu/GPU_batch.h
+++ b/source/blender/gpu/GPU_batch.h
@@ -24,8 +24,7 @@
* Contains VAOs + VBOs + Shader representing a drawable entity.
*/
-#ifndef __GPU_BATCH_H__
-#define __GPU_BATCH_H__
+#pragma once
#include "GPU_element.h"
#include "GPU_shader.h"
@@ -247,5 +246,3 @@ void gpu_batch_exit(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_BATCH_H__ */
diff --git a/source/blender/gpu/GPU_batch_presets.h b/source/blender/gpu/GPU_batch_presets.h
index 38de21e7955..1674cf776db 100644
--- a/source/blender/gpu/GPU_batch_presets.h
+++ b/source/blender/gpu/GPU_batch_presets.h
@@ -24,8 +24,7 @@
* This file contains any additions or modifications specific to Blender.
*/
-#ifndef __GPU_BATCH_PRESETS_H__
-#define __GPU_BATCH_PRESETS_H__
+#pragma once
#include "BLI_compiler_attrs.h"
#include "BLI_sys_types.h"
@@ -55,5 +54,3 @@ void GPU_batch_presets_reset(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_BATCH_PRESETS_H__ */
diff --git a/source/blender/gpu/GPU_batch_utils.h b/source/blender/gpu/GPU_batch_utils.h
index 8f85ac59aa5..37dccc4621c 100644
--- a/source/blender/gpu/GPU_batch_utils.h
+++ b/source/blender/gpu/GPU_batch_utils.h
@@ -18,8 +18,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_BATCH_UTILS_H__
-#define __GPU_BATCH_UTILS_H__
+#pragma once
#include "BLI_compiler_attrs.h"
#include "BLI_sys_types.h"
@@ -44,5 +43,3 @@ struct GPUBatch *gpu_batch_sphere(int lat_res, int lon_res) ATTR_WARN_UNUSED_RES
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_BATCH_UTILS_H__ */
diff --git a/source/blender/gpu/GPU_buffers.h b/source/blender/gpu/GPU_buffers.h
index c7e74040568..23349728f25 100644
--- a/source/blender/gpu/GPU_buffers.h
+++ b/source/blender/gpu/GPU_buffers.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_BUFFERS_H__
-#define __GPU_BUFFERS_H__
+#pragma once
#include <stddef.h>
@@ -121,5 +120,3 @@ bool GPU_pbvh_buffers_has_overlays(GPU_PBVH_Buffers *buffers);
#ifdef __cplusplus
}
#endif
-
-#endif
diff --git a/source/blender/gpu/GPU_common.h b/source/blender/gpu/GPU_common.h
index dd580ebbdac..8fd1baba2f7 100644
--- a/source/blender/gpu/GPU_common.h
+++ b/source/blender/gpu/GPU_common.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_COMMON_H__
-#define __GPU_COMMON_H__
+#pragma once
#define PROGRAM_NO_OPTI 0
@@ -51,5 +50,3 @@
#else
# define GPU_INLINE static inline __attribute__((always_inline)) __attribute__((__unused__))
#endif
-
-#endif /* __GPU_COMMON_H__ */
diff --git a/source/blender/gpu/GPU_context.h b/source/blender/gpu/GPU_context.h
index 6af150b4660..4f0edaf3ac8 100644
--- a/source/blender/gpu/GPU_context.h
+++ b/source/blender/gpu/GPU_context.h
@@ -23,8 +23,7 @@
* This interface allow GPU to manage VAOs for multiple context and threads.
*/
-#ifndef __GPU_CONTEXT_H__
-#define __GPU_CONTEXT_H__
+#pragma once
#include "GPU_batch.h"
#include "GPU_common.h"
@@ -53,5 +52,3 @@ void GPU_context_main_unlock(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_CONTEXT_H__ */
diff --git a/source/blender/gpu/GPU_debug.h b/source/blender/gpu/GPU_debug.h
index fc6ca791664..be822056678 100644
--- a/source/blender/gpu/GPU_debug.h
+++ b/source/blender/gpu/GPU_debug.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_DEBUG_H__
-#define __GPU_DEBUG_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -37,5 +36,3 @@ void GPU_string_marker(const char *str);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_DEBUG_H__ */
diff --git a/source/blender/gpu/GPU_element.h b/source/blender/gpu/GPU_element.h
index 9aef8d6ed73..3d5195b12fc 100644
--- a/source/blender/gpu/GPU_element.h
+++ b/source/blender/gpu/GPU_element.h
@@ -23,8 +23,7 @@
* GPU element list (AKA index buffer)
*/
-#ifndef __GPU_ELEMENT_H__
-#define __GPU_ELEMENT_H__
+#pragma once
#include "GPU_primitive.h"
@@ -116,5 +115,3 @@ int GPU_indexbuf_primitive_len(GPUPrimType prim_type);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_ELEMENT_H__ */
diff --git a/source/blender/gpu/GPU_extensions.h b/source/blender/gpu/GPU_extensions.h
index 0518108edf6..2ce6e458378 100644
--- a/source/blender/gpu/GPU_extensions.h
+++ b/source/blender/gpu/GPU_extensions.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_EXTENSIONS_H__
-#define __GPU_EXTENSIONS_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -64,5 +63,3 @@ bool GPU_stereo_quadbuffer_support(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_EXTENSIONS_H__ */
diff --git a/source/blender/gpu/GPU_framebuffer.h b/source/blender/gpu/GPU_framebuffer.h
index db531cdef9b..9dc07fefd4e 100644
--- a/source/blender/gpu/GPU_framebuffer.h
+++ b/source/blender/gpu/GPU_framebuffer.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_FRAMEBUFFER_H__
-#define __GPU_FRAMEBUFFER_H__
+#pragma once
#include "GPU_texture.h"
@@ -235,5 +234,3 @@ void GPU_backbuffer_bind(eGPUBackBuffer buffer);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_FRAMEBUFFER_H__ */
diff --git a/source/blender/gpu/GPU_glew.h b/source/blender/gpu/GPU_glew.h
index 744bce9713a..e87a7054e5f 100644
--- a/source/blender/gpu/GPU_glew.h
+++ b/source/blender/gpu/GPU_glew.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_GLEW_H__
-#define __GPU_GLEW_H__
+#pragma once
#if defined(WITH_OPENGL)
# include "glew-mx.h"
@@ -30,5 +29,3 @@
# include "GPU_legacy_stubs.h"
# endif
#endif
-
-#endif /* __GPU_GLEW_H__ */
diff --git a/source/blender/gpu/GPU_immediate.h b/source/blender/gpu/GPU_immediate.h
index 8e356cfb0e3..41d4f5d28d3 100644
--- a/source/blender/gpu/GPU_immediate.h
+++ b/source/blender/gpu/GPU_immediate.h
@@ -23,8 +23,7 @@
* GPU immediate mode work-alike
*/
-#ifndef __GPU_IMMEDIATE_H__
-#define __GPU_IMMEDIATE_H__
+#pragma once
#include "GPU_batch.h"
#include "GPU_immediate_util.h"
@@ -158,5 +157,3 @@ void immDestroy(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_IMMEDIATE_H__ */
diff --git a/source/blender/gpu/GPU_immediate_util.h b/source/blender/gpu/GPU_immediate_util.h
index 47b44b59461..7786bcd2d06 100644
--- a/source/blender/gpu/GPU_immediate_util.h
+++ b/source/blender/gpu/GPU_immediate_util.h
@@ -20,8 +20,7 @@
* Utility drawing functions (rough equivalent to OpenGL's GLU)
*/
-#ifndef __GPU_IMMEDIATE_UTIL_H__
-#define __GPU_IMMEDIATE_UTIL_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -92,5 +91,3 @@ void imm_draw_cylinder_fill_3d(
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_IMMEDIATE_UTIL_H__ */
diff --git a/source/blender/gpu/GPU_init_exit.h b/source/blender/gpu/GPU_init_exit.h
index 58b9505cdb1..42c56940c4c 100644
--- a/source/blender/gpu/GPU_init_exit.h
+++ b/source/blender/gpu/GPU_init_exit.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_INIT_EXIT_H__
-#define __GPU_INIT_EXIT_H__
+#pragma once
#include "BLI_utildefines.h"
@@ -37,5 +36,3 @@ bool GPU_is_init(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_INIT_EXIT_H__ */
diff --git a/source/blender/gpu/GPU_legacy_stubs.h b/source/blender/gpu/GPU_legacy_stubs.h
index c666ff73bc6..2e21b879907 100644
--- a/source/blender/gpu/GPU_legacy_stubs.h
+++ b/source/blender/gpu/GPU_legacy_stubs.h
@@ -26,8 +26,7 @@
* This file should be removed in the future
*/
-#ifndef __GPU_LEGACY_STUBS_H__
-#define __GPU_LEGACY_STUBS_H__
+#pragma once
#if defined(__GNUC__)
# pragma GCC diagnostic push
@@ -512,5 +511,3 @@ _GL_VOID DO_NOT_USE_glClientActiveTexture(GLenum texture) _GL_VOID_RET
#if defined(__GNUC__)
# pragma GCC diagnostic pop
#endif
-
-#endif /* __GPU_LEGACY_STUBS_H__ */
diff --git a/source/blender/gpu/GPU_material.h b/source/blender/gpu/GPU_material.h
index 7512fac6410..b8957ff1819 100644
--- a/source/blender/gpu/GPU_material.h
+++ b/source/blender/gpu/GPU_material.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_MATERIAL_H__
-#define __GPU_MATERIAL_H__
+#pragma once
#include "DNA_customdata_types.h" /* for CustomDataType */
#include "DNA_listBase.h"
@@ -264,5 +263,3 @@ ListBase GPU_material_volume_grids(GPUMaterial *material);
#ifdef __cplusplus
}
#endif
-
-#endif /*__GPU_MATERIAL_H__*/
diff --git a/source/blender/gpu/GPU_matrix.h b/source/blender/gpu/GPU_matrix.h
index eabfb5d2dc3..7b94a535a30 100644
--- a/source/blender/gpu/GPU_matrix.h
+++ b/source/blender/gpu/GPU_matrix.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_MATRIX_H__
-#define __GPU_MATRIX_H__
+#pragma once
#include "BLI_sys_types.h"
@@ -236,5 +235,3 @@ int GPU_matrix_stack_level_get_projection(void);
* however we need to check these limits in code that calls into these API's. */
#define GPU_MATRIX_ORTHO_CLIP_NEAR_DEFAULT (-100)
#define GPU_MATRIX_ORTHO_CLIP_FAR_DEFAULT (100)
-
-#endif /* __GPU_MATRIX_H__ */
diff --git a/source/blender/gpu/GPU_platform.h b/source/blender/gpu/GPU_platform.h
index 104d5ef0ddc..a89298c0d01 100644
--- a/source/blender/gpu/GPU_platform.h
+++ b/source/blender/gpu/GPU_platform.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_PLATFORM_H__
-#define __GPU_PLATFORM_H__
+#pragma once
#include "BLI_sys_types.h"
#include "BLI_utildefines.h"
@@ -74,5 +73,3 @@ const char *GPU_platform_gpu_name(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_PLATFORM_H__ */
diff --git a/source/blender/gpu/GPU_primitive.h b/source/blender/gpu/GPU_primitive.h
index 4cd6205c0d1..e910e81fac1 100644
--- a/source/blender/gpu/GPU_primitive.h
+++ b/source/blender/gpu/GPU_primitive.h
@@ -23,8 +23,7 @@
* GPU geometric primitives
*/
-#ifndef __GPU_PRIMITIVE_H__
-#define __GPU_PRIMITIVE_H__
+#pragma once
#include "GPU_common.h"
@@ -63,5 +62,3 @@ bool GPU_primtype_belongs_to_class(GPUPrimType, GPUPrimClass);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_PRIMITIVE_H__ */
diff --git a/source/blender/gpu/GPU_select.h b/source/blender/gpu/GPU_select.h
index d9a8e964a3d..d28363253b1 100644
--- a/source/blender/gpu/GPU_select.h
+++ b/source/blender/gpu/GPU_select.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_SELECT_H__
-#define __GPU_SELECT_H__
+#pragma once
#include "BLI_sys_types.h"
@@ -63,5 +62,3 @@ void GPU_select_buffer_stride_realign(const struct rcti *src, const struct rcti
#ifdef __cplusplus
}
#endif
-
-#endif
diff --git a/source/blender/gpu/GPU_shader.h b/source/blender/gpu/GPU_shader.h
index b51a63a1c1f..f782742ae53 100644
--- a/source/blender/gpu/GPU_shader.h
+++ b/source/blender/gpu/GPU_shader.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_SHADER_H__
-#define __GPU_SHADER_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -370,5 +369,3 @@ void GPU_shader_free_builtin_shaders(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_SHADER_H__ */
diff --git a/source/blender/gpu/GPU_shader_interface.h b/source/blender/gpu/GPU_shader_interface.h
index 28ee162bdbd..8aba1236b65 100644
--- a/source/blender/gpu/GPU_shader_interface.h
+++ b/source/blender/gpu/GPU_shader_interface.h
@@ -23,8 +23,7 @@
* GPU shader interface (C --> GLSL)
*/
-#ifndef __GPU_SHADER_INTERFACE_H__
-#define __GPU_SHADER_INTERFACE_H__
+#pragma once
#include "GPU_common.h"
@@ -116,5 +115,3 @@ void GPU_shaderinterface_remove_batch_ref(GPUShaderInterface *, struct GPUBatch
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_SHADER_INTERFACE_H__ */
diff --git a/source/blender/gpu/GPU_state.h b/source/blender/gpu/GPU_state.h
index a71b44507ba..4a2c90e241b 100644
--- a/source/blender/gpu/GPU_state.h
+++ b/source/blender/gpu/GPU_state.h
@@ -18,8 +18,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_STATE_H__
-#define __GPU_STATE_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -109,5 +108,3 @@ void gpuPopAttr(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_STATE_H__ */
diff --git a/source/blender/gpu/GPU_texture.h b/source/blender/gpu/GPU_texture.h
index 1fbcfd41dec..7ee7f8fcdec 100644
--- a/source/blender/gpu/GPU_texture.h
+++ b/source/blender/gpu/GPU_texture.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_TEXTURE_H__
-#define __GPU_TEXTURE_H__
+#pragma once
#include "BLI_utildefines.h"
@@ -302,5 +301,3 @@ void GPU_sampler_icon_bind(int number);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_TEXTURE_H__ */
diff --git a/source/blender/gpu/GPU_uniformbuffer.h b/source/blender/gpu/GPU_uniformbuffer.h
index 6862c1d960d..e2b2a757fb9 100644
--- a/source/blender/gpu/GPU_uniformbuffer.h
+++ b/source/blender/gpu/GPU_uniformbuffer.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_UNIFORMBUFFER_H__
-#define __GPU_UNIFORMBUFFER_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -52,5 +51,3 @@ bool GPU_uniformbuffer_is_dirty(GPUUniformBuffer *ubo);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_UNIFORMBUFFER_H__ */
diff --git a/source/blender/gpu/GPU_vertex_buffer.h b/source/blender/gpu/GPU_vertex_buffer.h
index d1693852c1a..757255496e0 100644
--- a/source/blender/gpu/GPU_vertex_buffer.h
+++ b/source/blender/gpu/GPU_vertex_buffer.h
@@ -23,8 +23,7 @@
* GPU vertex buffer
*/
-#ifndef __GPU_VERTEX_BUFFER_H__
-#define __GPU_VERTEX_BUFFER_H__
+#pragma once
#include "GPU_vertex_format.h"
@@ -147,5 +146,3 @@ uint GPU_vertbuf_get_memory_usage(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_VERTEX_BUFFER_H__ */
diff --git a/source/blender/gpu/GPU_vertex_format.h b/source/blender/gpu/GPU_vertex_format.h
index cf0f52e3950..59af912ed3d 100644
--- a/source/blender/gpu/GPU_vertex_format.h
+++ b/source/blender/gpu/GPU_vertex_format.h
@@ -23,8 +23,7 @@
* GPU vertex format
*/
-#ifndef __GPU_VERTEX_FORMAT_H__
-#define __GPU_VERTEX_FORMAT_H__
+#pragma once
#include "BLI_assert.h"
#include "BLI_compiler_compat.h"
@@ -199,5 +198,3 @@ BLI_INLINE GPUPackedNormal GPU_normal_convert_i10_s3(const short data[3])
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_VERTEX_FORMAT_H__ */
diff --git a/source/blender/gpu/GPU_viewport.h b/source/blender/gpu/GPU_viewport.h
index 878e7e3e9a8..60b78ecd59b 100644
--- a/source/blender/gpu/GPU_viewport.h
+++ b/source/blender/gpu/GPU_viewport.h
@@ -21,8 +21,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_VIEWPORT_H__
-#define __GPU_VIEWPORT_H__
+#pragma once
#include <stdbool.h>
@@ -159,5 +158,3 @@ struct GPUFrameBuffer *GPU_viewport_framebuffer_overlay_get(GPUViewport *viewpor
#ifdef __cplusplus
}
#endif
-
-#endif // __GPU_VIEWPORT_H__
diff --git a/source/blender/gpu/intern/gpu_attr_binding_private.h b/source/blender/gpu/intern/gpu_attr_binding_private.h
index 7df403a3ea5..4d359343c38 100644
--- a/source/blender/gpu/intern/gpu_attr_binding_private.h
+++ b/source/blender/gpu/intern/gpu_attr_binding_private.h
@@ -23,8 +23,7 @@
* GPU vertex attribute binding
*/
-#ifndef __GPU_ATTR_BINDING_PRIVATE_H__
-#define __GPU_ATTR_BINDING_PRIVATE_H__
+#pragma once
#include "GPU_shader_interface.h"
#include "GPU_vertex_format.h"
@@ -44,5 +43,3 @@ uint read_attr_location(const GPUAttrBinding *binding, uint a_idx);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_ATTR_BINDING_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_batch_private.h b/source/blender/gpu/intern/gpu_batch_private.h
index 58d1810ac7a..93745b9ca9b 100644
--- a/source/blender/gpu/intern/gpu_batch_private.h
+++ b/source/blender/gpu/intern/gpu_batch_private.h
@@ -24,8 +24,7 @@
* Contains VAOs + VBOs + Shader representing a drawable entity.
*/
-#ifndef __GPU_BATCH_PRIVATE_H__
-#define __GPU_BATCH_PRIVATE_H__
+#pragma once
#include "GPU_batch.h"
#include "GPU_context.h"
@@ -40,5 +39,3 @@ void gpu_batch_remove_interface_ref(GPUBatch *batch, const GPUShaderInterface *i
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_BATCH_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_codegen.h b/source/blender/gpu/intern/gpu_codegen.h
index c08ac663cef..5d130d75d2c 100644
--- a/source/blender/gpu/intern/gpu_codegen.h
+++ b/source/blender/gpu/intern/gpu_codegen.h
@@ -23,8 +23,7 @@
* Generate shader code from the intermediate node graph.
*/
-#ifndef __GPU_CODEGEN_H__
-#define __GPU_CODEGEN_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -70,5 +69,3 @@ void gpu_codegen_exit(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_CODEGEN_H__ */
diff --git a/source/blender/gpu/intern/gpu_context_private.h b/source/blender/gpu/intern/gpu_context_private.h
index f64cdf439a1..08fbefe3b3f 100644
--- a/source/blender/gpu/intern/gpu_context_private.h
+++ b/source/blender/gpu/intern/gpu_context_private.h
@@ -23,8 +23,7 @@
* This interface allow GPU to manage GL objects for multiple context and threads.
*/
-#ifndef __GPU_CONTEXT_PRIVATE_H__
-#define __GPU_CONTEXT_PRIVATE_H__
+#pragma once
#include "GPU_context.h"
@@ -64,5 +63,3 @@ struct GPUMatrixState *gpu_context_active_matrix_state_get(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_CONTEXT_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_material_library.h b/source/blender/gpu/intern/gpu_material_library.h
index f69c25b9490..da7b1636fa3 100644
--- a/source/blender/gpu/intern/gpu_material_library.h
+++ b/source/blender/gpu/intern/gpu_material_library.h
@@ -22,8 +22,7 @@
*
* Parsing of and code generation using GLSL shaders in gpu/shaders/material. */
-#ifndef __GPU_MATERIAL_LIBRARY_H__
-#define __GPU_MATERIAL_LIBRARY_H__
+#pragma once
#include "GPU_material.h"
@@ -65,5 +64,3 @@ char *gpu_material_library_generate_code(struct GSet *used_libraries, const char
char *gpu_str_skip_token(char *str, char *token, int max);
const char *gpu_data_type_to_string(const eGPUType type);
-
-#endif /* __ __GPU_MATERIAL_LIBRARY_H__ */
diff --git a/source/blender/gpu/intern/gpu_matrix_private.h b/source/blender/gpu/intern/gpu_matrix_private.h
index 862ef065481..3448b0a95aa 100644
--- a/source/blender/gpu/intern/gpu_matrix_private.h
+++ b/source/blender/gpu/intern/gpu_matrix_private.h
@@ -18,8 +18,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_MATRIX_PRIVATE_H__
-#define __GPU_MATRIX_PRIVATE_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -31,5 +30,3 @@ void GPU_matrix_state_discard(struct GPUMatrixState *state);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_MATRIX_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_node_graph.h b/source/blender/gpu/intern/gpu_node_graph.h
index a133dd1ccdc..7265abf4d65 100644
--- a/source/blender/gpu/intern/gpu_node_graph.h
+++ b/source/blender/gpu/intern/gpu_node_graph.h
@@ -23,8 +23,7 @@
* Intermediate node graph for generating GLSL shaders.
*/
-#ifndef __GPU_NODE_GRAPH_H__
-#define __GPU_NODE_GRAPH_H__
+#pragma once
#include "DNA_customdata_types.h"
#include "DNA_listBase.h"
@@ -164,5 +163,3 @@ struct GPUTexture **gpu_material_ramp_texture_row_set(struct GPUMaterial *mat,
float *row);
struct GSet *gpu_material_used_libraries(struct GPUMaterial *material);
-
-#endif /* __GPU_NODE_GRAPH_H__ */
diff --git a/source/blender/gpu/intern/gpu_primitive_private.h b/source/blender/gpu/intern/gpu_primitive_private.h
index b7d7b262128..e91eec18786 100644
--- a/source/blender/gpu/intern/gpu_primitive_private.h
+++ b/source/blender/gpu/intern/gpu_primitive_private.h
@@ -23,8 +23,7 @@
* GPU geometric primitives
*/
-#ifndef __GPU_PRIMITIVE_PRIVATE_H__
-#define __GPU_PRIMITIVE_PRIVATE_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -36,5 +35,3 @@ GLenum convert_prim_type_to_gl(GPUPrimType);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_PRIMITIVE_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_private.h b/source/blender/gpu/intern/gpu_private.h
index ed729dd399c..ef96bedae4a 100644
--- a/source/blender/gpu/intern/gpu_private.h
+++ b/source/blender/gpu/intern/gpu_private.h
@@ -18,8 +18,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_PRIVATE_H__
-#define __GPU_PRIVATE_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -48,5 +47,3 @@ void gpu_pbvh_exit(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_select_private.h b/source/blender/gpu/intern/gpu_select_private.h
index a0619bd4293..e364b78bff2 100644
--- a/source/blender/gpu/intern/gpu_select_private.h
+++ b/source/blender/gpu/intern/gpu_select_private.h
@@ -23,8 +23,7 @@
* Selection implementations.
*/
-#ifndef __GPU_SELECT_PRIVATE_H__
-#define __GPU_SELECT_PRIVATE_H__
+#pragma once
/* gpu_select_pick */
void gpu_select_pick_begin(uint (*buffer)[4], uint bufsize, const rcti *input, char mode);
@@ -43,5 +42,3 @@ bool gpu_select_query_load_id(uint id);
uint gpu_select_query_end(void);
#define SELECT_ID_NONE ((uint)0xffffffff)
-
-#endif /* __GPU_SELECT_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_shader_private.h b/source/blender/gpu/intern/gpu_shader_private.h
index 2c52568ac25..0f89fbda737 100644
--- a/source/blender/gpu/intern/gpu_shader_private.h
+++ b/source/blender/gpu/intern/gpu_shader_private.h
@@ -18,8 +18,7 @@
* \ingroup gpu
*/
-#ifndef __GPU_SHADER_PRIVATE_H__
-#define __GPU_SHADER_PRIVATE_H__
+#pragma once
#include "GPU_shader_interface.h"
@@ -53,5 +52,3 @@ GPUShader *immGetShader(void);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_SHADER_PRIVATE_H__ */
diff --git a/source/blender/gpu/intern/gpu_vertex_format_private.h b/source/blender/gpu/intern/gpu_vertex_format_private.h
index 7b560a35bd0..45523c0e956 100644
--- a/source/blender/gpu/intern/gpu_vertex_format_private.h
+++ b/source/blender/gpu/intern/gpu_vertex_format_private.h
@@ -23,8 +23,7 @@
* GPU vertex format
*/
-#ifndef __GPU_VERTEX_FORMAT_PRIVATE_H__
-#define __GPU_VERTEX_FORMAT_PRIVATE_H__
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -38,5 +37,3 @@ GLenum convert_comp_type_to_gl(GPUVertCompType type);
#ifdef __cplusplus
}
#endif
-
-#endif /* __GPU_VERTEX_FORMAT_PRIVATE_H__ */