Culled D bindings for header-only C++ functions (#3130)

* Reformatted comments; fixed a couple of oversights

* D bindings: deterministic sub-struct order

* Added missing default to IDL

* Fixed sub-struct linkage; regenerate D binds

* Culled D bindings for header-only C++ functions

* Added missing default to bgfx.idl

* cppinline now supported by all auto-gen bindings

The pattern "func.cppinline and not func.conly" is to make sure that C bindings for `bgfx_vertex_layout_has` are still generated.
This commit is contained in:
IchorDev
2023-07-20 10:53:42 +07:00
committed by GitHub
parent faf69bbe20
commit 878767e751
8 changed files with 16 additions and 34 deletions

View File

@@ -1357,13 +1357,6 @@ extern(C++, "bgfx") struct VertexLayout{
*/
[q{void}, q{decode}, q{bgfx.fakeenum.Attrib.Enum attrib, ref ubyte num, ref bgfx.fakeenum.AttribType.Enum type, ref bool normalized, ref bool asInt}, `C++`, q{const}],
/**
Returns `true` if VertexLayout contains attribute.
Params:
attrib = Attribute semantics. See: `bgfx::Attrib`
*/
[q{bool}, q{has}, q{bgfx.fakeenum.Attrib.Enum attrib}, `C++`, q{const}],
/**
Skip `_num` bytes in vertex stream.
Params:
@@ -1375,25 +1368,6 @@ extern(C++, "bgfx") struct VertexLayout{
End VertexLayout.
*/
[q{void}, q{end}, q{}, `C++`],
/**
Returns relative attribute offset from the vertex.
Params:
attrib = Attribute semantics. See: `bgfx::Attrib`
*/
[q{ushort}, q{getOffset}, q{bgfx.fakeenum.Attrib.Enum attrib}, `C++`, q{const}],
/**
Returns vertex stride.
*/
[q{ushort}, q{getStride}, q{}, `C++`, q{const}],
/**
Returns size of vertex buffer for number of vertices.
Params:
num = Number of vertices.
*/
[q{uint}, q{getSize}, q{uint num}, `C++`, q{const}],
], true);
return ret;
}(), typeof(this).stringof));
@@ -1487,7 +1461,7 @@ extern(C++, "bgfx") struct Encoder{
mtx = Pointer to first matrix in array.
num = Number of matrices in array.
*/
[q{uint}, q{setTransform}, q{const(void)* mtx, ushort num}, `C++`],
[q{uint}, q{setTransform}, q{const(void)* mtx, ushort num=1}, `C++`],
/**
Set model matrix from matrix cache for draw primitive.