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
path: root/intern
diff options
context:
space:
mode:
authorMike Erwin <significant.bit@gmail.com>2017-04-16 18:21:45 +0300
committerMike Erwin <significant.bit@gmail.com>2017-04-16 18:21:45 +0300
commitbf441fcfacc1648cb5aff87dafd1e5f0098e3d2b (patch)
tree297f0152c2962b8b20aee22887ccfb50135c29b0 /intern
parent4a41bc8ceac72f6f7be3067857c0ec35db5a039a (diff)
Gawain: move AttribBinding funcs to private interface
Other parts of Gawain uses these internally, but they're not part of the public API. Part of T51219
Diffstat (limited to 'intern')
-rw-r--r--intern/gawain/gawain/attrib_binding.h8
-rw-r--r--intern/gawain/gawain/attrib_binding_private.h20
-rw-r--r--intern/gawain/src/attrib_binding.c1
-rw-r--r--intern/gawain/src/immediate.c3
4 files changed, 24 insertions, 8 deletions
diff --git a/intern/gawain/gawain/attrib_binding.h b/intern/gawain/gawain/attrib_binding.h
index 0642492882a..8c372c81cc7 100644
--- a/intern/gawain/gawain/attrib_binding.h
+++ b/intern/gawain/gawain/attrib_binding.h
@@ -11,15 +11,9 @@
#pragma once
-#include "vertex_format.h"
-#include "shader_interface.h"
+#include "common.h"
typedef struct {
uint64_t loc_bits; // store 4 bits for each of the 16 attribs
uint16_t enabled_bits; // 1 bit for each attrib
} AttribBinding;
-
-void AttribBinding_clear(AttribBinding*);
-
-void get_attrib_locations(const VertexFormat*, AttribBinding*, const ShaderInterface*);
-unsigned read_attrib_location(const AttribBinding*, unsigned a_idx);
diff --git a/intern/gawain/gawain/attrib_binding_private.h b/intern/gawain/gawain/attrib_binding_private.h
new file mode 100644
index 00000000000..c9b7a3f2c01
--- /dev/null
+++ b/intern/gawain/gawain/attrib_binding_private.h
@@ -0,0 +1,20 @@
+
+// Gawain vertex attribute binding
+//
+// This code is part of the Gawain library, with modifications
+// specific to integration with Blender.
+//
+// Copyright 2017 Mike Erwin
+//
+// This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of
+// the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/.
+
+#pragma once
+
+#include "vertex_format.h"
+#include "shader_interface.h"
+
+void AttribBinding_clear(AttribBinding*);
+
+void get_attrib_locations(const VertexFormat*, AttribBinding*, const ShaderInterface*);
+unsigned read_attrib_location(const AttribBinding*, unsigned a_idx);
diff --git a/intern/gawain/src/attrib_binding.c b/intern/gawain/src/attrib_binding.c
index 8a7fe3df66c..10df9b9d333 100644
--- a/intern/gawain/src/attrib_binding.c
+++ b/intern/gawain/src/attrib_binding.c
@@ -10,6 +10,7 @@
// the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/.
#include "attrib_binding.h"
+#include "attrib_binding_private.h"
#include <stddef.h>
#if MAX_VERTEX_ATTRIBS != 16
diff --git a/intern/gawain/src/immediate.c b/intern/gawain/src/immediate.c
index 8c42ed54f75..6c237a27067 100644
--- a/intern/gawain/src/immediate.c
+++ b/intern/gawain/src/immediate.c
@@ -10,8 +10,9 @@
// the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/.
#include "immediate.h"
-#include "attrib_binding.h"
#include "buffer_id.h"
+#include "attrib_binding.h"
+#include "attrib_binding_private.h"
#include "vertex_format_private.h"
#include <string.h>