31 #include "scriptstdstring/scriptstdstring.h"
32 #include "scriptmath/scriptmath.h"
33 #include "scriptany/scriptany.h"
34 #include "scriptarray/scriptarray.h"
35 #include "scripthelper/scripthelper.h"
38 #include <OgreRenderOperation.h>
40 #include <Overlay/OgreOverlaySystem.h>
41 #include <Overlay/OgreOverlayManager.h>
42 #include <Overlay/OgreOverlay.h>
43 #include <Overlay/OgreOverlayContainer.h>
46 using namespace AngelScript;
59 new(
self) Vector3(other);
64 new(
self) Vector3(
x,
y,
z);
69 new(
self) Vector3(s, s, s);
80 new(
self) Vector2(other);
85 new(
self) Vector2(
x,
y);
90 new(
self) Vector2(s, s);
94 static int Vector3Cmp(
const Vector3& a,
const Vector3& b)
118 new(
self) Radian(other);
144 new(
self) Degree(other);
165 new(
self) Quaternion();
170 new(
self) Quaternion(other.w, other.x, other.y, other.z);
175 new(
self) Quaternion(rfAngle, rkAxis);
180 new(
self) Quaternion(
w,
x,
y,
z);
185 new(
self) Quaternion(xaxis, yaxis, zaxis);
191 new(
self) Quaternion((Ogre::Real *)&val);
196 new(
self) Quaternion(s, s, s, s);
202 new(
self) ColourValue();
207 new(
self) ColourValue(r,g,b,a);
212 new(
self) ColourValue(other.r, other.g, other.b, other.a);
223 new(
self) Box(l, t, r, b);
228 new(
self) Box(other);
238 (
self)->
operator=(other);
244 new (
self) TexturePtr();
249 new (
self) TexturePtr(other);
254 (
self)->~TexturePtr();
259 (
self)->
operator=(other);
264 return !(
self)->
operator bool();
271 new (
self) HardwarePixelBufferSharedPtr();
276 new (
self) HardwarePixelBufferSharedPtr(other);
281 (
self)->~HardwarePixelBufferSharedPtr();
286 (
self)->
operator=(other);
292 new (
self) PixelBox();
297 new (
self) PixelBox(other);
307 (
self)->
operator=(other);
318 new (
self) Image(other);
328 (
self)->
operator=(other);
341 new (
self) MeshPtr();
346 new (
self) MeshPtr(other);
356 (
self)->
operator=(other);
361 return !(
self)->
operator bool();
367 VertexData* vertData = (
self->useSharedVertices) ? self->parent->sharedVertexData : self->vertexData;
373 const Ogre::VertexElement* posElem = vertData->vertexDeclaration->findElementBySemantic(Ogre::VES_POSITION);
379 Ogre::HardwareVertexBufferSharedPtr vbuf = vertData->vertexBufferBinding->getBuffer(posElem->getSource());
386 AngelScript::CScriptArray* arr = AngelScript::CScriptArray::Create(typeinfo, vertData->vertexCount);
387 uint8_t* pStart =
static_cast<uint8_t*
>(vbuf->lock(Ogre::HardwareBuffer::HBL_READ_ONLY));
388 for (
size_t i = 0; i < vertData->vertexCount; i++)
390 uint8_t* pVert = pStart + (i * vertData->vertexDeclaration->getVertexSize(posElem->getSource()));
391 float* pPos =
nullptr;
392 posElem->baseVertexPointerToElement(pVert, &pPos);
393 Vector3 pos(*pPos, *(pPos+1), *(pPos+2));
394 arr->SetValue(i, &pos);
402 VertexData* vertData = (
self->useSharedVertices) ? self->parent->sharedVertexData : self->vertexData;
408 const Ogre::VertexElement* texcoordElem = vertData->vertexDeclaration->findElementBySemantic(Ogre::VES_TEXTURE_COORDINATES, (
unsigned short)index);
414 Ogre::HardwareVertexBufferSharedPtr vbuf = vertData->vertexBufferBinding->getBuffer(texcoordElem->getSource());
421 AngelScript::CScriptArray* arr = AngelScript::CScriptArray::Create(typeinfo, vertData->vertexCount);
422 uint8_t* pStart =
static_cast<uint8_t*
>(vbuf->lock(Ogre::HardwareBuffer::HBL_READ_ONLY));
423 const size_t vertSize = vertData->vertexDeclaration->getVertexSize(texcoordElem->getSource());
424 ROR_ASSERT(texcoordElem->getType() == Ogre::VET_FLOAT2);
425 for (
size_t i = 0; i < vertData->vertexCount; i++)
427 uint8_t* pVert = pStart + ((i + vertData->vertexStart) * vertSize);
428 float* pTexcoord =
nullptr;
429 texcoordElem->baseVertexPointerToElement(pVert, &pTexcoord);
430 Vector2 texcoord(*pTexcoord, *(pTexcoord+1));
431 arr->SetValue(i, &texcoord);
439 if (!self->indexData)
442 return Ogre::HardwareIndexBuffer::IT_16BIT;
444 Ogre::HardwareIndexBufferSharedPtr ibuf =
self->indexData->indexBuffer;
448 return Ogre::HardwareIndexBuffer::IT_16BIT;
450 return ibuf->getType();
455 if (!self->indexData)
460 Ogre::HardwareIndexBufferSharedPtr ibuf =
self->indexData->indexBuffer;
466 if (ibuf->getType() != desiredType)
472 AngelScript::CScriptArray* arr = AngelScript::CScriptArray::Create(typeinfo, self->indexData->indexCount);
473 uint8_t* pStart =
static_cast<uint8_t*
>(ibuf->lock(Ogre::HardwareBuffer::HBL_READ_ONLY));
474 for (
size_t i = self->indexData->indexStart; i < self->indexData->indexCount; i++)
476 uint8_t* pIndex = pStart + (i * ibuf->getIndexSize());
477 if (ibuf->getType() == Ogre::HardwareIndexBuffer::IT_16BIT)
479 uint16_t index = *
reinterpret_cast<uint16_t*
>(pIndex);
480 arr->SetValue(i, &index);
482 else if (ibuf->getType() == Ogre::HardwareIndexBuffer::IT_32BIT)
484 uint32_t index = *
reinterpret_cast<uint32_t*
>(pIndex);
485 arr->SetValue(i, &index);
508 return fmt::format(
"\"{}\" ({})", self->getName(),
static_cast<void*
>(
self));
523 return fmt::format(
"\"{}\" ({} {})", self->getName(), self->getMovableType(),
static_cast<void*
>(
self));
552 new (
self) MaterialPtr();
557 new (
self) MaterialPtr(other);
562 (
self)->~MaterialPtr();
567 (
self)->
operator=(other);
572 return !(
self)->
operator bool();
612 new(
self) Timer(other);
617 (
self)->
operator=(other);
623 new (
self) GpuProgramParametersPtr();
628 new (
self) GpuProgramParametersPtr(other);
633 (
self)->~GpuProgramParametersPtr();
638 (
self)->
operator=(other);
643 return !(
self)->
operator bool();
690 r = engine->RegisterObjectType(
"degree",
sizeof(Degree), asOBJ_VALUE | asOBJ_POD | asOBJ_APP_CLASS_CA | asOBJ_APP_CLASS_ALLFLOATS);
694 r = engine->RegisterObjectType(
"radian",
sizeof(Radian), asOBJ_VALUE | asOBJ_POD | asOBJ_APP_CLASS_CA | asOBJ_APP_CLASS_ALLFLOATS);
698 r = engine->RegisterObjectType(
"vector2",
sizeof(Vector2), asOBJ_VALUE | asOBJ_POD | asOBJ_APP_CLASS_CA | asOBJ_APP_CLASS_ALLFLOATS);
702 r = engine->RegisterObjectType(
"vector3",
sizeof(Vector3), asOBJ_VALUE | asOBJ_POD | asOBJ_APP_CLASS_CA | asOBJ_APP_CLASS_ALLFLOATS);
706 r = engine->RegisterObjectType(
"quaternion",
sizeof(Quaternion), asOBJ_VALUE | asOBJ_POD | asOBJ_APP_CLASS_CA | asOBJ_APP_CLASS_ALLFLOATS);
710 r = engine->RegisterObjectType(
"color",
sizeof(ColourValue), asOBJ_VALUE | asOBJ_POD | asOBJ_APP_CLASS_CA | asOBJ_APP_CLASS_ALLFLOATS);
714 r = engine->RegisterObjectType(
"box",
sizeof(Box), asOBJ_VALUE | asOBJ_POD | asOBJ_APP_CLASS_CA | asOBJ_APP_CLASS_ALLINTS);
719 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
721 r = engine->RegisterObjectType(
"MovableObject",
sizeof(MovableObject), asOBJ_REF | asOBJ_NOCOUNT);
724 r = engine->RegisterObjectType(
"Entity",
sizeof(Entity), asOBJ_REF | asOBJ_NOCOUNT);
727 r = engine->RegisterObjectType(
"SubEntity",
sizeof(Entity), asOBJ_REF | asOBJ_NOCOUNT);
730 r = engine->RegisterObjectType(
"Node",
sizeof(Node), asOBJ_REF | asOBJ_NOCOUNT);
733 r = engine->RegisterObjectType(
"SceneNode",
sizeof(SceneNode), asOBJ_REF | asOBJ_NOCOUNT);
736 r = engine->RegisterObjectType(
"SceneManager",
sizeof(SceneManager), asOBJ_REF | asOBJ_NOCOUNT);
739 r = engine->RegisterObjectType(
"Root",
sizeof(Root), asOBJ_REF | asOBJ_NOCOUNT);
742 r = engine->RegisterObjectType(
"AnimationState",
sizeof(Root), asOBJ_REF | asOBJ_NOCOUNT);
745 r = engine->RegisterObjectType(
"AnimationStateSet",
sizeof(Root), asOBJ_REF | asOBJ_NOCOUNT);
748 r = engine->RegisterObjectType(
"TexturePtr",
sizeof(TexturePtr), asOBJ_VALUE | asGetTypeTraits<TexturePtr>());
751 r = engine->RegisterObjectType(
"TextureManager",
sizeof(TextureManager), asOBJ_REF | asOBJ_NOCOUNT);
754 r = engine->RegisterObjectType(
"ManualObject",
sizeof(TextureManager), asOBJ_REF | asOBJ_NOCOUNT);
757 r = engine->RegisterObjectType(
"Image",
sizeof(Image), asOBJ_VALUE | asGetTypeTraits<Image>());
761 r = engine->RegisterObjectType(
"HardwarePixelBufferPtr",
sizeof(HardwarePixelBufferSharedPtr), asOBJ_VALUE | asGetTypeTraits<HardwarePixelBufferSharedPtr>());
764 r = engine->RegisterObjectType(
"PixelBox",
sizeof(PixelBox), asOBJ_VALUE | asGetTypeTraits<PixelBox>());
767 r = engine->RegisterObjectType(
"MeshPtr",
sizeof(MeshPtr), asOBJ_VALUE | asGetTypeTraits<TexturePtr>());
770 r = engine->RegisterObjectType(
"SubMesh",
sizeof(SubMesh), asOBJ_REF | asOBJ_NOCOUNT);
773 r = engine->RegisterObjectType(
"MeshManager",
sizeof(TextureManager), asOBJ_REF | asOBJ_NOCOUNT);
776 r = engine->RegisterObjectType(
"MaterialManager",
sizeof(MaterialManager), asOBJ_REF | asOBJ_NOCOUNT);
779 r = engine->RegisterObjectType(
"MaterialPtr",
sizeof(MeshPtr), asOBJ_VALUE | asGetTypeTraits<TexturePtr>());
782 r = engine->RegisterObjectType(
"Technique",
sizeof(SubMesh), asOBJ_REF | asOBJ_NOCOUNT);
785 r = engine->RegisterObjectType(
"Pass",
sizeof(SubMesh), asOBJ_REF | asOBJ_NOCOUNT);
788 r = engine->RegisterObjectType(
"TextureUnitState",
sizeof(SubMesh), asOBJ_REF | asOBJ_NOCOUNT);
791 r = engine->RegisterObjectType(
"Timer",
sizeof(Timer), asOBJ_VALUE | asGetTypeTraits<Timer>());
794 r = engine->RegisterObjectType(
"GpuProgramParametersPtr",
sizeof(GpuProgramParametersPtr), asOBJ_VALUE | asGetTypeTraits<GpuProgramParametersPtr>());
811 r = engine->RegisterEnum(
"IndexType");
ROR_ASSERT(r >= 0);
812 r = engine->RegisterEnumValue(
"IndexType",
"IT_16BIT", Ogre::HardwareIndexBuffer::IT_16BIT);
ROR_ASSERT(r >= 0);
813 r = engine->RegisterEnumValue(
"IndexType",
"IT_32BIT", Ogre::HardwareIndexBuffer::IT_32BIT);
ROR_ASSERT(r >= 0);
815 r = engine->RegisterEnum(
"TransformSpace");
ROR_ASSERT(r >= 0);
816 r = engine->RegisterEnumValue(
"TransformSpace",
"TS_LOCAL", Node::TS_LOCAL);
ROR_ASSERT(r >= 0);
817 r = engine->RegisterEnumValue(
"TransformSpace",
"TS_PARENT", Node::TS_PARENT);
ROR_ASSERT(r >= 0);
818 r = engine->RegisterEnumValue(
"TransformSpace",
"TS_WORLD", Node::TS_WORLD);
ROR_ASSERT(r >= 0);
820 r = engine->RegisterEnum(
"RenderOperation");
ROR_ASSERT(r >= 0);
821 r = engine->RegisterEnumValue(
"RenderOperation",
"OT_POINT_LIST", Ogre::RenderOperation::OT_POINT_LIST);
ROR_ASSERT(r >= 0);
822 r = engine->RegisterEnumValue(
"RenderOperation",
"OT_LINE_LIST", Ogre::RenderOperation::OT_LINE_LIST);
ROR_ASSERT(r >= 0);
823 r = engine->RegisterEnumValue(
"RenderOperation",
"OT_LINE_STRIP", Ogre::RenderOperation::OT_LINE_STRIP);
ROR_ASSERT(r >= 0);
824 r = engine->RegisterEnumValue(
"RenderOperation",
"OT_TRIANGLE_LIST", Ogre::RenderOperation::OT_TRIANGLE_LIST);
ROR_ASSERT(r >= 0);
825 r = engine->RegisterEnumValue(
"RenderOperation",
"OT_TRIANGLE_STRIP", Ogre::RenderOperation::OT_TRIANGLE_STRIP);
ROR_ASSERT(r >= 0);
826 r = engine->RegisterEnumValue(
"RenderOperation",
"OT_TRIANGLE_FAN", Ogre::RenderOperation::OT_TRIANGLE_FAN);
ROR_ASSERT(r >= 0);
828 r = engine->RegisterEnum(
"ImageFilter");
ROR_ASSERT(r >= 0);
829 r = engine->RegisterEnumValue(
"ImageFilter",
"FILTER_NEAREST", Image::Filter::FILTER_NEAREST);
ROR_ASSERT(r >= 0);
830 r = engine->RegisterEnumValue(
"ImageFilter",
"FILTER_LINEAR", Image::Filter::FILTER_LINEAR);
ROR_ASSERT(r >= 0);
831 r = engine->RegisterEnumValue(
"ImageFilter",
"FILTER_BILINEAR", Image::Filter::FILTER_BILINEAR);
ROR_ASSERT(r >= 0);
833 r = engine->RegisterEnum(
"HardwareBufferLockOptions");
ROR_ASSERT(r >= 0);
834 r = engine->RegisterEnumValue(
"HardwareBufferLockOptions",
"HBL_NORMAL", HardwareBuffer::LockOptions::HBL_NORMAL);
ROR_ASSERT(r >= 0);
835 r = engine->RegisterEnumValue(
"HardwareBufferLockOptions",
"HBL_DISCARD", HardwareBuffer::LockOptions::HBL_DISCARD);
ROR_ASSERT(r >= 0);
836 r = engine->RegisterEnumValue(
"HardwareBufferLockOptions",
"HBL_READ_ONLY", HardwareBuffer::LockOptions::HBL_READ_ONLY);
ROR_ASSERT(r >= 0);
837 r = engine->RegisterEnumValue(
"HardwareBufferLockOptions",
"HBL_NO_OVERWRITE", HardwareBuffer::LockOptions::HBL_NO_OVERWRITE);
ROR_ASSERT(r >= 0);
838 r = engine->RegisterEnumValue(
"HardwareBufferLockOptions",
"HBL_WRITE_ONLY", HardwareBuffer::LockOptions::HBL_WRITE_ONLY);
ROR_ASSERT(r >= 0);
840 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
882 r = engine->RegisterObjectMethod(
"Ogre::Node",
"Ogre::SceneNode@ opCast()", asFUNCTION((ScriptRefCastNoCount<Ogre::Node, Ogre::SceneNode>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
883 r = engine->RegisterObjectMethod(
"Ogre::SceneNode",
"Ogre::Node@ opImplCast()", asFUNCTION((ScriptRefCastNoCount<Ogre::SceneNode, Ogre::Node>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
885 r = engine->RegisterObjectMethod(
"Ogre::MovableObject",
"Ogre::Entity@ opCast()", asFUNCTION((ScriptRefCastNoCount<Ogre::MovableObject, Ogre::Entity>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
886 r = engine->RegisterObjectMethod(
"Ogre::Entity",
"Ogre::MovableObject@ opImplCast()", asFUNCTION((ScriptRefCastNoCount<Ogre::Entity, Ogre::MovableObject>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
888 r = engine->RegisterObjectMethod(
"Ogre::MovableObject",
"Ogre::ManualObject@ opCast()", asFUNCTION((ScriptRefCastNoCount<Ogre::MovableObject, Ogre::ManualObject>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
889 r = engine->RegisterObjectMethod(
"Ogre::ManualObject",
"Ogre::MovableObject@ opImplCast()", asFUNCTION((ScriptRefCastNoCount<Ogre::ManualObject, Ogre::MovableObject>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
895 r = engine->RegisterObjectMethod(
"Ogre::Node",
"const Ogre::SceneNode@ opCast() const", asFUNCTION((ScriptRefCastNoCount<Ogre::Node, Ogre::SceneNode>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
896 r = engine->RegisterObjectMethod(
"Ogre::SceneNode",
"const Ogre::Node@ opImplCast() const", asFUNCTION((ScriptRefCastNoCount<Ogre::SceneNode, Ogre::Node>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
898 r = engine->RegisterObjectMethod(
"Ogre::MovableObject",
"const Ogre::Entity@ opCast() const", asFUNCTION((ScriptRefCastNoCount<Ogre::MovableObject, Ogre::Entity>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
899 r = engine->RegisterObjectMethod(
"Ogre::Entity",
"const Ogre::MovableObject@ opImplCast() const", asFUNCTION((ScriptRefCastNoCount<Ogre::Entity, Ogre::MovableObject>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
901 r = engine->RegisterObjectMethod(
"Ogre::MovableObject",
"const Ogre::ManualObject@ opCast() const", asFUNCTION((ScriptRefCastNoCount<Ogre::MovableObject, Ogre::ManualObject>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
902 r = engine->RegisterObjectMethod(
"Ogre::ManualObject",
"const Ogre::MovableObject@ opImplCast() const", asFUNCTION((ScriptRefCastNoCount<Ogre::ManualObject, Ogre::MovableObject>)), asCALL_CDECL_OBJLAST); assert(r >= 0);
912 r = engine->RegisterObjectProperty(
"vector3",
"float x", offsetof(Ogre::Vector3,
x));
914 r = engine->RegisterObjectProperty(
"vector3",
"float y", offsetof(Ogre::Vector3,
y));
916 r = engine->RegisterObjectProperty(
"vector3",
"float z", offsetof(Ogre::Vector3,
z));
920 r = engine->RegisterObjectBehaviour(
"vector3", asBEHAVE_CONSTRUCT,
"void f()", asFUNCTION(
Vector3DefaultConstructor), asCALL_CDECL_OBJLAST);
922 r = engine->RegisterObjectBehaviour(
"vector3", asBEHAVE_CONSTRUCT,
"void f(float, float, float)", asFUNCTION(
Vector3InitConstructor), asCALL_CDECL_OBJLAST);
924 r = engine->RegisterObjectBehaviour(
"vector3", asBEHAVE_CONSTRUCT,
"void f(const vector3 &in)", asFUNCTION(
Vector3CopyConstructor), asCALL_CDECL_OBJLAST);
926 r = engine->RegisterObjectBehaviour(
"vector3", asBEHAVE_CONSTRUCT,
"void f(float)", asFUNCTION(
Vector3InitConstructorScaler), asCALL_CDECL_OBJLAST);
930 r = engine->RegisterObjectMethod(
"vector3",
"float opIndex(int) const", asMETHODPR(Vector3,
operator[], (
size_t)
const,
float), asCALL_THISCALL);
932 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &f(const vector3 &in)", asMETHODPR(Vector3,
operator =, (
const Vector3 &), Vector3&), asCALL_THISCALL);
934 r = engine->RegisterObjectMethod(
"vector3",
"bool opEquals(const vector3 &in) const", asMETHODPR(Vector3,
operator==,(
const Vector3&)
const,
bool), asCALL_THISCALL);
937 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opAdd(const vector3 &in) const", asMETHODPR(Vector3,
operator+,(
const Vector3&)
const, Vector3), asCALL_THISCALL);
939 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opSub(const vector3 &in) const", asMETHODPR(Vector3,
operator-,(
const Vector3&)
const, Vector3), asCALL_THISCALL);
942 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opMul(float) const", asMETHODPR(Vector3,
operator*,(
const float)
const, Vector3), asCALL_THISCALL);
944 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opMul(const vector3 &in) const", asMETHODPR(Vector3,
operator*,(
const Vector3&)
const, Vector3), asCALL_THISCALL);
946 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opDiv(float) const", asMETHODPR(Vector3,
operator/,(
const float)
const, Vector3), asCALL_THISCALL);
948 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opDiv(const vector3 &in) const", asMETHODPR(Vector3,
operator/,(
const Vector3&)
const, Vector3), asCALL_THISCALL);
951 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opAdd() const", asMETHODPR(Vector3,
operator+,()
const,
const Vector3&), asCALL_THISCALL);
953 r = engine->RegisterObjectMethod(
"vector3",
"vector3 opSub() const", asMETHODPR(Vector3,
operator-,()
const, Vector3), asCALL_THISCALL);
958 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opAddAssign(const vector3 &in)", asMETHODPR(Vector3,
operator+=,(
const Vector3 &),Vector3&), asCALL_THISCALL);
960 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opAddAssign(float)", asMETHODPR(Vector3,
operator+=,(
const float),Vector3&), asCALL_THISCALL);
963 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opSubAssign(const vector3 &in)", asMETHODPR(Vector3,
operator-=,(
const Vector3 &),Vector3&), asCALL_THISCALL);
965 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opSubAssign(float)", asMETHODPR(Vector3,
operator-=,(
const float),Vector3&), asCALL_THISCALL);
968 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opMulAssign(const vector3 &in)", asMETHODPR(Vector3,
operator*=,(
const Vector3 &),Vector3&), asCALL_THISCALL);
970 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opMulAssign(float)", asMETHODPR(Vector3,
operator*=,(
const float),Vector3&), asCALL_THISCALL);
975 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opDivAssign(const vector3 &in)", asMETHODPR(Vector3,
operator/=,(
const Vector3 &),Vector3&), asCALL_THISCALL);
977 r = engine->RegisterObjectMethod(
"vector3",
"vector3 &opDivAssign(float)", asMETHODPR(Vector3,
operator/=,(
const float),Vector3&), asCALL_THISCALL);
985 r = engine->RegisterObjectMethod(
"vector3",
"float length() const", asMETHOD(Vector3,length), asCALL_THISCALL);
987 r = engine->RegisterObjectMethod(
"vector3",
"float squaredLength() const", asMETHOD(Vector3,squaredLength), asCALL_THISCALL);
990 r = engine->RegisterObjectMethod(
"vector3",
"float distance(const vector3 &in) const", asMETHOD(Vector3,distance), asCALL_THISCALL);
992 r = engine->RegisterObjectMethod(
"vector3",
"float squaredDistance(const vector3 &in) const", asMETHOD(Vector3,squaredDistance), asCALL_THISCALL);
995 r = engine->RegisterObjectMethod(
"vector3",
"float dotProduct(const vector3 &in) const", asMETHOD(Vector3,dotProduct), asCALL_THISCALL);
997 r = engine->RegisterObjectMethod(
"vector3",
"float absDotProduct(const vector3 &in) const", asMETHOD(Vector3,absDotProduct), asCALL_THISCALL);
1000 r = engine->RegisterObjectMethod(
"vector3",
"float normalise()", asMETHOD(Vector3,
normalise), asCALL_THISCALL);
1002 r = engine->RegisterObjectMethod(
"vector3",
"float crossProduct(const vector3 &in) const", asMETHOD(Vector3,crossProduct), asCALL_THISCALL);
1004 r = engine->RegisterObjectMethod(
"vector3",
"vector3 midPoint(const vector3 &in) const", asMETHOD(Vector3,midPoint), asCALL_THISCALL);
1006 r = engine->RegisterObjectMethod(
"vector3",
"void makeFloor(const vector3 &in)", asMETHOD(Vector3,makeFloor), asCALL_THISCALL);
1008 r = engine->RegisterObjectMethod(
"vector3",
"void makeCeil(const vector3 &in)", asMETHOD(Vector3,makeCeil), asCALL_THISCALL);
1010 r = engine->RegisterObjectMethod(
"vector3",
"vector3 perpendicular() const", asMETHOD(Vector3,perpendicular), asCALL_THISCALL);
1012 r = engine->RegisterObjectMethod(
"vector3",
"vector3 randomDeviant(const radian &in, const vector3 &in) const", asMETHOD(Vector3,randomDeviant), asCALL_THISCALL);
1014 r = engine->RegisterObjectMethod(
"vector3",
"radian angleBetween(const vector3 &in)", asMETHOD(Vector3,angleBetween), asCALL_THISCALL);
1016 r = engine->RegisterObjectMethod(
"vector3",
"quaternion getRotationTo(const vector3 &in, const vector3 &in) const", asMETHOD(Vector3,getRotationTo), asCALL_THISCALL);
1018 r = engine->RegisterObjectMethod(
"vector3",
"bool isZeroLength() const", asMETHOD(Vector3,isZeroLength), asCALL_THISCALL);
1020 r = engine->RegisterObjectMethod(
"vector3",
"vector3 normalisedCopy() const", asMETHOD(Vector3,normalisedCopy), asCALL_THISCALL);
1022 r = engine->RegisterObjectMethod(
"vector3",
"vector3 reflect(const vector3 &in) const", asMETHOD(Vector3,reflect), asCALL_THISCALL);
1025 r = engine->RegisterObjectMethod(
"vector3",
"bool positionEquals(const vector3 &in, float) const", asMETHOD(Vector3,positionEquals), asCALL_THISCALL);
1027 r = engine->RegisterObjectMethod(
"vector3",
"bool positionCloses(const vector3 &in, float) const", asMETHOD(Vector3,positionCloses), asCALL_THISCALL);
1029 r = engine->RegisterObjectMethod(
"vector3",
"bool directionEquals(const vector3 &in, radian &in) const", asMETHOD(Vector3,directionEquals), asCALL_THISCALL);
1032 r = engine->RegisterObjectMethod(
"vector3",
"bool isNaN() const", asMETHOD(Vector3,
isNaN), asCALL_THISCALL);
1043 r = engine->RegisterObjectProperty(
"vector2",
"float x", offsetof(Ogre::Vector2,
x));
1045 r = engine->RegisterObjectProperty(
"vector2",
"float y", offsetof(Ogre::Vector2,
y));
1049 r = engine->RegisterObjectBehaviour(
"vector2", asBEHAVE_CONSTRUCT,
"void f()", asFUNCTION(
Vector2DefaultConstructor), asCALL_CDECL_OBJLAST);
1051 r = engine->RegisterObjectBehaviour(
"vector2", asBEHAVE_CONSTRUCT,
"void f(float, float)", asFUNCTION(
Vector2InitConstructor), asCALL_CDECL_OBJLAST);
1053 r = engine->RegisterObjectBehaviour(
"vector2", asBEHAVE_CONSTRUCT,
"void f(const vector2 &in)", asFUNCTION(
Vector2CopyConstructor), asCALL_CDECL_OBJLAST);
1055 r = engine->RegisterObjectBehaviour(
"vector2", asBEHAVE_CONSTRUCT,
"void f(float)", asFUNCTION(
Vector2InitConstructorScaler), asCALL_CDECL_OBJLAST);
1059 r = engine->RegisterObjectMethod(
"vector2",
"float opIndex(int) const", asMETHODPR(Vector2,
operator[], (
size_t)
const,
float), asCALL_THISCALL);
1061 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &f(const vector2 &in)", asMETHODPR(Vector2,
operator =, (
const Vector2 &), Vector2&), asCALL_THISCALL);
1063 r = engine->RegisterObjectMethod(
"vector2",
"bool opEquals(const vector2 &in) const", asMETHODPR(Vector2,
operator==,(
const Vector2&)
const,
bool), asCALL_THISCALL);
1066 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opAdd(const vector2 &in) const", asMETHODPR(Vector2,
operator+,(
const Vector2&)
const, Vector2), asCALL_THISCALL);
1068 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opSub(const vector2 &in) const", asMETHODPR(Vector2,
operator-,(
const Vector2&)
const, Vector2), asCALL_THISCALL);
1071 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opMul(float) const", asMETHODPR(Vector2,
operator*,(
const float)
const, Vector2), asCALL_THISCALL);
1073 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opMul(const vector2 &in) const", asMETHODPR(Vector2,
operator*,(
const Vector2&)
const, Vector2), asCALL_THISCALL);
1075 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opDiv(float) const", asMETHODPR(Vector2,
operator/,(
const float)
const, Vector2), asCALL_THISCALL);
1077 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opDiv(const vector2 &in) const", asMETHODPR(Vector2,
operator/,(
const Vector2&)
const, Vector2), asCALL_THISCALL);
1080 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opAdd() const", asMETHODPR(Vector2,
operator+,()
const,
const Vector2&), asCALL_THISCALL);
1082 r = engine->RegisterObjectMethod(
"vector2",
"vector2 opSub() const", asMETHODPR(Vector2,
operator-,()
const, Vector2), asCALL_THISCALL);
1085 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opAddAssign(const vector2 &in)", asMETHODPR(Vector2,
operator+=,(
const Vector2 &),Vector2&), asCALL_THISCALL);
1087 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opAddAssign(float)", asMETHODPR(Vector2,
operator+=,(
const float),Vector2&), asCALL_THISCALL);
1090 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opSubAssign(const vector2 &in)", asMETHODPR(Vector2,
operator-=,(
const Vector2 &),Vector2&), asCALL_THISCALL);
1092 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opSubAssign(float)", asMETHODPR(Vector2,
operator-=,(
const float),Vector2&), asCALL_THISCALL);
1095 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opMulAssign(const vector2 &in)", asMETHODPR(Vector2,
operator*=,(
const Vector2 &),Vector2&), asCALL_THISCALL);
1097 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opMulAssign(float)", asMETHODPR(Vector2,
operator*=,(
const float),Vector2&), asCALL_THISCALL);
1100 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opDivAssign(const vector2 &in)", asMETHODPR(Vector2,
operator/=,(
const Vector2 &),Vector2&), asCALL_THISCALL);
1102 r = engine->RegisterObjectMethod(
"vector2",
"vector2 &opDivAssign(float)", asMETHODPR(Vector2,
operator/=,(
const float),Vector2&), asCALL_THISCALL);
1107 r = engine->RegisterObjectMethod(
"vector2",
"float length() const", asMETHOD(Vector2,length), asCALL_THISCALL);
1109 r = engine->RegisterObjectMethod(
"vector2",
"float squaredLength() const", asMETHOD(Vector2,squaredLength), asCALL_THISCALL);
1112 r = engine->RegisterObjectMethod(
"vector2",
"float distance(const vector2 &in) const", asMETHOD(Vector2,distance), asCALL_THISCALL);
1114 r = engine->RegisterObjectMethod(
"vector2",
"float squaredDistance(const vector2 &in) const", asMETHOD(Vector2,squaredDistance), asCALL_THISCALL);
1117 r = engine->RegisterObjectMethod(
"vector2",
"float dotProduct(const vector2 &in) const", asMETHOD(Vector2,dotProduct), asCALL_THISCALL);
1120 r = engine->RegisterObjectMethod(
"vector2",
"float normalise()", asMETHOD(Vector2,
normalise), asCALL_THISCALL);
1122 r = engine->RegisterObjectMethod(
"vector2",
"float crossProduct(const vector2 &in) const", asMETHOD(Vector2,crossProduct), asCALL_THISCALL);
1124 r = engine->RegisterObjectMethod(
"vector2",
"vector2 midPoint(const vector2 &in) const", asMETHOD(Vector2,midPoint), asCALL_THISCALL);
1126 r = engine->RegisterObjectMethod(
"vector2",
"void makeFloor(const vector2 &in)", asMETHOD(Vector2,makeFloor), asCALL_THISCALL);
1128 r = engine->RegisterObjectMethod(
"vector2",
"void makeCeil(const vector2 &in)", asMETHOD(Vector2,makeCeil), asCALL_THISCALL);
1130 r = engine->RegisterObjectMethod(
"vector2",
"vector2 perpendicular() const", asMETHOD(Vector2,perpendicular), asCALL_THISCALL);
1132 r = engine->RegisterObjectMethod(
"vector2",
"vector2 randomDeviant(const radian &in, const vector2 &in) const", asMETHOD(Vector2,randomDeviant), asCALL_THISCALL);
1134 r = engine->RegisterObjectMethod(
"vector2",
"radian angleBetween(const vector2 &in)", asMETHOD(Vector2,angleBetween), asCALL_THISCALL);
1136 r = engine->RegisterObjectMethod(
"vector2",
"bool isZeroLength() const", asMETHOD(Vector2,isZeroLength), asCALL_THISCALL);
1138 r = engine->RegisterObjectMethod(
"vector2",
"vector2 normalisedCopy() const", asMETHOD(Vector2,normalisedCopy), asCALL_THISCALL);
1140 r = engine->RegisterObjectMethod(
"vector2",
"vector2 reflect(const vector2 &in) const", asMETHOD(Vector2,reflect), asCALL_THISCALL);
1143 r = engine->RegisterObjectMethod(
"vector2",
"bool positionEquals(const vector2 &in, float) const", asMETHOD(Vector2,positionEquals), asCALL_THISCALL);
1146 r = engine->RegisterObjectMethod(
"vector2",
"bool isNaN() const", asMETHOD(Vector2,
isNaN), asCALL_THISCALL);
1155 r = engine->RegisterObjectBehaviour(
"radian", asBEHAVE_CONSTRUCT,
"void f()", asFUNCTION(
RadianDefaultConstructor), asCALL_CDECL_OBJLAST);
1157 r = engine->RegisterObjectBehaviour(
"radian", asBEHAVE_CONSTRUCT,
"void f(float)", asFUNCTION(
RadianInitConstructor), asCALL_CDECL_OBJLAST);
1159 r = engine->RegisterObjectBehaviour(
"radian", asBEHAVE_CONSTRUCT,
"void f(const radian &in)", asFUNCTION(
RadianCopyConstructor), asCALL_CDECL_OBJLAST);
1171 r = engine->RegisterObjectMethod(
"radian",
"radian &opAssign(const radian &in)", asMETHODPR(Radian,
operator =, (
const Radian &), Radian&), asCALL_THISCALL);
1173 r = engine->RegisterObjectMethod(
"radian",
"radian &opAssign(const float)", asMETHODPR(Radian,
operator =, (
const float &), Radian&), asCALL_THISCALL);
1175 r = engine->RegisterObjectMethod(
"radian",
"radian &opAssign(const degree &in)", asMETHODPR(Radian,
operator =, (
const Degree &), Radian&), asCALL_THISCALL);
1178 r = engine->RegisterObjectMethod(
"radian",
"radian opAdd() const", asMETHODPR(Radian,
operator+,()
const,
const Radian&), asCALL_THISCALL);
1180 r = engine->RegisterObjectMethod(
"radian",
"radian opAdd(const radian &in) const", asMETHODPR(Radian,
operator+,(
const Radian&)
const, Radian), asCALL_THISCALL);
1182 r = engine->RegisterObjectMethod(
"radian",
"radian opAdd(const degree &in) const", asMETHODPR(Radian,
operator+,(
const Degree&)
const, Radian), asCALL_THISCALL);
1185 r = engine->RegisterObjectMethod(
"radian",
"radian &opAddAssign(const radian &in)", asMETHODPR(Radian,
operator+=,(
const Radian &),Radian&), asCALL_THISCALL);
1187 r = engine->RegisterObjectMethod(
"radian",
"radian &opAddAssign(const degree &in)", asMETHODPR(Radian,
operator+=,(
const Degree &),Radian&), asCALL_THISCALL);
1190 r = engine->RegisterObjectMethod(
"radian",
"radian opSub() const", asMETHODPR(Radian,
operator-,()
const, Radian), asCALL_THISCALL);
1192 r = engine->RegisterObjectMethod(
"radian",
"radian opSub(const radian &in) const", asMETHODPR(Radian,
operator-,(
const Radian&)
const, Radian), asCALL_THISCALL);
1194 r = engine->RegisterObjectMethod(
"radian",
"radian opSub(const degree &in) const", asMETHODPR(Radian,
operator-,(
const Degree&)
const, Radian), asCALL_THISCALL);
1197 r = engine->RegisterObjectMethod(
"radian",
"radian &opSubAssign(const radian &in)", asMETHODPR(Radian,
operator-=,(
const Radian &),Radian&), asCALL_THISCALL);
1199 r = engine->RegisterObjectMethod(
"radian",
"radian &opSubAssign(const degree &in)", asMETHODPR(Radian,
operator-=,(
const Degree &),Radian&), asCALL_THISCALL);
1202 r = engine->RegisterObjectMethod(
"radian",
"radian opMul(float) const", asMETHODPR(Radian,
operator*,(
float)
const, Radian), asCALL_THISCALL);
1204 r = engine->RegisterObjectMethod(
"radian",
"radian opMul(const radian &in) const", asMETHODPR(Radian,
operator*,(
const Radian&)
const, Radian), asCALL_THISCALL);
1207 r = engine->RegisterObjectMethod(
"radian",
"radian &opMulAssign(float)", asMETHODPR(Radian,
operator*=,(
float),Radian&), asCALL_THISCALL);
1210 r = engine->RegisterObjectMethod(
"radian",
"radian opDiv(float) const", asMETHODPR(Radian,
operator/,(
float)
const, Radian), asCALL_THISCALL);
1213 r = engine->RegisterObjectMethod(
"radian",
"radian &opDivAssign(float)", asMETHODPR(Radian,
operator*=,(
float),Radian&), asCALL_THISCALL);
1216 r = engine->RegisterObjectMethod(
"radian",
"int opCmp(const radian &in) const", asFUNCTION(
RadianCmp), asCALL_CDECL_OBJFIRST);
1219 r = engine->RegisterObjectMethod(
"radian",
"bool opEquals(const radian &in) const", asMETHODPR(Radian,
operator==,(
const Radian&)
const,
bool), asCALL_THISCALL);
1223 r = engine->RegisterObjectMethod(
"radian",
"float valueDegrees() const", asMETHOD(Radian,valueDegrees), asCALL_THISCALL);
1225 r = engine->RegisterObjectMethod(
"radian",
"float valueRadians() const", asMETHOD(Radian,valueRadians), asCALL_THISCALL);
1227 r = engine->RegisterObjectMethod(
"radian",
"float valueAngleUnits() const", asMETHOD(Radian,valueAngleUnits), asCALL_THISCALL);
1236 r = engine->RegisterObjectBehaviour(
"degree", asBEHAVE_CONSTRUCT,
"void f()", asFUNCTION(
DegreeDefaultConstructor), asCALL_CDECL_OBJLAST);
1238 r = engine->RegisterObjectBehaviour(
"degree", asBEHAVE_CONSTRUCT,
"void f(float)", asFUNCTION(
DegreeInitConstructor), asCALL_CDECL_OBJLAST);
1240 r = engine->RegisterObjectBehaviour(
"degree", asBEHAVE_CONSTRUCT,
"void f(const degree &in)", asFUNCTION(
DegreeCopyConstructor), asCALL_CDECL_OBJLAST);
1252 r = engine->RegisterObjectMethod(
"degree",
"degree &opAssign(const degree &in)", asMETHODPR(Degree,
operator =, (
const Degree &), Degree&), asCALL_THISCALL);
1254 r = engine->RegisterObjectMethod(
"degree",
"degree &opAssign(float)", asMETHODPR(Degree,
operator =, (
const float &), Degree&), asCALL_THISCALL);
1256 r = engine->RegisterObjectMethod(
"degree",
"degree &opAssign(const radian &in)", asMETHODPR(Degree,
operator =, (
const Radian &), Degree&), asCALL_THISCALL);
1259 r = engine->RegisterObjectMethod(
"degree",
"degree opAdd() const", asMETHODPR(Degree,
operator+,()
const,
const Degree&), asCALL_THISCALL);
1261 r = engine->RegisterObjectMethod(
"degree",
"degree opAdd(const degree &in) const", asMETHODPR(Degree,
operator+,(
const Degree&)
const, Degree), asCALL_THISCALL);
1263 r = engine->RegisterObjectMethod(
"degree",
"degree opAdd(const radian &in) const", asMETHODPR(Degree,
operator+,(
const Radian&)
const, Degree), asCALL_THISCALL);
1266 r = engine->RegisterObjectMethod(
"degree",
"degree &opAddAssign(const degree &in)", asMETHODPR(Degree,
operator+=,(
const Degree &),Degree&), asCALL_THISCALL);
1268 r = engine->RegisterObjectMethod(
"degree",
"degree &opAddAssign(const radian &in)", asMETHODPR(Degree,
operator+=,(
const Radian &),Degree&), asCALL_THISCALL);
1271 r = engine->RegisterObjectMethod(
"degree",
"degree opSub() const", asMETHODPR(Degree,
operator-,()
const, Degree), asCALL_THISCALL);
1273 r = engine->RegisterObjectMethod(
"degree",
"degree opSub(const degree &in) const", asMETHODPR(Degree,
operator-,(
const Degree&)
const, Degree), asCALL_THISCALL);
1275 r = engine->RegisterObjectMethod(
"degree",
"degree opSub(const radian &in) const", asMETHODPR(Degree,
operator-,(
const Radian&)
const, Degree), asCALL_THISCALL);
1278 r = engine->RegisterObjectMethod(
"degree",
"degree &opSubAssign(const degree &in)", asMETHODPR(Degree,
operator-=,(
const Degree &),Degree&), asCALL_THISCALL);
1280 r = engine->RegisterObjectMethod(
"degree",
"degree &opSubAssign(const radian &in)", asMETHODPR(Degree,
operator-=,(
const Radian &),Degree&), asCALL_THISCALL);
1283 r = engine->RegisterObjectMethod(
"degree",
"degree opMul(float) const", asMETHODPR(Degree,
operator*,(
float)
const, Degree), asCALL_THISCALL);
1285 r = engine->RegisterObjectMethod(
"degree",
"degree opMul(const degree &in) const", asMETHODPR(Degree,
operator*,(
const Degree&)
const, Degree), asCALL_THISCALL);
1288 r = engine->RegisterObjectMethod(
"degree",
"degree &opMulAssign(float)", asMETHODPR(Degree,
operator*=,(
float),Degree&), asCALL_THISCALL);
1291 r = engine->RegisterObjectMethod(
"degree",
"degree opDiv(float) const", asMETHODPR(Degree,
operator/,(
float)
const, Degree), asCALL_THISCALL);
1294 r = engine->RegisterObjectMethod(
"degree",
"degree &opDivAssign(float)", asMETHODPR(Degree,
operator*=,(
float),Degree&), asCALL_THISCALL);
1297 r = engine->RegisterObjectMethod(
"degree",
"int opCmp(const degree &in) const", asFUNCTION(
DegreeCmp), asCALL_CDECL_OBJFIRST);
1300 r = engine->RegisterObjectMethod(
"degree",
"bool opEquals(const degree &in) const", asMETHODPR(Degree,
operator==,(
const Degree&)
const,
bool), asCALL_THISCALL);
1304 r = engine->RegisterObjectMethod(
"degree",
"float valueRadians() const", asMETHOD(Degree,valueRadians), asCALL_THISCALL);
1306 r = engine->RegisterObjectMethod(
"degree",
"float valueDegrees() const", asMETHOD(Degree,valueDegrees), asCALL_THISCALL);
1308 r = engine->RegisterObjectMethod(
"degree",
"float valueAngleUnits() const", asMETHOD(Degree,valueAngleUnits), asCALL_THISCALL);
1317 r = engine->RegisterObjectProperty(
"quaternion",
"float w", offsetof(Quaternion,
w));
1319 r = engine->RegisterObjectProperty(
"quaternion",
"float x", offsetof(Quaternion,
x));
1321 r = engine->RegisterObjectProperty(
"quaternion",
"float y", offsetof(Quaternion,
y));
1323 r = engine->RegisterObjectProperty(
"quaternion",
"float z", offsetof(Quaternion,
z));
1330 r = engine->RegisterObjectBehaviour(
"quaternion", asBEHAVE_CONSTRUCT,
"void f()", asFUNCTION(
QuaternionDefaultConstructor), asCALL_CDECL_OBJLAST);
1332 r = engine->RegisterObjectBehaviour(
"quaternion", asBEHAVE_CONSTRUCT,
"void f(const radian &in, const vector3 &in)", asFUNCTION(
QuaternionInitConstructor1), asCALL_CDECL_OBJLAST);
1334 r = engine->RegisterObjectBehaviour(
"quaternion", asBEHAVE_CONSTRUCT,
"void f(float, float, float, float)", asFUNCTION(
QuaternionInitConstructor2), asCALL_CDECL_OBJLAST);
1336 r = engine->RegisterObjectBehaviour(
"quaternion", asBEHAVE_CONSTRUCT,
"void f(const vector3 &in, const vector3 &in, const vector3 &in)", asFUNCTION(
QuaternionInitConstructor3), asCALL_CDECL_OBJLAST);
1338 r = engine->RegisterObjectBehaviour(
"quaternion", asBEHAVE_CONSTRUCT,
"void f(float)", asFUNCTION(
QuaternionInitConstructorScaler), asCALL_CDECL_OBJLAST);
1340 r = engine->RegisterObjectBehaviour(
"quaternion", asBEHAVE_CONSTRUCT,
"void f(const quaternion &in)", asFUNCTION(
QuaternionCopyConstructor), asCALL_CDECL_OBJLAST);
1344 r = engine->RegisterObjectMethod(
"quaternion",
"float opIndex(int) const", asMETHODPR(Quaternion,
operator[], (
size_t)
const,
float), asCALL_THISCALL);
1346 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion &opAssign(const quaternion &in)", asMETHODPR(Quaternion,
operator =, (
const Quaternion &), Quaternion&), asCALL_THISCALL);
1348 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion opAdd(const quaternion &in) const", asMETHODPR(Quaternion,
operator+,(
const Quaternion&)
const, Quaternion), asCALL_THISCALL);
1350 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion opSub(const quaternion &in) const", asMETHODPR(Quaternion,
operator-,(
const Quaternion&)
const, Quaternion), asCALL_THISCALL);
1352 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion opMul(const quaternion &in) const", asMETHODPR(Quaternion,
operator*,(
const Quaternion&)
const, Quaternion), asCALL_THISCALL);
1354 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion opMul(float) const", asMETHODPR(Quaternion,
operator*,(
float)
const, Quaternion), asCALL_THISCALL);
1356 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion opSub() const", asMETHODPR(Quaternion,
operator-,()
const, Quaternion), asCALL_THISCALL);
1358 r = engine->RegisterObjectMethod(
"quaternion",
"bool opEquals(const quaternion &in) const", asMETHODPR(Quaternion,
operator==,(
const Quaternion&)
const,
bool), asCALL_THISCALL);
1360 r = engine->RegisterObjectMethod(
"quaternion",
"vector3 opMul(const vector3 &in) const", asMETHODPR(Quaternion,
operator*,(
const Vector3&)
const, Vector3), asCALL_THISCALL);
1364 r = engine->RegisterObjectMethod(
"quaternion",
"float Dot(const quaternion &in) const", asMETHOD(Quaternion,
Dot), asCALL_THISCALL);
1366 r = engine->RegisterObjectMethod(
"quaternion",
"float Norm() const", asMETHOD(Quaternion,
Norm), asCALL_THISCALL);
1368 r = engine->RegisterObjectMethod(
"quaternion",
"float normalise()", asMETHOD(Quaternion,
normalise), asCALL_THISCALL);
1370 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion Inverse() const", asMETHOD(Quaternion,
Inverse), asCALL_THISCALL);
1372 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion UnitInverse() const", asMETHOD(Quaternion,
UnitInverse), asCALL_THISCALL);
1374 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion Exp() const", asMETHOD(Quaternion,
Exp), asCALL_THISCALL);
1376 r = engine->RegisterObjectMethod(
"quaternion",
"quaternion Log() const", asMETHOD(Quaternion,
Log), asCALL_THISCALL);
1378 r = engine->RegisterObjectMethod(
"quaternion",
"radian getRoll(bool reprojectAxis = true) const", asMETHOD(Quaternion,
getRoll), asCALL_THISCALL);
1380 r = engine->RegisterObjectMethod(
"quaternion",
"radian getPitch(bool reprojectAxis = true) const", asMETHOD(Quaternion,
getPitch), asCALL_THISCALL);
1382 r = engine->RegisterObjectMethod(
"quaternion",
"radian getYaw(bool reprojectAxis = true) const", asMETHOD(Quaternion,
getYaw), asCALL_THISCALL);
1384 r = engine->RegisterObjectMethod(
"quaternion",
"bool equals(const quaternion &in, const radian &in) const", asMETHOD(Quaternion,
equals), asCALL_THISCALL);
1386 r = engine->RegisterObjectMethod(
"quaternion",
"bool isNaN() const", asMETHOD(Quaternion,
isNaN), asCALL_THISCALL);
1390 r = engine->RegisterGlobalFunction(
"quaternion Slerp(float, const quaternion &in, const quaternion &in, bool &in)", asFUNCTIONPR(
Quaternion::Slerp,(Real fT,
const Quaternion&,
const Quaternion&,
bool), Quaternion), asCALL_CDECL);
1392 r = engine->RegisterGlobalFunction(
"quaternion SlerpExtraSpins(float, const quaternion &in, const quaternion &in, int &in)", asFUNCTION(
Quaternion::SlerpExtraSpins), asCALL_CDECL);
1394 r = engine->RegisterGlobalFunction(
"void Intermediate(const quaternion &in, const quaternion &in, const quaternion &in, const quaternion &in, const quaternion &in)", asFUNCTION(
Quaternion::Intermediate), asCALL_CDECL);
1396 r = engine->RegisterGlobalFunction(
"quaternion Squad(float, const quaternion &in, const quaternion &in, const quaternion &in, const quaternion &in, bool &in)", asFUNCTION(
Quaternion::Squad), asCALL_CDECL);
1398 r = engine->RegisterGlobalFunction(
"quaternion nlerp(float, const quaternion &in, const quaternion &in, bool &in)", asFUNCTION(
Quaternion::nlerp), asCALL_CDECL);
1407 r = engine->RegisterObjectProperty(
"color",
"float r", offsetof(ColourValue, r));
1409 r = engine->RegisterObjectProperty(
"color",
"float g", offsetof(ColourValue, g));
1411 r = engine->RegisterObjectProperty(
"color",
"float b", offsetof(ColourValue, b));
1413 r = engine->RegisterObjectProperty(
"color",
"float a", offsetof(ColourValue, a));
1417 r = engine->RegisterObjectBehaviour(
"color", asBEHAVE_CONSTRUCT,
"void f()", asFUNCTION(
ColourValueDefaultConstructor), asCALL_CDECL_OBJLAST);
1419 r = engine->RegisterObjectBehaviour(
"color", asBEHAVE_CONSTRUCT,
"void f(float r, float g, float b, float a)", asFUNCTION(
ColourValueInitConstructor), asCALL_CDECL_OBJLAST);
1421 r = engine->RegisterObjectBehaviour(
"color", asBEHAVE_CONSTRUCT,
"void f(const color &other)", asFUNCTION(
QuaternionCopyConstructor), asCALL_CDECL_OBJLAST);
1429 r = engine->RegisterObjectProperty(
"box",
"uint left", offsetof(Box, left));
1431 r = engine->RegisterObjectProperty(
"box",
"uint top", offsetof(Box, top));
1433 r = engine->RegisterObjectProperty(
"box",
"uint right", offsetof(Box, right));
1435 r = engine->RegisterObjectProperty(
"box",
"uint bottom", offsetof(Box, bottom));
1437 r = engine->RegisterObjectProperty(
"box",
"uint front", offsetof(Box, front));
1439 r = engine->RegisterObjectProperty(
"box",
"uint back", offsetof(Box, back));
1443 r = engine->RegisterObjectBehaviour(
"box", asBEHAVE_CONSTRUCT,
"void f()", asFUNCTION(
BoxDefaultConstructor), asCALL_CDECL_OBJLAST);
1445 r = engine->RegisterObjectBehaviour(
"box", asBEHAVE_CONSTRUCT,
"void f(uint32 l, uint32 t, uint32 r, uint32 b)", asFUNCTION(
BoxInitConstructor), asCALL_CDECL_OBJLAST);
1447 r = engine->RegisterObjectBehaviour(
"box", asBEHAVE_CONSTRUCT,
"void f(const box &other)", asFUNCTION(
BoxCopyConstructor), asCALL_CDECL_OBJLAST);
1450 r = engine->RegisterObjectBehaviour(
"box", asBEHAVE_DESTRUCT,
"void f()", asFUNCTION(
BoxDestructor), asCALL_CDECL_OBJLAST);
1452 r = engine->RegisterObjectMethod(
"box",
"box& opAssign(const box&in)", asFUNCTION(
BoxAssignOperator), asCALL_CDECL_OBJLAST);
1459 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1462 r = engine->RegisterObjectBehaviour(
"TexturePtr", asBEHAVE_CONSTRUCT,
"void f(const TexturePtr&in)", asFUNCTION(
TexturePtrCopyConstructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
1463 r = engine->RegisterObjectBehaviour(
"TexturePtr", asBEHAVE_DESTRUCT,
"void f()", asFUNCTION(
TexturePtrDestructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
1464 r = engine->RegisterObjectMethod(
"TexturePtr",
"TexturePtr& opAssign(const TexturePtr&in)", asFUNCTION(
TexturePtrAssignOperator), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
1465 r = engine->RegisterObjectMethod(
"TexturePtr",
"bool isNull()", asFUNCTION(
TexturePtrIsNull), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
1468 r = engine->RegisterObjectMethod(
"TexturePtr",
"string getName() const", asFUNCTIONPR([](TexturePtr
const&
self) {
1469 return self->getName();
1470 }, (TexturePtr
const&), Ogre::String), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1471 r = engine->RegisterObjectMethod(
"TexturePtr",
"uint getWidth()", asFUNCTIONPR([](TexturePtr
const&
self) {
1472 return (asUINT)self->getWidth();
1473 }, (TexturePtr
const&), Ogre::uint32), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1474 r = engine->RegisterObjectMethod(
"TexturePtr",
"uint getHeight()", asFUNCTIONPR([](TexturePtr
const&
self) {
1475 return (asUINT)self->getHeight();
1476 }, (TexturePtr
const&), Ogre::uint32), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1477 r = engine->RegisterObjectMethod(
"TexturePtr",
"uint getNumMipmaps()", asFUNCTIONPR([](TexturePtr
const&
self) {
1478 return (asUINT)self->getNumMipmaps();
1479 }, (TexturePtr
const&), Ogre::uint32), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1480 r = engine->RegisterObjectMethod(
"TexturePtr",
"HardwarePixelBufferPtr getBuffer(uint, uint)", asFUNCTIONPR([](TexturePtr
const&
self, asUINT face, asUINT mipmap) {
1481 return self->getBuffer(face, mipmap);
1482 }, (TexturePtr
const&, asUINT, asUINT), HardwarePixelBufferSharedPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1484 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1490 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1493 r = engine->RegisterObjectMethod(
"TextureManager",
"TexturePtr load(const string&in file, const string&in rg)", asFUNCTIONPR([](TextureManager& mgr, std::string
const&
file, std::string
const& rg){
1494 try {
return mgr.load(
file, rg); }
1496 }, (TextureManager& mgr, std::string
const&
file, std::string
const& rg), TexturePtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1498 r = engine->SetDefaultNamespace(
"Ogre::TextureManager");
ROR_ASSERT(r >= 0);
1499 r = engine->RegisterGlobalFunction(
"TextureManager& getSingleton()", asFUNCTION(TextureManager::getSingleton), asCALL_CDECL);
ROR_ASSERT(r >= 0);
1501 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1504 template <
typename T>
1510 r = engine->RegisterObjectMethod(obj,
"const string& getName() const", asMETHOD(MovableObject, getName), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1511 r = engine->RegisterObjectMethod(obj,
"const string& getMovableType() const", asMETHOD(MovableObject, getMovableType), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1513 r = engine->RegisterObjectMethod(obj,
"Node@ getParentNode()", asMETHOD(MovableObject, getParentNode), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1514 r = engine->RegisterObjectMethod(obj,
"SceneNode@ getParentSceneNode()", asMETHOD(MovableObject, getParentSceneNode), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1515 r = engine->RegisterObjectMethod(obj,
"bool isParentTagPoint() const", asMETHOD(MovableObject, isParentTagPoint), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1516 r = engine->RegisterObjectMethod(obj,
"bool isAttached() const", asMETHOD(MovableObject, isAttached), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1517 r = engine->RegisterObjectMethod(obj,
"void detachFromParent()", asMETHOD(MovableObject, detachFromParent), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1519 r = engine->RegisterObjectMethod(obj,
"bool isInScene() const", asMETHOD(MovableObject, isInScene), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1520 r = engine->RegisterObjectMethod(obj,
"float getBoundingRadius() const", asMETHOD(MovableObject, getBoundingRadius), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1522 r = engine->RegisterObjectMethod(obj,
"void setVisible(bool visible)", asMETHOD(MovableObject, setVisible), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1523 r = engine->RegisterObjectMethod(obj,
"bool getVisible() const", asMETHOD(MovableObject, getVisible), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1524 r = engine->RegisterObjectMethod(obj,
"bool isVisible() const", asMETHOD(MovableObject, isVisible), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1526 r = engine->RegisterObjectMethod(obj,
"void setRenderingDistance(float dist)", asMETHOD(MovableObject, setRenderingDistance), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1527 r = engine->RegisterObjectMethod(obj,
"float getRenderingDistance() const", asMETHOD(MovableObject, getRenderingDistance), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1529 r = engine->RegisterObjectMethod(obj,
"void setRenderingMinPixelSize(float pixelSize)", asMETHOD(MovableObject, setRenderingMinPixelSize), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1530 r = engine->RegisterObjectMethod(obj,
"float getRenderingMinPixelSize() const", asMETHOD(MovableObject, getRenderingMinPixelSize), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1532 r = engine->RegisterObjectMethod(obj,
"void setCastShadows(bool enabled)", asMETHOD(MovableObject, setCastShadows), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1533 r = engine->RegisterObjectMethod(obj,
"bool getCastShadows() const", asMETHOD(MovableObject, getCastShadows), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1539 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1541 registerOgreMovableObjectBase<MovableObject>(engine,
"MovableObject");
1543 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1549 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1551 r = engine->RegisterObjectMethod(
"Entity",
"AnimationState @getAnimationState(const string &in) const", asMETHOD(Entity, getAnimationState), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1552 r = engine->RegisterObjectMethod(
"Entity",
"AnimationStateSet @getAllAnimationStates()", asMETHOD(Entity, getAllAnimationStates), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1553 r = engine->RegisterObjectMethod(
"Entity",
"void setDisplaySkeleton(bool)", asMETHOD(Entity, setDisplaySkeleton), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1554 r = engine->RegisterObjectMethod(
"Entity",
"bool getDisplaySkeleton() const", asMETHOD(Entity, getDisplaySkeleton), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1555 r = engine->RegisterObjectMethod(
"Entity",
"uint64 getNumManualLodLevels() const", asMETHOD(Entity, getNumManualLodLevels), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1556 r = engine->RegisterObjectMethod(
"Entity",
"uint16 getCurrentLodIndex()", asMETHOD(Entity, getCurrentLodIndex), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1557 r = engine->RegisterObjectMethod(
"Entity",
"Entity @getManualLodLevel(uint64) const", asMETHOD(Entity, getManualLodLevel), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1558 r = engine->RegisterObjectMethod(
"Entity",
"void setMeshLodBias(float, uint16, uint16)", asMETHOD(Entity, setMeshLodBias), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1559 r = engine->RegisterObjectMethod(
"Entity",
"void setMaterialLodBias(float, uint16, uint16)", asMETHOD(Entity, setMaterialLodBias), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1560 r = engine->RegisterObjectMethod(
"Entity",
"SubEntityArray @getSubEntities() const", asFUNCTION(
EntityGetSubEntities), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1561 r = engine->RegisterObjectMethod(
"Entity",
"const MeshPtr& getMesh() const", asMETHOD(Entity, getMesh), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1563 registerOgreMovableObjectBase<MovableObject>(engine,
"Entity");
1565 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1571 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1573 r = engine->RegisterObjectMethod(
"SubEntity",
"const MaterialPtr& getMaterial() const", asMETHOD(SubEntity, getMaterial), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1574 r = engine->RegisterObjectMethod(
"SubEntity",
"void setMaterial(const MaterialPtr&in)", asMETHOD(SubEntity, setMaterial), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1575 r = engine->RegisterObjectMethod(
"SubEntity",
"SubMesh@ getSubMesh()", asMETHOD(SubEntity, getSubMesh), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1577 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1580 template <
typename T>
1584 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1586 r = engine->RegisterObjectMethod(obj,
"const vector3& getPosition() const", asMETHOD(T, getPosition), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1587 r = engine->RegisterObjectMethod(obj,
"void setPosition(const vector3 &in)", asMETHODPR(T, setPosition, (
const Vector3&),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1589 r = engine->RegisterObjectMethod(obj,
"const vector3& getScale() const", asMETHOD(T, getScale), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1590 r = engine->RegisterObjectMethod(obj,
"void setScale(const vector3 &in)", asMETHODPR(T, setScale, (
const Ogre::Vector3&),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1592 r = engine->RegisterObjectMethod(obj,
"const string& getName() const", asMETHOD(T, getName), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1593 r = engine->RegisterObjectMethod(obj,
"Node@ getParent()", asMETHOD(T, getParent), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1595 r = engine->RegisterObjectMethod(obj,
"const quaternion& getOrientation() const", asMETHOD(T, getOrientation), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1596 r = engine->RegisterObjectMethod(obj,
"void setOrientation(const quaternion&in)", asFUNCTIONPR([](T*
self,
const Ogre::Quaternion& q){
1597 self->setOrientation(q);
1598 }, (T*,
const Quaternion&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1603 r = engine->RegisterObjectMethod(obj,
"ChildNodeArray@ getChildren()", asFUNCTION(
NodeGetChildren), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
1605 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1611 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1613 registerOgreNodeBase<Node>(engine,
"Node");
1615 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1621 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1623 r = engine->RegisterObjectMethod(
"SceneNode",
"void attachObject(MovableObject@ obj)", asMETHODPR(SceneNode, attachObject, (MovableObject*),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1624 r = engine->RegisterObjectMethod(
"SceneNode",
"MovableObject@ getAttachedObject(const string& in)", asMETHODPR(SceneNode, getAttachedObject, (
const String&), MovableObject*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1625 r = engine->RegisterObjectMethod(
"SceneNode",
"MovableObject@ detachObject(uint16)", asMETHODPR(SceneNode, detachObject, (uint16), MovableObject*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1626 r = engine->RegisterObjectMethod(
"SceneNode",
"void detachObject(MovableObject@ obj)", asMETHODPR(SceneNode, detachObject, (MovableObject*),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1627 r = engine->RegisterObjectMethod(
"SceneNode",
"MovableObject@ detachObject(const string& in)", asMETHODPR(SceneNode, detachObject, (
const String&), MovableObject*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1628 r = engine->RegisterObjectMethod(
"SceneNode",
"void detachAllObjects()", asMETHOD(SceneNode, detachAllObjects), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1629 r = engine->RegisterObjectMethod(
"SceneNode",
"bool isInSceneGraph() const", asMETHOD(SceneNode, isInSceneGraph), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1630 r = engine->RegisterObjectMethod(
"SceneNode",
"SceneManager@ getCreator() const", asMETHOD(SceneNode, getCreator), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1631 r = engine->RegisterObjectMethod(
"SceneNode",
"void removeAndDestroyChild(const string& in)", asMETHODPR(SceneNode, removeAndDestroyChild, (
const String&),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1632 r = engine->RegisterObjectMethod(
"SceneNode",
"void removeAndDestroyChild(uint16)", asMETHODPR(SceneNode, removeAndDestroyChild, (uint16),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1633 r = engine->RegisterObjectMethod(
"SceneNode",
"void removeAndDestroyChild(SceneNode@)", asMETHODPR(SceneNode, removeAndDestroyChild, (uint16),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1634 r = engine->RegisterObjectMethod(
"SceneNode",
"void removeAndDestroyAllChildren()", asMETHOD(SceneNode, removeAndDestroyAllChildren), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1635 r = engine->RegisterObjectMethod(
"SceneNode",
"void showBoundingBox(bool bShow)", asMETHOD(SceneNode, showBoundingBox), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1636 r = engine->RegisterObjectMethod(
"SceneNode",
"void hideBoundingBox(bool bHide)", asMETHOD(SceneNode, hideBoundingBox), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1637 r = engine->RegisterObjectMethod(
"SceneNode",
"bool getShowBoundingBox() const", asMETHOD(SceneNode, getShowBoundingBox), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1638 r = engine->RegisterObjectMethod(
"SceneNode",
"SceneNode@ createChildSceneNode(const string& in name, const vector3& in translate = vector3(0.f, 0.f, 0.f), const quaternion& in rotate = quaternion())", asMETHODPR(SceneNode, createChildSceneNode, (
const String&,
const Vector3&,
const Quaternion&), SceneNode*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1639 r = engine->RegisterObjectMethod(
"SceneNode",
"void setFixedYawAxis(bool useFixed, const vector3& in fixedAxis = vector3(0.f, 1.f, 0.f))", asMETHOD(SceneNode, setFixedYawAxis), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1640 r = engine->RegisterObjectMethod(
"SceneNode",
"void yaw(const radian& in angle, TransformSpace relativeTo = Ogre::TS_LOCAL)", asMETHOD(SceneNode, yaw), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1641 r = engine->RegisterObjectMethod(
"SceneNode",
"void setDirection(const vector3& in vec, TransformSpace relativeTo = Ogre::TS_LOCAL, const vector3& in localDirectionVector = vector3(0.f, 0.f, -1.f))", asMETHODPR(SceneNode, setDirection, (
const Vector3&, Node::TransformSpace,
const Vector3&),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1642 r = engine->RegisterObjectMethod(
"SceneNode",
"SceneNode@ getParentSceneNode() const", asMETHOD(SceneNode, getParentSceneNode), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1645 r = engine->RegisterObjectMethod(
"SceneNode",
"void lookAt(const vector3 &in, TransformSpace, const vector3 &in = vector3(0,0,-1))", asMETHODPR(SceneNode, lookAt, (
const Vector3&, Node::TransformSpace,
const Vector3&),
void), asCALL_THISCALL);
1646 r = engine->RegisterObjectMethod(
"SceneNode",
"void setAutoTracking(bool, SceneNode@, const vector3 &in = vector3(0,0,-1), const vector3 &in = vector3())", asMETHODPR(SceneNode, setAutoTracking, (
bool, SceneNode*
const,
const Vector3&,
const Vector3&),
void), asCALL_THISCALL);
1647 r = engine->RegisterObjectMethod(
"SceneNode",
"SceneNode@ getAutoTrackTarget()", asMETHODPR(SceneNode, getAutoTrackTarget, (), SceneNode*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1648 r = engine->RegisterObjectMethod(
"SceneNode",
"const vector3& getAutoTrackOffset()", asMETHODPR(SceneNode, getAutoTrackOffset, (),
const Vector3&), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1649 r = engine->RegisterObjectMethod(
"SceneNode",
"const vector3& getAutoTrackLocalDirection()", asMETHODPR(SceneNode, getAutoTrackLocalDirection, (),
const Vector3&), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1650 r = engine->RegisterObjectMethod(
"SceneNode",
"SceneNode@ getParentSceneNode()", asMETHODPR(SceneNode, getParentSceneNode, ()
const, SceneNode*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1651 r = engine->RegisterObjectMethod(
"SceneNode",
"void setVisible(bool, bool cascade = true)", asMETHODPR(SceneNode, setVisible, (
bool,
bool),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1652 r = engine->RegisterObjectMethod(
"SceneNode",
"void flipVisibility(bool = true)", asMETHODPR(SceneNode, flipVisibility, (
bool),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1653 r = engine->RegisterObjectMethod(
"SceneNode",
"void setDebugDisplayEnabled(bool, bool cascade = true)", asMETHODPR(SceneNode, setDebugDisplayEnabled, (
bool,
bool),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1655 registerOgreNodeBase<SceneNode>(engine,
"SceneNode");
1657 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1663 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1665 r = engine->RegisterObjectMethod(
"SceneManager",
"Entity@ createEntity(const string&in ent_name, const string &in mesh_name, const string &in mesh_rg = \"OgreAutodetect\")", asFUNCTIONPR([](Ogre::SceneManager*
self,
const std::string& entityName,
const std::string& meshName,
const std::string& meshRG) -> Ogre::Entity* {
1666 try {
return self->createEntity(entityName, meshName, meshRG); }
1668 }, (Ogre::SceneManager* ,
const std::string& ,
const std::string& ,
const std::string& ), Ogre::Entity*), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1669 r = engine->RegisterObjectMethod(
"SceneManager",
"const string& getName() const", asMETHOD(SceneManager, getName), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1670 r = engine->RegisterObjectMethod(
"SceneManager",
"SceneNode@ getRootSceneNode()", asMETHOD(SceneManager, getRootSceneNode), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1671 r = engine->RegisterObjectMethod(
"SceneManager",
"void destroyEntity(Entity@)", asMETHODPR(SceneManager, destroyEntity, (Entity*),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1672 r = engine->RegisterObjectMethod(
"SceneManager",
"void destroyEntity(const string &in)", asMETHODPR(SceneManager, destroyEntity, (
const Ogre::String&),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1673 r = engine->RegisterObjectMethod(
"SceneManager",
"void destroySceneNode(SceneNode@)", asMETHODPR(SceneManager, destroySceneNode, (SceneNode*),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1674 r = engine->RegisterObjectMethod(
"SceneManager",
"void destroySceneNode(const string &in)", asMETHODPR(SceneManager, destroySceneNode, (
const Ogre::String&),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1677 r = engine->RegisterObjectMethod(
"SceneManager",
"ManualObject@ createManualObject(const string &in)", asMETHODPR(SceneManager, createManualObject, (
const Ogre::String&), Ogre::ManualObject*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1678 r = engine->RegisterObjectMethod(
"SceneManager",
"ManualObject@ getManualObject(const string &in)", asMETHODPR(SceneManager, getManualObject, (
const Ogre::String&)
const, Ogre::ManualObject*), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1679 r = engine->RegisterObjectMethod(
"SceneManager",
"ManualObject@ destroyManualObject(const string &in)", asMETHODPR(SceneManager, destroyManualObject, (
const Ogre::String&),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1680 r = engine->RegisterObjectMethod(
"SceneManager",
"void destroyManualObject(ManualObject@)", asMETHODPR(SceneManager, destroyManualObject, (Ogre::ManualObject*),
void), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1682 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1688 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1690 r = engine->RegisterObjectMethod(
"Root",
"SceneManagerInstanceDict@ getSceneManagers()", asFUNCTION(
RootGetSceneManagers), asCALL_CDECL_OBJLAST);
1692 r = engine->SetDefaultNamespace(
"Ogre::Root");
1693 r = engine->RegisterGlobalFunction(
"Root& getSingleton()", asFUNCTION(Root::getSingleton), asCALL_CDECL);
1695 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1701 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1704 r = engine->RegisterObjectMethod(
"AnimationState",
"const string& getAnimationName() const", asMETHOD(AnimationState, getAnimationName), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1705 r = engine->RegisterObjectMethod(
"AnimationState",
"float getTimePosition() const", asMETHOD(AnimationState, getTimePosition), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1706 r = engine->RegisterObjectMethod(
"AnimationState",
"void setTimePosition(float)", asMETHOD(AnimationState, setTimePosition), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1707 r = engine->RegisterObjectMethod(
"AnimationState",
"float getLength() const", asMETHOD(AnimationState, getLength), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1708 r = engine->RegisterObjectMethod(
"AnimationState",
"void setLength(float)", asMETHOD(AnimationState, setLength), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1709 r = engine->RegisterObjectMethod(
"AnimationState",
"float getWeight() const", asMETHOD(AnimationState, getWeight), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1710 r = engine->RegisterObjectMethod(
"AnimationState",
"void setWeight(float)", asMETHOD(AnimationState, setWeight), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1711 r = engine->RegisterObjectMethod(
"AnimationState",
"void addTime(float)", asMETHOD(AnimationState, addTime), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1712 r = engine->RegisterObjectMethod(
"AnimationState",
"bool hasEnded() const", asMETHOD(AnimationState, hasEnded), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1713 r = engine->RegisterObjectMethod(
"AnimationState",
"bool getEnabled() const", asMETHOD(AnimationState, getEnabled), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1714 r = engine->RegisterObjectMethod(
"AnimationState",
"void setEnabled(bool)", asMETHOD(AnimationState, setEnabled), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1715 r = engine->RegisterObjectMethod(
"AnimationState",
"void setLoop(bool)", asMETHOD(AnimationState, setLoop), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1716 r = engine->RegisterObjectMethod(
"AnimationState",
"bool getLoop() const", asMETHOD(AnimationState, getLoop), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1717 r = engine->RegisterObjectMethod(
"AnimationState",
"AnimationStateSet@ getParent()", asMETHOD(AnimationState, getParent), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1718 r = engine->RegisterObjectMethod(
"AnimationState",
"void createBlendMask(uint blendMaskSizeHint, float initialWeight = 1.0f)", asMETHOD(AnimationState, createBlendMask), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1719 r = engine->RegisterObjectMethod(
"AnimationState",
"void destroyBlendMask()", asMETHOD(AnimationState, destroyBlendMask), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1720 r = engine->RegisterObjectMethod(
"AnimationState",
"bool hasBlendMask() const", asMETHOD(AnimationState, hasBlendMask), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1721 r = engine->RegisterObjectMethod(
"AnimationState",
"void setBlendMaskEntry(uint boneHandle, float weight)", asMETHOD(AnimationState, setBlendMaskEntry), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1722 r = engine->RegisterObjectMethod(
"AnimationState",
"float getBlendMaskEntry(uint boneHandle)", asMETHOD(AnimationState, getBlendMaskEntry), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1724 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1730 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1732 r = engine->RegisterObjectMethod(
"AnimationStateSet",
"AnimationState@ createAnimationState(const string& in, float, float, float = 1.0f, bool = false)", asMETHOD(AnimationStateSet, createAnimationState), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1733 r = engine->RegisterObjectMethod(
"AnimationStateSet",
"AnimationState@ getAnimationState(const string& in) const", asMETHOD(AnimationStateSet, getAnimationState), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1734 r = engine->RegisterObjectMethod(
"AnimationStateSet",
"bool hasAnimationState(const string& in) const", asMETHOD(AnimationStateSet, hasAnimationState), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1735 r = engine->RegisterObjectMethod(
"AnimationStateSet",
"void removeAnimationState(const string& in)", asMETHOD(AnimationStateSet, removeAnimationState), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1736 r = engine->RegisterObjectMethod(
"AnimationStateSet",
"void removeAllAnimationStates()", asMETHOD(AnimationStateSet, removeAllAnimationStates), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
1739 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
1745 const Ogre::Overlay::OverlayContainerList& ocList =
self->get2DElements();
1747 AngelScript::CScriptArray* arr = AngelScript::CScriptArray::Create(typeinfo);
1748 for (OverlayContainer* oc: ocList)
1750 OverlayElement* elem =
static_cast<Ogre::OverlayElement*
>(oc);
1751 arr->InsertLast(&elem);
1761 auto iterable =
self->getTemplateIterator();
1764 AngelScript::CScriptArray* arr = AngelScript::CScriptArray::Create(typeinfo);
1765 for (
auto& elem_pair: iterable) {
1766 OverlayElement* elem =
static_cast<Ogre::OverlayElement*
>(elem_pair.second);
1767 arr->InsertLast(&elem);
1775 engine->SetDefaultNamespace(
"Ogre");
1778 engine->RegisterEnum(
"GuiMetricsMode");
1779 engine->RegisterEnumValue(
"GuiMetricsMode",
"GMM_PIXELS", Ogre::GMM_PIXELS);
1780 engine->RegisterEnumValue(
"GuiMetricsMode",
"GMM_RELATIVE", Ogre::GMM_RELATIVE);
1781 engine->RegisterEnumValue(
"GuiMetricsMode",
"GMM_RELATIVE_ASPECT_ADJUSTED", Ogre::GMM_RELATIVE_ASPECT_ADJUSTED);
1784 engine->RegisterEnum(
"GuiHorizontalAlignment");
1785 engine->RegisterEnumValue(
"GuiHorizontalAlignment",
"GHA_LEFT", Ogre::GHA_LEFT);
1786 engine->RegisterEnumValue(
"GuiHorizontalAlignment",
"GHA_CENTER", Ogre::GHA_CENTER);
1787 engine->RegisterEnumValue(
"GuiHorizontalAlignment",
"GHA_RIGHT", Ogre::GHA_RIGHT);
1795 engine->RegisterObjectType(
"OverlayElement", 0, asOBJ_REF | asOBJ_NOCOUNT);
1796 engine->RegisterObjectMethod(
"OverlayElement",
"const string& getName() const", asMETHOD(Ogre::OverlayElement, getName), asCALL_THISCALL);
1798 engine->RegisterObjectMethod(
"OverlayElement",
"void show()", asMETHOD(Ogre::OverlayElement, show), asCALL_THISCALL);
1799 engine->RegisterObjectMethod(
"OverlayElement",
"void hide()", asMETHOD(Ogre::OverlayElement, hide), asCALL_THISCALL);
1800 engine->RegisterObjectMethod(
"OverlayElement",
"bool isVisible() const", asMETHOD(Ogre::OverlayElement, isVisible), asCALL_THISCALL);
1802 engine->RegisterObjectMethod(
"OverlayElement",
"void setPosition(float, float)", asMETHOD(Ogre::OverlayElement, setPosition), asCALL_THISCALL);
1803 engine->RegisterObjectMethod(
"OverlayElement",
"void setDimensions(float, float)", asMETHOD(Ogre::OverlayElement, setDimensions), asCALL_THISCALL);
1804 engine->RegisterObjectMethod(
"OverlayElement",
"float getLeft() const", asMETHOD(Ogre::OverlayElement, getLeft), asCALL_THISCALL);
1805 engine->RegisterObjectMethod(
"OverlayElement",
"float getTop() const", asMETHOD(Ogre::OverlayElement, getTop), asCALL_THISCALL);
1806 engine->RegisterObjectMethod(
"OverlayElement",
"float getWidth() const", asMETHOD(Ogre::OverlayElement, getWidth), asCALL_THISCALL);
1807 engine->RegisterObjectMethod(
"OverlayElement",
"float getHeight() const", asMETHOD(Ogre::OverlayElement, getHeight), asCALL_THISCALL);
1808 engine->RegisterObjectMethod(
"OverlayElement",
"void setLeft(float)", asMETHOD(Ogre::OverlayElement, setLeft), asCALL_THISCALL);
1809 engine->RegisterObjectMethod(
"OverlayElement",
"void setTop(float)", asMETHOD(Ogre::OverlayElement, setTop), asCALL_THISCALL);
1810 engine->RegisterObjectMethod(
"OverlayElement",
"void setWidth(float)", asMETHOD(Ogre::OverlayElement, setWidth), asCALL_THISCALL);
1811 engine->RegisterObjectMethod(
"OverlayElement",
"void setHeight(float)", asMETHOD(Ogre::OverlayElement, setHeight), asCALL_THISCALL);
1813 engine->RegisterObjectMethod(
"OverlayElement",
"const string& getMaterialName() const", asMETHOD(Ogre::OverlayElement, getMaterialName), asCALL_THISCALL);
1814 engine->RegisterObjectMethod(
"OverlayElement",
"void setMaterialName(const string&in, const string&in)", asMETHOD(Ogre::OverlayElement, setMaterialName), asCALL_THISCALL);
1816 engine->RegisterObjectMethod(
"OverlayElement",
"void setCaption(const string&in)", asMETHOD(Ogre::OverlayElement, setCaption), asCALL_THISCALL);
1817 engine->RegisterObjectMethod(
"OverlayElement",
"const string& getCaption() const", asMETHOD(Ogre::OverlayElement, getCaption), asCALL_THISCALL);
1819 engine->RegisterObjectMethod(
"OverlayElement",
"void setColour(const color&in)", asMETHOD(Ogre::OverlayElement, setColour), asCALL_THISCALL);
1820 engine->RegisterObjectMethod(
"OverlayElement",
"const color& getColour() const", asMETHOD(Ogre::OverlayElement, getColour), asCALL_THISCALL);
1822 engine->RegisterObjectMethod(
"OverlayElement",
"GuiMetricsMode getMetricsMode() const", asMETHOD(Ogre::OverlayElement, getMetricsMode), asCALL_THISCALL);
1823 engine->RegisterObjectMethod(
"OverlayElement",
"void setMetricsMode(GuiMetricsMode)", asMETHOD(Ogre::OverlayElement, setMetricsMode), asCALL_THISCALL);
1825 engine->RegisterObjectMethod(
"OverlayElement",
"GuiHorizontalAlignment getHorizontalAlignment() const", asMETHOD(Ogre::OverlayElement, getHorizontalAlignment), asCALL_THISCALL);
1826 engine->RegisterObjectMethod(
"OverlayElement",
"void setHorizontalAlignment(GuiHorizontalAlignment)", asMETHOD(Ogre::OverlayElement, setHorizontalAlignment), asCALL_THISCALL);
1831 engine->RegisterObjectType(
"Overlay", 0, asOBJ_REF | asOBJ_NOCOUNT);
1832 engine->RegisterObjectMethod(
"Overlay",
"const string& getName() const", asMETHOD(Ogre::Overlay, getName), asCALL_THISCALL);
1834 engine->RegisterObjectMethod(
"Overlay",
"void setZOrder(uint16)", asMETHOD(Ogre::Overlay, setZOrder), asCALL_THISCALL);
1835 engine->RegisterObjectMethod(
"Overlay",
"uint16 getZOrder()", asMETHOD(Ogre::Overlay, getZOrder), asCALL_THISCALL);
1837 engine->RegisterObjectMethod(
"Overlay",
"bool isVisible() const", asMETHODPR(Ogre::Overlay, isVisible, ()
const,
bool), asCALL_THISCALL);
1838 engine->RegisterObjectMethod(
"Overlay",
"void show()", asMETHODPR(Ogre::Overlay, show, (),
void), asCALL_THISCALL);
1839 engine->RegisterObjectMethod(
"Overlay",
"void hide()", asMETHODPR(Ogre::Overlay, hide, (),
void), asCALL_THISCALL);
1841 engine->RegisterObjectMethod(
"Overlay",
"void add2D(OverlayElement@)", asFUNCTIONPR([](Ogre::Overlay*
self, Ogre::OverlayElement* elem) {
1842 try {
self->add2D(
dynamic_cast<Ogre::OverlayContainer*
>(elem)); }
1844 engine->RegisterObjectMethod(
"Overlay",
"void remove2D(OverlayElement@)", asFUNCTIONPR([](Ogre::Overlay*
self, Ogre::OverlayElement* elem) {
1845 try {
self->remove2D(
dynamic_cast<Ogre::OverlayContainer*
>(elem)); }
1848 engine->RegisterObjectMethod(
"Overlay",
"void setScroll(float, float)", asMETHOD(Ogre::Overlay, setScroll), asCALL_THISCALL);
1849 engine->RegisterObjectMethod(
"Overlay",
"float getScrollX() const", asMETHOD(Ogre::Overlay, getScrollX), asCALL_THISCALL);
1850 engine->RegisterObjectMethod(
"Overlay",
"float getScrollY() const", asMETHOD(Ogre::Overlay, getScrollY), asCALL_THISCALL);
1851 engine->RegisterObjectMethod(
"Overlay",
"void scroll(float, float)", asMETHOD(Ogre::Overlay, scroll), asCALL_THISCALL);
1853 engine->RegisterObjectMethod(
"Overlay",
"void setRotate(const radian&in)", asMETHOD(Ogre::Overlay, setRotate), asCALL_THISCALL);
1854 engine->RegisterObjectMethod(
"Overlay",
"const radian& getRotate() const", asMETHOD(Ogre::Overlay, getRotate), asCALL_THISCALL);
1855 engine->RegisterObjectMethod(
"Overlay",
"void rotate(const radian&in)", asMETHOD(Ogre::Overlay, rotate), asCALL_THISCALL);
1857 engine->RegisterObjectMethod(
"Overlay",
"void setScale(float, float)", asMETHOD(Ogre::Overlay, setScale), asCALL_THISCALL);
1858 engine->RegisterObjectMethod(
"Overlay",
"float getScaleX() const", asMETHOD(Ogre::Overlay, getScaleX), asCALL_THISCALL);
1859 engine->RegisterObjectMethod(
"Overlay",
"float getScaleY() const", asMETHOD(Ogre::Overlay, getScaleY), asCALL_THISCALL);
1861 engine->RegisterObjectMethod(
"Overlay",
"array<OverlayElement@>@ get2DElements()", asFUNCTION(
get2DElementsHelper), asCALL_CDECL_OBJFIRST);
1866 engine->RegisterObjectType(
"OverlayManager", 0, asOBJ_REF | asOBJ_NOCOUNT);
1868 engine->RegisterObjectMethod(
"OverlayManager",
"Overlay@ create(const string&in)", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& name) {
1869 try {
return self->create(name);}
1871 engine->RegisterObjectMethod(
"OverlayManager",
"Overlay@ getByName(const string&in)", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& name) {
1872 try {
return self->getByName(name);}
1874 engine->RegisterObjectMethod(
"OverlayManager",
"void destroy(const string&in)", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& name) {
1875 try {
return self->destroy(name);}
1877 engine->RegisterObjectMethod(
"OverlayManager",
"void destroy(Overlay@)", asFUNCTIONPR([](Ogre::OverlayManager*
self, Ogre::Overlay* ov) {
1878 try {
return self->destroy(ov);}
1880 engine->RegisterObjectMethod(
"OverlayManager",
"void destroyAll()", asFUNCTIONPR([](Ogre::OverlayManager*
self) {
1881 try {
return self->destroyAll();}
1884 engine->RegisterObjectMethod(
"OverlayManager",
"array<Overlay@>@ getOverlays()", asFUNCTIONPR([](Ogre::OverlayManager*
self) {
1885 try {
auto iterable =
self->getOverlayIterator();
1889 engine->RegisterObjectMethod(
"OverlayManager",
"float getViewportHeight() const", asMETHOD(Ogre::OverlayManager, getViewportHeight), asCALL_THISCALL);
1890 engine->RegisterObjectMethod(
"OverlayManager",
"float getViewportWidth() const", asMETHOD(Ogre::OverlayManager, getViewportWidth), asCALL_THISCALL);
1892 engine->RegisterObjectMethod(
"OverlayManager",
"OverlayElement@ createOverlayElement(const string&in, const string&in, bool=false)", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& type,
const std::string& name,
bool isTemplate) {
1893 try {
return dynamic_cast<Ogre::OverlayElement*
>(
self->createOverlayElement(type,name,isTemplate));}
1894 catch(...) {
App::GetScriptEngine()->
forwardExceptionAsScriptEvent(
"Ogre::OverlayManager::createOverlayElement()");
return (Ogre::OverlayElement*)
nullptr;}}, (Ogre::OverlayManager*,
const std::string&,
const std::string&, bool), Ogre::OverlayElement*), asCALL_CDECL_OBJFIRST);
1895 engine->RegisterObjectMethod(
"OverlayManager",
"OverlayElement@ getOverlayElement(const string&in) const", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& name) {
1896 try {
return dynamic_cast<Ogre::OverlayElement*
>(
self->getOverlayElement(name));}
1897 catch(...) {
App::GetScriptEngine()->
forwardExceptionAsScriptEvent(
"Ogre::OverlayManager::getOverlayElement()");
return (Ogre::OverlayElement*)
nullptr;}}, (Ogre::OverlayManager*,
const std::string&), Ogre::OverlayElement*), asCALL_CDECL_OBJFIRST);
1898 engine->RegisterObjectMethod(
"OverlayManager",
"bool hasOverlayElement(const string&in) const", asMETHOD(Ogre::OverlayManager, hasOverlayElement), asCALL_THISCALL);
1899 engine->RegisterObjectMethod(
"OverlayManager",
"void destroyOverlayElement(const string&in, bool isTemplate=false) const", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& name,
bool isTemplate) {
1900 try {
self->destroyOverlayElement(name, isTemplate);}
1902 engine->RegisterObjectMethod(
"OverlayManager",
"void destroyOverlayElement(OverlayElement@, bool isTemplate=false) const", asFUNCTIONPR([](Ogre::OverlayManager*
self, Ogre::OverlayElement* oe,
bool isTemplate) {
1903 try {
self->destroyOverlayElement(oe, isTemplate);}
1905 engine->RegisterObjectMethod(
"OverlayManager",
"void destroyAllOverlayElements(bool isTemplate=false) const", asFUNCTIONPR([](Ogre::OverlayManager*
self,
bool isTemplate) {
1906 try {
self->destroyAllOverlayElements(isTemplate);}
1909 engine->RegisterObjectMethod(
"OverlayManager",
"OverlayElement@ createOverlayElementFromTemplate(const string&in, const string&in, const string&in, bool=false)", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& templateName,
const std::string& typeName,
const std::string& instanceName,
bool isTemplate) {
1910 try {
return dynamic_cast<Ogre::OverlayElement*
>(
self->createOverlayElementFromTemplate(templateName, typeName, instanceName, isTemplate));}
1911 catch(...) {
App::GetScriptEngine()->
forwardExceptionAsScriptEvent(
"Ogre::OverlayManager::createOverlayElementFromTemplate()");
return (Ogre::OverlayElement*)
nullptr;}}, (Ogre::OverlayManager*,
const std::string&,
const std::string&,
const std::string&, bool), Ogre::OverlayElement*), asCALL_CDECL_OBJFIRST);
1912 engine->RegisterObjectMethod(
"OverlayManager",
"OverlayElement@ cloneOverlayElementFromTemplate(const string&in, const string&in)", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& templateName,
const std::string& instanceName) {
1913 try {
return dynamic_cast<Ogre::OverlayElement*
>(
self->cloneOverlayElementFromTemplate(templateName, instanceName));}
1914 catch(...) {
App::GetScriptEngine()->
forwardExceptionAsScriptEvent(
"Ogre::OverlayManager::cloneOverlayElementFromTemplate()");
return (Ogre::OverlayElement*)
nullptr;}}, (Ogre::OverlayManager*,
const std::string&,
const std::string&), Ogre::OverlayElement*), asCALL_CDECL_OBJFIRST);
1916 engine->RegisterObjectMethod(
"OverlayManager",
"array<OverlayElement@>@ getTemplates()", asFUNCTION(
getElementTemplatesHelper), asCALL_CDECL_OBJFIRST);
1917 engine->RegisterObjectMethod(
"OverlayManager",
"bool isTemplate(const string&in)", asFUNCTIONPR([](Ogre::OverlayManager*
self,
const std::string& name) {
1918 try {
return self->isTemplate(name);}
1922 engine->SetDefaultNamespace(
"Ogre::OverlayManager");
1923 engine->RegisterGlobalFunction(
"OverlayManager& getSingleton()", asFUNCTION(OverlayManager::getSingleton), asCALL_CDECL);
1925 engine->SetDefaultNamespace(
"");
1931 engine->SetDefaultNamespace(
"Ogre");
1934 engine->RegisterObjectType(
"ManualObject", 0, asOBJ_REF | asOBJ_NOCOUNT);
1935 engine->RegisterObjectMethod(
"ManualObject",
"void begin(const string&in, RenderOperation, const string&in)", asMETHODPR(Ogre::ManualObject, begin, (
const String&, Ogre::RenderOperation::OperationType,
const String&),
void), asCALL_THISCALL);
1936 engine->RegisterObjectMethod(
"ManualObject",
"void beginUpdate()", asMETHOD(Ogre::ManualObject, beginUpdate), asCALL_THISCALL);
1937 engine->RegisterObjectMethod(
"ManualObject",
"void position(const vector3&in)", asMETHODPR(Ogre::ManualObject, position, (
const Ogre::Vector3&),
void), asCALL_THISCALL);
1938 engine->RegisterObjectMethod(
"ManualObject",
"void normal(const vector3&in)", asMETHODPR(Ogre::ManualObject, normal, (
const Ogre::Vector3&),
void), asCALL_THISCALL);
1939 engine->RegisterObjectMethod(
"ManualObject",
"void textureCoord(float, float)", asMETHODPR(Ogre::ManualObject, textureCoord, (
float,
float),
void), asCALL_THISCALL);
1940 engine->RegisterObjectMethod(
"ManualObject",
"void textureCoord(const vector2&in)", asMETHODPR(Ogre::ManualObject, textureCoord, (
const Ogre::Vector2&),
void), asCALL_THISCALL);
1941 engine->RegisterObjectMethod(
"ManualObject",
"void textureCoord(const vector3&in)", asMETHODPR(Ogre::ManualObject, textureCoord, (
const Ogre::Vector3&),
void), asCALL_THISCALL);
1942 engine->RegisterObjectMethod(
"ManualObject",
"void colour(const color&in)", asMETHODPR(Ogre::ManualObject, colour, (
const Ogre::ColourValue&),
void), asCALL_THISCALL);
1943 engine->RegisterObjectMethod(
"ManualObject",
"void index(uint32)", asMETHOD(Ogre::ManualObject, index), asCALL_THISCALL);
1944 engine->RegisterObjectMethod(
"ManualObject",
"void end()", asMETHOD(Ogre::ManualObject, end), asCALL_THISCALL);
1946 engine->RegisterObjectMethod(
"ManualObject",
"uint getCurrentVertexCount()", asMETHOD(Ogre::ManualObject, getCurrentVertexCount), asCALL_THISCALL);
1947 engine->RegisterObjectMethod(
"ManualObject",
"void getCurrentIndexCount()", asMETHOD(Ogre::ManualObject, getCurrentIndexCount), asCALL_THISCALL);
1949 engine->RegisterObjectMethod(
"ManualObject",
"MeshPtr convertToMesh(const string&in name, const string&in group = 'General')", asMETHOD(Ogre::ManualObject, convertToMesh), asCALL_THISCALL);
1951 engine->SetDefaultNamespace(
"");
1959 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
1966 r = engine->RegisterObjectMethod(
"HardwarePixelBufferPtr",
"const PixelBox& getCurrentLock()", asFUNCTIONPR([](HardwarePixelBufferSharedPtr
const&
self) ->
const PixelBox& {
1967 try {
return self->getCurrentLock(); }
1969 }, (HardwarePixelBufferSharedPtr
const&),
const PixelBox&), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1971 r = engine->RegisterObjectMethod(
"HardwarePixelBufferPtr",
"const PixelBox& lock(const box& lockbox, HardwareBufferLockOptions opt)", asFUNCTIONPR([](HardwarePixelBufferSharedPtr
const&
self,
const Box& lockbox, HardwareBuffer::LockOptions opt) ->
const PixelBox& {
1972 try {
return self->lock(lockbox, opt); }
1974 }, (HardwarePixelBufferSharedPtr
const&,
const Box&, HardwareBuffer::LockOptions),
const PixelBox&), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1976 r = engine->RegisterObjectMethod(
"HardwarePixelBufferPtr",
"uint getWidth()", asFUNCTIONPR([](HardwarePixelBufferSharedPtr
const&
self) -> asUINT {
1977 try {
return self->getWidth(); }
1979 }, (HardwarePixelBufferSharedPtr
const&), asUINT), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1981 r = engine->RegisterObjectMethod(
"HardwarePixelBufferPtr",
"uint getHeight()", asFUNCTIONPR([](HardwarePixelBufferSharedPtr
const&
self) -> asUINT {
1982 try {
return self->getHeight(); }
1984 }, (HardwarePixelBufferSharedPtr
const&), asUINT), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1986 r = engine->RegisterObjectMethod(
"HardwarePixelBufferPtr",
"void blitFromMemory(const PixelBox& src, const box& dst)", asFUNCTIONPR([](HardwarePixelBufferSharedPtr
const&
self,
const PixelBox& src,
const Box& dstBox){
1987 try {
self->blitFromMemory(src, dstBox); }
1989 }, (HardwarePixelBufferSharedPtr
const&,
const PixelBox&,
const Box&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1991 r = engine->RegisterObjectMethod(
"HardwarePixelBufferPtr",
"void blitToMemory(const box& src, const PixelBox& dst)", asFUNCTIONPR([](HardwarePixelBufferSharedPtr
const&
self,
const Box& srcBox,
const PixelBox& dst){
1992 try {
self->blitToMemory(srcBox, dst); }
1994 }, (HardwarePixelBufferSharedPtr
const&,
const Box&,
const PixelBox&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
1996 r = engine->RegisterObjectMethod(
"HardwarePixelBufferPtr",
"void unlock()", asFUNCTIONPR([](HardwarePixelBufferSharedPtr
const&
self){
1997 try {
self->unlock(); }
1999 }, (HardwarePixelBufferSharedPtr
const&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2001 engine->SetDefaultNamespace(
"");
2007 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2010 r = engine->RegisterObjectBehaviour(
"PixelBox", asBEHAVE_CONSTRUCT,
"void f(const PixelBox&in)", asFUNCTION(
PixelBoxCopyConstructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2011 r = engine->RegisterObjectBehaviour(
"PixelBox", asBEHAVE_DESTRUCT,
"void f()", asFUNCTION(
PixelBoxDestructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2012 r = engine->RegisterObjectMethod(
"PixelBox",
"PixelBox& opAssign(const PixelBox&in)", asFUNCTION(
PixelBoxAssignOperator), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2014 r = engine->RegisterObjectMethod(
"PixelBox",
"color getColourAt(uint32 x, uint32 y, uint32 z)", asMETHOD(PixelBox, getColourAt), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2015 r = engine->RegisterObjectMethod(
"PixelBox",
"void setColourAt(const color& c, uint32 x, uint32 y, uint32 z)", asMETHOD(PixelBox, setColourAt), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2018 r = engine->RegisterObjectMethod(
"PixelBox",
"uint getWidth()", asFUNCTIONPR([](
const Ogre::PixelBox&
self) -> asUINT {
2019 return self.getWidth();
2020 }, (
const Ogre::PixelBox&), asUINT), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2022 r = engine->RegisterObjectMethod(
"PixelBox",
"uint getHeight()", asFUNCTIONPR([](
const Ogre::PixelBox&
self) -> asUINT {
2023 return self.getHeight();
2024 }, (
const Ogre::PixelBox&), asUINT), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2026 r = engine->RegisterObjectMethod(
"PixelBox",
"uint getDepth()", asFUNCTIONPR([](
const Ogre::PixelBox&
self) -> asUINT {
2027 return self.getDepth();
2028 } , (
const Ogre::PixelBox&), asUINT), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2030 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
2036 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2039 r = engine->RegisterObjectBehaviour(
"Image", asBEHAVE_CONSTRUCT,
"void f(const Image&in)", asFUNCTION(
ImageCopyConstructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2040 r = engine->RegisterObjectBehaviour(
"Image", asBEHAVE_DESTRUCT,
"void f()", asFUNCTION(
ImageDestructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2041 r = engine->RegisterObjectMethod(
"Image",
"Image& opAssign(const Image&in)", asFUNCTION(
ImageAssignOperator), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2043 r = engine->RegisterObjectMethod(
"Image",
"color getColourAt(uint32 x, uint32 y, uint32 z)", asMETHOD(Image, getColourAt), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2044 r = engine->RegisterObjectMethod(
"Image",
"void setColourAt(const color& c, uint32 x, uint32 y, uint32 z)", asMETHOD(Image, setColourAt), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2045 r = engine->RegisterObjectMethod(
"Image",
"Image& flipAroundX()", asMETHOD(Ogre::Image, flipAroundX), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2046 r = engine->RegisterObjectMethod(
"Image",
"Image& flipAroundY()", asMETHOD(Ogre::Image, flipAroundY), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2047 r = engine->RegisterObjectMethod(
"Image",
"uint getNumMipmaps()", asMETHOD(Ogre::Image, getNumMipmaps), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2048 r = engine->RegisterObjectMethod(
"Image",
"uint getNumFaces()", asMETHOD(Ogre::Image, getNumFaces), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2049 r = engine->RegisterObjectMethod(
"Image",
"PixelBox getPixelBox(uint face, uint mipmap)", asMETHOD(Ogre::Image, getPixelBox), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2050 r = engine->RegisterObjectMethod(
"Image",
"uint getSize()", asMETHOD(Ogre::Image, getSize), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2051 r = engine->RegisterObjectMethod(
"Image",
"uint getWidth()", asMETHOD(Ogre::Image, getWidth), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2052 r = engine->RegisterObjectMethod(
"Image",
"uint getHeight()", asMETHOD(Ogre::Image, getHeight), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2053 r = engine->RegisterObjectMethod(
"Image",
"void resize(uint16 width, uint16 height, ImageFilter filter)", asMETHOD(Ogre::Image, resize), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2055 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
2060 engine->SetDefaultNamespace(
"Ogre");
2063 engine->RegisterObjectMethod(
"SubMesh",
"const string& getMaterialName()", asMETHOD(Ogre::SubMesh, getMaterialName), asCALL_THISCALL);
2064 engine->RegisterObjectMethod(
"SubMesh",
"void setMaterialName(const string&in, const string&in)", asMETHOD(Ogre::SubMesh, setMaterialName), asCALL_THISCALL);
2067 engine->RegisterObjectMethod(
"SubMesh",
"array<vector3>@ __getVertexPositions()", asFUNCTION(
SubMesh__getVertexPositions), asCALL_CDECL_OBJFIRST);
2068 engine->RegisterObjectMethod(
"SubMesh",
"array<vector2>@ __getVertexTexcoords(uint index)", asFUNCTION(
SubMesh__getVertexTexcoords), asCALL_CDECL_OBJFIRST);
2071 engine->RegisterObjectMethod(
"SubMesh",
"array<uint16>@ __getIndexBuffer16bit()", asFUNCTIONPR([](Ogre::SubMesh*
self) {
2072 const Ogre::HardwareIndexBuffer::IndexType desiredType = Ogre::HardwareIndexBuffer::IndexType::IT_16BIT;
2074 else {
App::GetScriptEngine()->SLOG(
"SubMesh::__getIndexBuffer16bit(): The buffer format isn't 16bit.");
return (CScriptArray*)
nullptr; }
2075 }, (Ogre::SubMesh*), CScriptArray*), asCALL_CDECL_OBJFIRST);
2076 engine->RegisterObjectMethod(
"SubMesh",
"array<uint>@ __getIndexBuffer32bit()", asFUNCTIONPR([](Ogre::SubMesh*
self) {
2077 const Ogre::HardwareIndexBuffer::IndexType desiredType = Ogre::HardwareIndexBuffer::IndexType::IT_32BIT;
2079 else {
App::GetScriptEngine()->SLOG(
"SubMesh::__getIndexBuffer32bit(): The buffer format isn't 32bit.");
return (CScriptArray*)
nullptr; }
2080 }, (Ogre::SubMesh*), CScriptArray*), asCALL_CDECL_OBJFIRST);
2081 engine->RegisterObjectMethod(
"SubMesh",
"IndexType __getIndexType()", asFUNCTION(
SubMesh__getIndexType), asCALL_CDECL_OBJFIRST);
2083 engine->SetDefaultNamespace(
"");
2089 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2092 r = engine->RegisterObjectBehaviour(
"MeshPtr", asBEHAVE_CONSTRUCT,
"void f(const MeshPtr&in)", asFUNCTION(
MeshPtrCopyConstructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2093 r = engine->RegisterObjectBehaviour(
"MeshPtr", asBEHAVE_DESTRUCT,
"void f()", asFUNCTION(
MeshPtrDestructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2094 r = engine->RegisterObjectMethod(
"MeshPtr",
"MeshPtr& opAssign(const MeshPtr&in)", asFUNCTION(
MeshPtrAssignOperator), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2095 r = engine->RegisterObjectMethod(
"MeshPtr",
"bool isNull()", asFUNCTION(
MeshPtrIsNull), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2098 r = engine->RegisterObjectMethod(
"MeshPtr",
"SubMeshArray@ getSubMeshes()", asFUNCTION(
MeshPtrGetSubmeshes), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2099 r = engine->RegisterObjectMethod(
"MeshPtr",
"string getName()", asFUNCTIONPR([](MeshPtr
const&
self) {
2100 return self->getName();
2101 }, (MeshPtr
const&), Ogre::String), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2102 r = engine->RegisterObjectMethod(
"MeshPtr",
"SubMesh@ createSubMesh(const string&in name)", asFUNCTIONPR([](MeshPtr
const&
self,
const Ogre::String& name) {
2103 return self->createSubMesh(name);
2104 }, (MeshPtr
const&,
const Ogre::String&), Ogre::SubMesh*), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2105 r = engine->RegisterObjectMethod(
"MeshPtr",
"void destroySubMesh(const string&in name)", asFUNCTIONPR([](MeshPtr
const&
self,
const Ogre::String& name) {
2106 self->createSubMesh(name);
2107 }, (MeshPtr
const&,
const Ogre::String&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2109 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
2115 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2117 r = engine->RegisterObjectMethod(
"MeshManager",
"MeshPtr load(const string&in file, const string&in rg)", asFUNCTIONPR([](MeshManager& mgr, std::string
const&
file, std::string
const& rg){
2118 try {
return mgr.load(
file, rg); }
2120 }, (MeshManager& mgr, std::string
const&
file, std::string
const& rg), MeshPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2122 r = engine->RegisterObjectMethod(
"MeshManager",
"void remove(const string&in file, const string&in rg)", asFUNCTIONPR([](MeshManager& mgr, std::string
const&
file, std::string
const& rg){
2123 try { mgr.remove(
file, rg); }
2125 }, (MeshManager& mgr, std::string
const&
file, std::string
const& rg),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2127 r = engine->SetDefaultNamespace(
"Ogre::MeshManager");
ROR_ASSERT(r >= 0);
2128 r = engine->RegisterGlobalFunction(
"MeshManager& getSingleton()", asFUNCTION(MeshManager::getSingleton), asCALL_CDECL);
ROR_ASSERT(r >= 0);
2130 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
2136 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2138 r = engine->RegisterObjectMethod(
"MaterialManager",
"MaterialPtr getByName(const string&in file, const string&in rg)", asFUNCTIONPR([](MaterialManager& mgr, std::string
const&
file, std::string
const& rg){
2139 try {
return mgr.getByName(
file, rg); }
2141 }, (MaterialManager& mgr, std::string
const&
file, std::string
const& rg), MaterialPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2143 r = engine->RegisterObjectMethod(
"MaterialManager",
"void create(const string&in file, const string&in rg)", asFUNCTIONPR([](MaterialManager& mgr, std::string
const&
file, std::string
const& rg){
2144 try {
return mgr.create(
file, rg); }
2146 }, (MaterialManager& mgr, std::string
const&
file, std::string
const& rg), MaterialPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2148 r = engine->SetDefaultNamespace(
"Ogre::MaterialManager");
ROR_ASSERT(r >= 0);
2149 r = engine->RegisterGlobalFunction(
"MaterialManager& getSingleton()", asFUNCTION(MaterialManager::getSingleton), asCALL_CDECL);
ROR_ASSERT(r >= 0);
2151 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
2157 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2160 r = engine->RegisterObjectBehaviour(
"MaterialPtr", asBEHAVE_CONSTRUCT,
"void f(const MaterialPtr&in)", asFUNCTION(
MaterialPtrCopyConstructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2161 r = engine->RegisterObjectBehaviour(
"MaterialPtr", asBEHAVE_DESTRUCT,
"void f()", asFUNCTION(
MaterialPtrDestructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2162 r = engine->RegisterObjectMethod(
"MaterialPtr",
"MaterialPtr& opAssign(const MaterialPtr&in)", asFUNCTION(
MaterialPtrAssignOperator), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2163 r = engine->RegisterObjectMethod(
"MaterialPtr",
"bool isNull()", asFUNCTION(
MaterialPtrIsNull), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2168 r = engine->RegisterObjectMethod(
"MaterialPtr",
"string getName()", asFUNCTIONPR([](MaterialPtr
const&
self) {
2169 return self->getName();
2170 }, (MaterialPtr
const&), Ogre::String), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2172 r = engine->RegisterObjectMethod(
"MaterialPtr",
"Technique@ createTechnique()", asFUNCTIONPR([](MaterialPtr
const&
self) {
2173 try {
return self->createTechnique(); }
2175 }, (MaterialPtr
const&), Ogre::Technique*), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2177 r = engine->RegisterObjectMethod(
"MaterialPtr",
"void removeTechnique()", asFUNCTIONPR([](MaterialPtr
const&
self, uint16_t index) {
2178 try {
self->removeTechnique(index); }
2180 }, (MaterialPtr
const&, uint16_t),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2182 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
2187 engine->SetDefaultNamespace(
"Ogre");
2189 engine->RegisterObjectMethod(
"Technique",
"PassArray @getPasses()", asFUNCTION(
TechniqueGetPasses), asCALL_CDECL_OBJFIRST);
2190 engine->RegisterObjectMethod(
"Technique",
"Pass @createPass()", asMETHOD(Ogre::Technique, createPass), asCALL_THISCALL);
2191 engine->RegisterObjectMethod(
"Technique",
"void removePass(uint16 index)", asMETHOD(Ogre::Technique, removePass), asCALL_THISCALL);
2192 engine->RegisterObjectMethod(
"Technique",
"const string& getName() const", asMETHOD(Ogre::Technique, getName), asCALL_THISCALL);
2194 engine->SetDefaultNamespace(
"");
2200 engine->SetDefaultNamespace(
"Ogre");
2202 engine->RegisterObjectMethod(
"Pass",
"const string& getName() const", asMETHOD(Ogre::Pass, getName), asCALL_THISCALL);
2203 engine->RegisterObjectMethod(
"Pass",
"TextureUnitStateArray @getTextureUnitStates()", asFUNCTION(
PassGetTextureUnitStates), asCALL_CDECL_OBJFIRST);
2204 engine->RegisterObjectMethod(
"Pass",
"void removeTextureUnitState(uint16 index)", asMETHOD(Ogre::Pass, removeTextureUnitState), asCALL_THISCALL);
2206 r = engine->RegisterObjectMethod(
"Pass",
"GpuProgramParametersPtr getVertexProgramParameters()", asFUNCTIONPR([](Ogre::Pass*
self) -> Ogre::GpuProgramParametersPtr {
2207 try {
return self->getVertexProgramParameters(); }
2209 }, (Ogre::Pass*), Ogre::GpuProgramParametersPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2211 r = engine->RegisterObjectMethod(
"Pass",
"GpuProgramParametersPtr getFragmentProgramParameters()", asFUNCTIONPR([](Ogre::Pass*
self) -> Ogre::GpuProgramParametersPtr {
2212 try {
return self->getFragmentProgramParameters(); }
2214 }, (Ogre::Pass*), Ogre::GpuProgramParametersPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2216 r = engine->RegisterObjectMethod(
"Pass",
"GpuProgramParametersPtr getGeometryProgramParameters()", asFUNCTIONPR([](Ogre::Pass*
self) -> Ogre::GpuProgramParametersPtr {
2217 try {
return self->getGeometryProgramParameters(); }
2219 }, (Ogre::Pass*), Ogre::GpuProgramParametersPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2221 r = engine->RegisterObjectMethod(
"Pass",
"GpuProgramParametersPtr getTessellationHullProgramParameters()", asFUNCTIONPR([](Ogre::Pass*
self) -> Ogre::GpuProgramParametersPtr {
2222 try {
return self->getTessellationHullProgramParameters(); }
2224 }, (Ogre::Pass*), Ogre::GpuProgramParametersPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2226 r = engine->RegisterObjectMethod(
"Pass",
"GpuProgramParametersPtr getTessellationDomainProgramParameters()", asFUNCTIONPR([](Ogre::Pass*
self) -> Ogre::GpuProgramParametersPtr {
2227 try {
return self->getTessellationDomainProgramParameters(); }
2229 }, (Ogre::Pass*), Ogre::GpuProgramParametersPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2231 r = engine->RegisterObjectMethod(
"Pass",
"GpuProgramParametersPtr getComputeProgramParameters()", asFUNCTIONPR([](Ogre::Pass*
self) -> Ogre::GpuProgramParametersPtr {
2232 try {
return self->getComputeProgramParameters(); }
2234 }, (Ogre::Pass*), Ogre::GpuProgramParametersPtr), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2236 engine->RegisterObjectMethod(
"Pass",
"void setVertexProgramParameters(GpuProgramParametersPtr)", asMETHOD(Ogre::Pass, setVertexProgramParameters), asCALL_THISCALL);
2237 engine->RegisterObjectMethod(
"Pass",
"void setFragmentProgramParameters(GpuProgramParametersPtr)", asMETHOD(Ogre::Pass, setFragmentProgramParameters), asCALL_THISCALL);
2238 engine->RegisterObjectMethod(
"Pass",
"void setGeometryProgramParameters(GpuProgramParametersPtr)", asMETHOD(Ogre::Pass, setGeometryProgramParameters), asCALL_THISCALL);
2239 engine->RegisterObjectMethod(
"Pass",
"void setTessellationHullProgramParameters(GpuProgramParametersPtr)", asMETHOD(Ogre::Pass, setTessellationHullProgramParameters), asCALL_THISCALL);
2240 engine->RegisterObjectMethod(
"Pass",
"void setTessellationDomainProgramParameters(GpuProgramParametersPtr)", asMETHOD(Ogre::Pass, setTessellationDomainProgramParameters), asCALL_THISCALL);
2241 engine->RegisterObjectMethod(
"Pass",
"void setComputeProgramParameters(GpuProgramParametersPtr)", asMETHOD(Ogre::Pass, setComputeProgramParameters), asCALL_THISCALL);
2243 engine->SetDefaultNamespace(
"");
2248 engine->SetDefaultNamespace(
"Ogre");
2250 engine->RegisterObjectMethod(
"TextureUnitState",
"const string& getName() const", asMETHOD(Ogre::TextureUnitState, getName), asCALL_THISCALL);
2251 engine->RegisterObjectMethod(
"TextureUnitState",
"void setTexture(const TexturePtr&in)", asMETHODPR(Ogre::TextureUnitState, setTexture, (
const TexturePtr&),
void), asCALL_THISCALL);
2252 engine->RegisterObjectMethod(
"TextureUnitState",
"const TexturePtr& _getTexturePtr() const", asMETHODPR(Ogre::TextureUnitState, _getTexturePtr, (
void)
const,
const TexturePtr&), asCALL_THISCALL);
2254 engine->SetDefaultNamespace(
"");
2260 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2263 r = engine->RegisterObjectBehaviour(
"Timer", asBEHAVE_CONSTRUCT,
"void f(const Timer&in)", asFUNCTION(
TimerCopyConstructor), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2265 r = engine->RegisterObjectMethod(
"Timer",
"Timer& opAssign(const Timer&in)", asFUNCTION(
TimerAssignOperator), asCALL_CDECL_OBJLAST);
ROR_ASSERT(r >= 0);
2267 r = engine->RegisterObjectMethod(
"Timer",
"void reset()", asMETHOD(Timer, reset), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2268 r = engine->RegisterObjectMethod(
"Timer",
"uint getMilliseconds()", asMETHOD(Timer, getMilliseconds), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2269 r = engine->RegisterObjectMethod(
"Timer",
"uint getMicroseconds()", asMETHOD(Timer, getMicroseconds), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2270 r = engine->RegisterObjectMethod(
"Timer",
"uint getMillisecondsCPU()", asMETHOD(Timer, getMillisecondsCPU), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2271 r = engine->RegisterObjectMethod(
"Timer",
"uint getMicrosecondsCPU()", asMETHOD(Timer, getMicrosecondsCPU), asCALL_THISCALL);
ROR_ASSERT(r >= 0);
2273 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);
2280 r = engine->SetDefaultNamespace(
"Ogre");
ROR_ASSERT(r >= 0);
2292 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, float val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index,
float val) {
2293 try {
self->setConstant(index, val); }
2295 }, (GpuProgramParametersPtr
const&, asUINT, float),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2296 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, const vector3& val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index,
const Ogre::Vector3& val) {
2297 try {
self->setConstant(index, val); }
2299 }, (GpuProgramParametersPtr
const&, asUINT,
const Ogre::Vector3&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2300 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, const vector2& val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index,
const Ogre::Vector2& val) {
2301 try {
self->setConstant(index, val); }
2303 }, (GpuProgramParametersPtr
const&, asUINT,
const Ogre::Vector2&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2304 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, const color& val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index,
const Ogre::ColourValue& val) {
2305 try {
self->setConstant(index, val); }
2307 }, (GpuProgramParametersPtr
const&, asUINT,
const Ogre::ColourValue&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2310 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, const array<float>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index, CScriptArray* vals) {
2312 try {
self->setConstant(index, (
float*)vals->GetBuffer(), vals->GetSize()); }
2314 }, (GpuProgramParametersPtr
const&, asUINT, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2315 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, const array<vector3>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index, CScriptArray* vals) {
2317 try {
self->setConstant(index, (
float*)vals->GetBuffer(), vals->GetSize()*3); }
2319 }, (GpuProgramParametersPtr
const&, asUINT, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2320 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, const array<vector2>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index, CScriptArray* vals) {
2322 try {
self->setConstant(index, (
float*)vals->GetBuffer(), vals->GetSize()*2); }
2324 }, (GpuProgramParametersPtr
const&, asUINT, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2325 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setConstant(uint index, const array<color>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self, asUINT index, CScriptArray* vals) {
2327 try {
self->setConstant(index, (
float*)vals->GetBuffer(), vals->GetSize()*4); }
2329 }, (GpuProgramParametersPtr
const&, asUINT, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2332 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, float val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name,
float val) {
2333 try {
self->setNamedConstant(name, val); }
2335 }, (GpuProgramParametersPtr
const&,
const std::string&, float),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2336 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, const vector3& val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name,
const Ogre::Vector3& val) {
2337 try {
self->setNamedConstant(name, val); }
2339 }, (GpuProgramParametersPtr
const&,
const std::string&,
const Ogre::Vector3&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2340 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, const vector2& val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name,
const Ogre::Vector2& val) {
2341 try {
self->setNamedConstant(name, val); }
2343 }, (GpuProgramParametersPtr
const&,
const std::string&,
const Ogre::Vector2&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2344 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, const color& val)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name,
const Ogre::ColourValue& val) {
2345 try {
self->setNamedConstant(name, val); }
2347 }, (GpuProgramParametersPtr
const&,
const std::string&,
const Ogre::ColourValue&),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2350 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, const array<float>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name, CScriptArray* vals) {
2352 try {
self->setNamedConstant(name, (
float*)vals->GetBuffer(), vals->GetSize()); }
2354 }, (GpuProgramParametersPtr
const&,
const std::string&, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2355 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, const array<vector3>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name, CScriptArray* vals) {
2357 try {
self->setNamedConstant(name, (
float*)vals->GetBuffer(), vals->GetSize()*3); }
2359 }, (GpuProgramParametersPtr
const&,
const std::string&, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2360 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, const array<vector2>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name, CScriptArray* vals) {
2362 try {
self->setNamedConstant(name, (
float*)vals->GetBuffer(), vals->GetSize()*2); }
2364 }, (GpuProgramParametersPtr
const&,
const std::string&, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2365 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"void setNamedConstant(const string&in name, const array<color>@ vals)", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self,
const std::string& name, CScriptArray* vals) {
2367 try {
self->setNamedConstant(name, (
float*)vals->GetBuffer(), vals->GetSize()*4); }
2369 }, (GpuProgramParametersPtr
const&,
const std::string&, CScriptArray*),
void), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2371 r = engine->RegisterObjectMethod(
"GpuProgramParametersPtr",
"array<string>@ __getNamedConstants()", asFUNCTIONPR([](GpuProgramParametersPtr
const&
self) -> CScriptArray* {
2373 std::vector<std::string> keys;
2374 const Ogre::GpuNamedConstants& namedConstants =
self->getConstantDefinitions();
2375 for (
auto& pair : namedConstants.map)
2376 keys.push_back(pair.first);
2382 }, (GpuProgramParametersPtr
const&), CScriptArray*), asCALL_CDECL_OBJFIRST);
ROR_ASSERT(r >= 0);
2385 r = engine->SetDefaultNamespace(
"");
ROR_ASSERT(r >= 0);