diff --git a/Autogenerated/Bindings/Go/lib3mf.go b/Autogenerated/Bindings/Go/lib3mf.go index aeac95c81..2c6e1527d 100644 --- a/Autogenerated/Bindings/Go/lib3mf.go +++ b/Autogenerated/Bindings/Go/lib3mf.go @@ -39,3268 +39,7 @@ package lib3mf /* #cgo linux LDFLAGS: -ldl -#include "lib3mf_dynamic.cc" - -Lib3MFHandle loadLib3MFLibrary (const char * pFileName) -{ - Lib3MFResult nResult; - sLib3MFDynamicWrapperTable * pWrapperTable = (sLib3MFDynamicWrapperTable *) malloc (sizeof (sLib3MFDynamicWrapperTable)); - if (pWrapperTable != NULL) { - nResult = InitLib3MFWrapperTable (pWrapperTable); - if (nResult != LIB3MF_SUCCESS) { - free (pWrapperTable); - return 0; - } - - nResult = LoadLib3MFWrapperTable (pWrapperTable, pFileName); - if (nResult != LIB3MF_SUCCESS) { - free (pWrapperTable); - return 0; - } - - return (Lib3MFHandle) pWrapperTable; - } -} - -void unloadLib3MFLibrary (Lib3MFHandle nLibraryHandle) -{ - sLib3MFDynamicWrapperTable * pWrapperTable = (sLib3MFDynamicWrapperTable *) malloc (sizeof (sLib3MFDynamicWrapperTable)); - if (pWrapperTable != NULL) { - ReleaseLib3MFWrapperTable (pWrapperTable); - free (pWrapperTable); - } -} - - -Lib3MFResult CCall_lib3mf_base_classtypeid(Lib3MFHandle libraryHandle, Lib3MF_Base pBase, Lib3MF_uint64 * pClassTypeId) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Base_ClassTypeId (pBase, pClassTypeId); -} - - -Lib3MFResult CCall_lib3mf_writer_writetofile(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, const char * pFilename) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_WriteToFile (pWriter, pFilename); -} - - -Lib3MFResult CCall_lib3mf_writer_getstreamsize(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint64 * pStreamSize) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_GetStreamSize (pWriter, pStreamSize); -} - - -Lib3MFResult CCall_lib3mf_writer_writetobuffer(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, const Lib3MF_uint64 nBufferBufferSize, Lib3MF_uint64* pBufferNeededCount, Lib3MF_uint8 * pBufferBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_WriteToBuffer (pWriter, nBufferBufferSize, pBufferNeededCount, pBufferBuffer); -} - - -Lib3MFResult CCall_lib3mf_writer_writetocallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MFWriteCallback pTheWriteCallback, Lib3MFSeekCallback pTheSeekCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_WriteToCallback (pWriter, pTheWriteCallback, pTheSeekCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_writer_setprogresscallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MFProgressCallback pProgressCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_SetProgressCallback (pWriter, pProgressCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_writer_getdecimalprecision(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 * pDecimalPrecision) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_GetDecimalPrecision (pWriter, pDecimalPrecision); -} - - -Lib3MFResult CCall_lib3mf_writer_setdecimalprecision(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 nDecimalPrecision) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_SetDecimalPrecision (pWriter, nDecimalPrecision); -} - - -Lib3MFResult CCall_lib3mf_writer_setstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, bool bStrictModeActive) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_SetStrictModeActive (pWriter, bStrictModeActive); -} - - -Lib3MFResult CCall_lib3mf_writer_getstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, bool * pStrictModeActive) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_GetStrictModeActive (pWriter, pStrictModeActive); -} - - -Lib3MFResult CCall_lib3mf_writer_getwarning(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 nIndex, Lib3MF_uint32 * pErrorCode, const Lib3MF_uint32 nWarningBufferSize, Lib3MF_uint32* pWarningNeededChars, char * pWarningBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_GetWarning (pWriter, nIndex, pErrorCode, nWarningBufferSize, pWarningNeededChars, pWarningBuffer); -} - - -Lib3MFResult CCall_lib3mf_writer_getwarningcount(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_GetWarningCount (pWriter, pCount); -} - - -Lib3MFResult CCall_lib3mf_writer_addkeywrappingcallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, const char * pConsumerID, Lib3MFKeyWrappingCallback pTheCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_AddKeyWrappingCallback (pWriter, pConsumerID, pTheCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_writer_setcontentencryptioncallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MFContentEncryptionCallback pTheCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Writer_SetContentEncryptionCallback (pWriter, pTheCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_reader_readfromfile(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pFilename) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_ReadFromFile (pReader, pFilename); -} - - -Lib3MFResult CCall_lib3mf_reader_readfrombuffer(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint64 nBufferBufferSize, const Lib3MF_uint8 * pBufferBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_ReadFromBuffer (pReader, nBufferBufferSize, pBufferBuffer); -} - - -Lib3MFResult CCall_lib3mf_reader_readfromcallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MFReadCallback pTheReadCallback, Lib3MF_uint64 nStreamSize, Lib3MFSeekCallback pTheSeekCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_ReadFromCallback (pReader, pTheReadCallback, nStreamSize, pTheSeekCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_reader_setprogresscallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MFProgressCallback pProgressCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_SetProgressCallback (pReader, pProgressCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_reader_addrelationtoread(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pRelationShipType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_AddRelationToRead (pReader, pRelationShipType); -} - - -Lib3MFResult CCall_lib3mf_reader_removerelationtoread(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pRelationShipType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_RemoveRelationToRead (pReader, pRelationShipType); -} - - -Lib3MFResult CCall_lib3mf_reader_setstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, bool bStrictModeActive) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_SetStrictModeActive (pReader, bStrictModeActive); -} - - -Lib3MFResult CCall_lib3mf_reader_getstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, bool * pStrictModeActive) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_GetStrictModeActive (pReader, pStrictModeActive); -} - - -Lib3MFResult CCall_lib3mf_reader_getwarning(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint32 nIndex, Lib3MF_uint32 * pErrorCode, const Lib3MF_uint32 nWarningBufferSize, Lib3MF_uint32* pWarningNeededChars, char * pWarningBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_GetWarning (pReader, nIndex, pErrorCode, nWarningBufferSize, pWarningNeededChars, pWarningBuffer); -} - - -Lib3MFResult CCall_lib3mf_reader_getwarningcount(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_GetWarningCount (pReader, pCount); -} - - -Lib3MFResult CCall_lib3mf_reader_addkeywrappingcallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pConsumerID, Lib3MFKeyWrappingCallback pTheCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_AddKeyWrappingCallback (pReader, pConsumerID, pTheCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_reader_setcontentencryptioncallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MFContentEncryptionCallback pTheCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Reader_SetContentEncryptionCallback (pReader, pTheCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_packagepart_getpath(Lib3MFHandle libraryHandle, Lib3MF_PackagePart pPackagePart, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_PackagePart_GetPath (pPackagePart, nPathBufferSize, pPathNeededChars, pPathBuffer); -} - - -Lib3MFResult CCall_lib3mf_packagepart_setpath(Lib3MFHandle libraryHandle, Lib3MF_PackagePart pPackagePart, const char * pPath) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_PackagePart_SetPath (pPackagePart, pPath); -} - - -Lib3MFResult CCall_lib3mf_resource_getresourceid(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32 * pUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Resource_GetResourceID (pResource, pUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_resource_getuniqueresourceid(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32 * pUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Resource_GetUniqueResourceID (pResource, pUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_resource_packagepart(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_PackagePart * pPackagePart) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Resource_PackagePart (pResource, pPackagePart); -} - - -Lib3MFResult CCall_lib3mf_resource_setpackagepart(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_PackagePart pPackagePart) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Resource_SetPackagePart (pResource, pPackagePart); -} - - -Lib3MFResult CCall_lib3mf_resource_getmodelresourceid(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32 * pModelResourceId) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Resource_GetModelResourceID (pResource, pModelResourceId); -} - - -Lib3MFResult CCall_lib3mf_resourceiterator_movenext(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, bool * pHasNext) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceIterator_MoveNext (pResourceIterator, pHasNext); -} - - -Lib3MFResult CCall_lib3mf_resourceiterator_moveprevious(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, bool * pHasPrevious) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceIterator_MovePrevious (pResourceIterator, pHasPrevious); -} - - -Lib3MFResult CCall_lib3mf_resourceiterator_getcurrent(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_Resource * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceIterator_GetCurrent (pResourceIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_resourceiterator_clone(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_ResourceIterator * pOutResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceIterator_Clone (pResourceIterator, pOutResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_resourceiterator_count(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceIterator_Count (pResourceIterator, pCount); -} - - -Lib3MFResult CCall_lib3mf_slicestackiterator_getcurrentslicestack(Lib3MFHandle libraryHandle, Lib3MF_SliceStackIterator pSliceStackIterator, Lib3MF_SliceStack * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStackIterator_GetCurrentSliceStack (pSliceStackIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_objectiterator_getcurrentobject(Lib3MFHandle libraryHandle, Lib3MF_ObjectIterator pObjectIterator, Lib3MF_Object * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ObjectIterator_GetCurrentObject (pObjectIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_meshobjectiterator_getcurrentmeshobject(Lib3MFHandle libraryHandle, Lib3MF_MeshObjectIterator pMeshObjectIterator, Lib3MF_MeshObject * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObjectIterator_GetCurrentMeshObject (pMeshObjectIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_componentsobjectiterator_getcurrentcomponentsobject(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObjectIterator pComponentsObjectIterator, Lib3MF_ComponentsObject * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ComponentsObjectIterator_GetCurrentComponentsObject (pComponentsObjectIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_texture2diterator_getcurrenttexture2d(Lib3MFHandle libraryHandle, Lib3MF_Texture2DIterator pTexture2DIterator, Lib3MF_Texture2D * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DIterator_GetCurrentTexture2D (pTexture2DIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroupiterator_getcurrentbasematerialgroup(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroupIterator pBaseMaterialGroupIterator, Lib3MF_BaseMaterialGroup * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroupIterator_GetCurrentBaseMaterialGroup (pBaseMaterialGroupIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_colorgroupiterator_getcurrentcolorgroup(Lib3MFHandle libraryHandle, Lib3MF_ColorGroupIterator pColorGroupIterator, Lib3MF_ColorGroup * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorGroupIterator_GetCurrentColorGroup (pColorGroupIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_texture2dgroupiterator_getcurrenttexture2dgroup(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroupIterator pTexture2DGroupIterator, Lib3MF_Texture2DGroup * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DGroupIterator_GetCurrentTexture2DGroup (pTexture2DGroupIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_compositematerialsiterator_getcurrentcompositematerials(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterialsIterator pCompositeMaterialsIterator, Lib3MF_CompositeMaterials * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CompositeMaterialsIterator_GetCurrentCompositeMaterials (pCompositeMaterialsIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroupiterator_getcurrentmultipropertygroup(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroupIterator pMultiPropertyGroupIterator, Lib3MF_MultiPropertyGroup * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroupIterator_GetCurrentMultiPropertyGroup (pMultiPropertyGroupIterator, pResource); -} - - -Lib3MFResult CCall_lib3mf_metadata_getnamespace(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nNameSpaceBufferSize, Lib3MF_uint32* pNameSpaceNeededChars, char * pNameSpaceBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_GetNameSpace (pMetaData, nNameSpaceBufferSize, pNameSpaceNeededChars, pNameSpaceBuffer); -} - - -Lib3MFResult CCall_lib3mf_metadata_setnamespace(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pNameSpace) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_SetNameSpace (pMetaData, pNameSpace); -} - - -Lib3MFResult CCall_lib3mf_metadata_getname(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_GetName (pMetaData, nNameBufferSize, pNameNeededChars, pNameBuffer); -} - - -Lib3MFResult CCall_lib3mf_metadata_setname(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pName) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_SetName (pMetaData, pName); -} - - -Lib3MFResult CCall_lib3mf_metadata_getkey(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nKeyBufferSize, Lib3MF_uint32* pKeyNeededChars, char * pKeyBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_GetKey (pMetaData, nKeyBufferSize, pKeyNeededChars, pKeyBuffer); -} - - -Lib3MFResult CCall_lib3mf_metadata_getmustpreserve(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, bool * pMustPreserve) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_GetMustPreserve (pMetaData, pMustPreserve); -} - - -Lib3MFResult CCall_lib3mf_metadata_setmustpreserve(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, bool bMustPreserve) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_SetMustPreserve (pMetaData, bMustPreserve); -} - - -Lib3MFResult CCall_lib3mf_metadata_gettype(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nTypeBufferSize, Lib3MF_uint32* pTypeNeededChars, char * pTypeBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_GetType (pMetaData, nTypeBufferSize, pTypeNeededChars, pTypeBuffer); -} - - -Lib3MFResult CCall_lib3mf_metadata_settype(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_SetType (pMetaData, pType); -} - - -Lib3MFResult CCall_lib3mf_metadata_getvalue(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nValueBufferSize, Lib3MF_uint32* pValueNeededChars, char * pValueBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_GetValue (pMetaData, nValueBufferSize, pValueNeededChars, pValueBuffer); -} - - -Lib3MFResult CCall_lib3mf_metadata_setvalue(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pValue) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaData_SetValue (pMetaData, pValue); -} - - -Lib3MFResult CCall_lib3mf_metadatagroup_getmetadatacount(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaDataGroup_GetMetaDataCount (pMetaDataGroup, pCount); -} - - -Lib3MFResult CCall_lib3mf_metadatagroup_getmetadata(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 nIndex, Lib3MF_MetaData * pMetaData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaDataGroup_GetMetaData (pMetaDataGroup, nIndex, pMetaData); -} - - -Lib3MFResult CCall_lib3mf_metadatagroup_getmetadatabykey(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, const char * pNameSpace, const char * pName, Lib3MF_MetaData * pMetaData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaDataGroup_GetMetaDataByKey (pMetaDataGroup, pNameSpace, pName, pMetaData); -} - - -Lib3MFResult CCall_lib3mf_metadatagroup_removemetadatabyindex(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 nIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaDataGroup_RemoveMetaDataByIndex (pMetaDataGroup, nIndex); -} - - -Lib3MFResult CCall_lib3mf_metadatagroup_removemetadata(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_MetaData pTheMetaData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaDataGroup_RemoveMetaData (pMetaDataGroup, pTheMetaData); -} - - -Lib3MFResult CCall_lib3mf_metadatagroup_addmetadata(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, const char * pNameSpace, const char * pName, const char * pValue, const char * pType, bool bMustPreserve, Lib3MF_MetaData * pMetaData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MetaDataGroup_AddMetaData (pMetaDataGroup, pNameSpace, pName, pValue, pType, bMustPreserve, pMetaData); -} - - -Lib3MFResult CCall_lib3mf_object_gettype(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFObjectType * pObjectType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetType (pObject, pObjectType); -} - - -Lib3MFResult CCall_lib3mf_object_settype(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFObjectType eObjectType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_SetType (pObject, eObjectType); -} - - -Lib3MFResult CCall_lib3mf_object_getname(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetName (pObject, nNameBufferSize, pNameNeededChars, pNameBuffer); -} - - -Lib3MFResult CCall_lib3mf_object_setname(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char * pName) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_SetName (pObject, pName); -} - - -Lib3MFResult CCall_lib3mf_object_getpartnumber(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const Lib3MF_uint32 nPartNumberBufferSize, Lib3MF_uint32* pPartNumberNeededChars, char * pPartNumberBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetPartNumber (pObject, nPartNumberBufferSize, pPartNumberNeededChars, pPartNumberBuffer); -} - - -Lib3MFResult CCall_lib3mf_object_setpartnumber(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char * pPartNumber) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_SetPartNumber (pObject, pPartNumber); -} - - -Lib3MFResult CCall_lib3mf_object_ismeshobject(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pIsMeshObject) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_IsMeshObject (pObject, pIsMeshObject); -} - - -Lib3MFResult CCall_lib3mf_object_iscomponentsobject(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pIsComponentsObject) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_IsComponentsObject (pObject, pIsComponentsObject); -} - - -Lib3MFResult CCall_lib3mf_object_isvalid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pIsValid) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_IsValid (pObject, pIsValid); -} - - -Lib3MFResult CCall_lib3mf_object_setattachmentasthumbnail(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_Attachment pAttachment) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_SetAttachmentAsThumbnail (pObject, pAttachment); -} - - -Lib3MFResult CCall_lib3mf_object_getthumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_Attachment * pAttachment) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetThumbnailAttachment (pObject, pAttachment); -} - - -Lib3MFResult CCall_lib3mf_object_clearthumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Object pObject) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_ClearThumbnailAttachment (pObject); -} - - -Lib3MFResult CCall_lib3mf_object_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, sLib3MFBox * pOutbox) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetOutbox (pObject, pOutbox); -} - - -Lib3MFResult CCall_lib3mf_object_getuuid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetUUID (pObject, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_object_setuuid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char * pUUID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_SetUUID (pObject, pUUID); -} - - -Lib3MFResult CCall_lib3mf_object_getmetadatagroup(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_MetaDataGroup * pMetaDataGroup) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetMetaDataGroup (pObject, pMetaDataGroup); -} - - -Lib3MFResult CCall_lib3mf_object_setslicesmeshresolution(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFSlicesMeshResolution eMeshResolution) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_SetSlicesMeshResolution (pObject, eMeshResolution); -} - - -Lib3MFResult CCall_lib3mf_object_getslicesmeshresolution(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFSlicesMeshResolution * pMeshResolution) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetSlicesMeshResolution (pObject, pMeshResolution); -} - - -Lib3MFResult CCall_lib3mf_object_hasslices(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool bRecursive, bool * pHasSlices) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_HasSlices (pObject, bRecursive, pHasSlices); -} - - -Lib3MFResult CCall_lib3mf_object_clearslicestack(Lib3MFHandle libraryHandle, Lib3MF_Object pObject) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_ClearSliceStack (pObject); -} - - -Lib3MFResult CCall_lib3mf_object_getslicestack(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_SliceStack * pSliceStackInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_GetSliceStack (pObject, pSliceStackInstance); -} - - -Lib3MFResult CCall_lib3mf_object_assignslicestack(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_SliceStack pSliceStackInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Object_AssignSliceStack (pObject, pSliceStackInstance); -} - - -Lib3MFResult CCall_lib3mf_meshobject_getvertexcount(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 * pVertexCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetVertexCount (pMeshObject, pVertexCount); -} - - -Lib3MFResult CCall_lib3mf_meshobject_gettrianglecount(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 * pVertexCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetTriangleCount (pMeshObject, pVertexCount); -} - - -Lib3MFResult CCall_lib3mf_meshobject_getvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFPosition * pCoordinates) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetVertex (pMeshObject, nIndex, pCoordinates); -} - - -Lib3MFResult CCall_lib3mf_meshobject_setvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, const sLib3MFPosition * pCoordinates) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_SetVertex (pMeshObject, nIndex, pCoordinates); -} - - -Lib3MFResult CCall_lib3mf_meshobject_addvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const sLib3MFPosition * pCoordinates, Lib3MF_uint32 * pNewIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_AddVertex (pMeshObject, pCoordinates, pNewIndex); -} - - -Lib3MFResult CCall_lib3mf_meshobject_getvertices(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const Lib3MF_uint64 nVerticesBufferSize, Lib3MF_uint64* pVerticesNeededCount, sLib3MFPosition * pVerticesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetVertices (pMeshObject, nVerticesBufferSize, pVerticesNeededCount, pVerticesBuffer); -} - - -Lib3MFResult CCall_lib3mf_meshobject_gettriangle(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFTriangle * pIndices) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetTriangle (pMeshObject, nIndex, pIndices); -} - - -Lib3MFResult CCall_lib3mf_meshobject_settriangle(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, const sLib3MFTriangle * pIndices) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_SetTriangle (pMeshObject, nIndex, pIndices); -} - - -Lib3MFResult CCall_lib3mf_meshobject_addtriangle(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const sLib3MFTriangle * pIndices, Lib3MF_uint32 * pNewIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_AddTriangle (pMeshObject, pIndices, pNewIndex); -} - - -Lib3MFResult CCall_lib3mf_meshobject_gettriangleindices(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const Lib3MF_uint64 nIndicesBufferSize, Lib3MF_uint64* pIndicesNeededCount, sLib3MFTriangle * pIndicesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetTriangleIndices (pMeshObject, nIndicesBufferSize, pIndicesNeededCount, pIndicesBuffer); -} - - -Lib3MFResult CCall_lib3mf_meshobject_setobjectlevelproperty(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nUniqueResourceID, Lib3MF_uint32 nPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_SetObjectLevelProperty (pMeshObject, nUniqueResourceID, nPropertyID); -} - - -Lib3MFResult CCall_lib3mf_meshobject_getobjectlevelproperty(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 * pUniqueResourceID, Lib3MF_uint32 * pPropertyID, bool * pHasObjectLevelProperty) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetObjectLevelProperty (pMeshObject, pUniqueResourceID, pPropertyID, pHasObjectLevelProperty); -} - - -Lib3MFResult CCall_lib3mf_meshobject_settriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, const sLib3MFTriangleProperties * pProperties) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_SetTriangleProperties (pMeshObject, nIndex, pProperties); -} - - -Lib3MFResult CCall_lib3mf_meshobject_gettriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFTriangleProperties * pProperty) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetTriangleProperties (pMeshObject, nIndex, pProperty); -} - - -Lib3MFResult CCall_lib3mf_meshobject_setalltriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint64 nPropertiesArrayBufferSize, const sLib3MFTriangleProperties * pPropertiesArrayBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_SetAllTriangleProperties (pMeshObject, nPropertiesArrayBufferSize, pPropertiesArrayBuffer); -} - - -Lib3MFResult CCall_lib3mf_meshobject_getalltriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const Lib3MF_uint64 nPropertiesArrayBufferSize, Lib3MF_uint64* pPropertiesArrayNeededCount, sLib3MFTriangleProperties * pPropertiesArrayBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_GetAllTriangleProperties (pMeshObject, nPropertiesArrayBufferSize, pPropertiesArrayNeededCount, pPropertiesArrayBuffer); -} - - -Lib3MFResult CCall_lib3mf_meshobject_clearallproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_ClearAllProperties (pMeshObject); -} - - -Lib3MFResult CCall_lib3mf_meshobject_setgeometry(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint64 nVerticesBufferSize, const sLib3MFPosition * pVerticesBuffer, Lib3MF_uint64 nIndicesBufferSize, const sLib3MFTriangle * pIndicesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_SetGeometry (pMeshObject, nVerticesBufferSize, pVerticesBuffer, nIndicesBufferSize, pIndicesBuffer); -} - - -Lib3MFResult CCall_lib3mf_meshobject_ismanifoldandoriented(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, bool * pIsManifoldAndOriented) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_IsManifoldAndOriented (pMeshObject, pIsManifoldAndOriented); -} - - -Lib3MFResult CCall_lib3mf_meshobject_beamlattice(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_BeamLattice * pTheBeamLattice) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MeshObject_BeamLattice (pMeshObject, pTheBeamLattice); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getminlength(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_double * pMinLength) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetMinLength (pBeamLattice, pMinLength); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setminlength(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_double dMinLength) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetMinLength (pBeamLattice, dMinLength); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getclipping(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeClipMode * pClipMode, Lib3MF_uint32 * pUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetClipping (pBeamLattice, pClipMode, pUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setclipping(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeClipMode eClipMode, Lib3MF_uint32 nUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetClipping (pBeamLattice, eClipMode, nUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getrepresentation(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, bool * pHasRepresentation, Lib3MF_uint32 * pUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetRepresentation (pBeamLattice, pHasRepresentation, pUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setrepresentation(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetRepresentation (pBeamLattice, nUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getballoptions(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeBallMode * pBallMode, Lib3MF_double * pBallRadius) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBallOptions (pBeamLattice, pBallMode, pBallRadius); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setballoptions(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeBallMode eBallMode, Lib3MF_double dBallRadius) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetBallOptions (pBeamLattice, eBallMode, dBallRadius); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getbeamcount(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBeamCount (pBeamLattice, pCount); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getbeam(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, sLib3MFBeam * pBeamInfo) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBeam (pBeamLattice, nIndex, pBeamInfo); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_addbeam(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const sLib3MFBeam * pBeamInfo, Lib3MF_uint32 * pIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_AddBeam (pBeamLattice, pBeamInfo, pIndex); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setbeam(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, const sLib3MFBeam * pBeamInfo) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetBeam (pBeamLattice, nIndex, pBeamInfo); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setbeams(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint64 nBeamInfoBufferSize, const sLib3MFBeam * pBeamInfoBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetBeams (pBeamLattice, nBeamInfoBufferSize, pBeamInfoBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getbeams(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const Lib3MF_uint64 nBeamInfoBufferSize, Lib3MF_uint64* pBeamInfoNeededCount, sLib3MFBeam * pBeamInfoBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBeams (pBeamLattice, nBeamInfoBufferSize, pBeamInfoNeededCount, pBeamInfoBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getballcount(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBallCount (pBeamLattice, pCount); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getball(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, sLib3MFBall * pBallInfo) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBall (pBeamLattice, nIndex, pBallInfo); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_addball(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const sLib3MFBall * pBallInfo, Lib3MF_uint32 * pIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_AddBall (pBeamLattice, pBallInfo, pIndex); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setball(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, const sLib3MFBall * pBallInfo) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetBall (pBeamLattice, nIndex, pBallInfo); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_setballs(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint64 nBallInfoBufferSize, const sLib3MFBall * pBallInfoBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_SetBalls (pBeamLattice, nBallInfoBufferSize, pBallInfoBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getballs(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const Lib3MF_uint64 nBallInfoBufferSize, Lib3MF_uint64* pBallInfoNeededCount, sLib3MFBall * pBallInfoBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBalls (pBeamLattice, nBallInfoBufferSize, pBallInfoNeededCount, pBallInfoBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getbeamsetcount(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBeamSetCount (pBeamLattice, pCount); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_addbeamset(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_BeamSet * pBeamSet) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_AddBeamSet (pBeamLattice, pBeamSet); -} - - -Lib3MFResult CCall_lib3mf_beamlattice_getbeamset(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, Lib3MF_BeamSet * pBeamSet) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamLattice_GetBeamSet (pBeamLattice, nIndex, pBeamSet); -} - - -Lib3MFResult CCall_lib3mf_component_getobjectresource(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, Lib3MF_Object * pObjectResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Component_GetObjectResource (pComponent, pObjectResource); -} - - -Lib3MFResult CCall_lib3mf_component_getobjectresourceid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, Lib3MF_uint32 * pUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Component_GetObjectResourceID (pComponent, pUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_component_getuuid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Component_GetUUID (pComponent, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_component_setuuid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, const char * pUUID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Component_SetUUID (pComponent, pUUID); -} - - -Lib3MFResult CCall_lib3mf_component_hastransform(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, bool * pHasTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Component_HasTransform (pComponent, pHasTransform); -} - - -Lib3MFResult CCall_lib3mf_component_gettransform(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Component_GetTransform (pComponent, pTransform); -} - - -Lib3MFResult CCall_lib3mf_component_settransform(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, const sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Component_SetTransform (pComponent, pTransform); -} - - -Lib3MFResult CCall_lib3mf_componentsobject_addcomponent(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObject pComponentsObject, Lib3MF_Object pObjectResource, const sLib3MFTransform * pTransform, Lib3MF_Component * pComponentInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ComponentsObject_AddComponent (pComponentsObject, pObjectResource, pTransform, pComponentInstance); -} - - -Lib3MFResult CCall_lib3mf_componentsobject_getcomponent(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObject pComponentsObject, Lib3MF_uint32 nIndex, Lib3MF_Component * pComponentInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ComponentsObject_GetComponent (pComponentsObject, nIndex, pComponentInstance); -} - - -Lib3MFResult CCall_lib3mf_componentsobject_getcomponentcount(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObject pComponentsObject, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ComponentsObject_GetComponentCount (pComponentsObject, pCount); -} - - -Lib3MFResult CCall_lib3mf_beamset_setname(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const char * pName) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_SetName (pBeamSet, pName); -} - - -Lib3MFResult CCall_lib3mf_beamset_getname(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_GetName (pBeamSet, nNameBufferSize, pNameNeededChars, pNameBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamset_setidentifier(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const char * pIdentifier) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_SetIdentifier (pBeamSet, pIdentifier); -} - - -Lib3MFResult CCall_lib3mf_beamset_getidentifier(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint32 nIdentifierBufferSize, Lib3MF_uint32* pIdentifierNeededChars, char * pIdentifierBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_GetIdentifier (pBeamSet, nIdentifierBufferSize, pIdentifierNeededChars, pIdentifierBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamset_getreferencecount(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_GetReferenceCount (pBeamSet, pCount); -} - - -Lib3MFResult CCall_lib3mf_beamset_setreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint64 nReferencesBufferSize, const Lib3MF_uint32 * pReferencesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_SetReferences (pBeamSet, nReferencesBufferSize, pReferencesBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamset_getreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint64 nReferencesBufferSize, Lib3MF_uint64* pReferencesNeededCount, Lib3MF_uint32 * pReferencesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_GetReferences (pBeamSet, nReferencesBufferSize, pReferencesNeededCount, pReferencesBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamset_getballreferencecount(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_GetBallReferenceCount (pBeamSet, pCount); -} - - -Lib3MFResult CCall_lib3mf_beamset_setballreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint64 nBallReferencesBufferSize, const Lib3MF_uint32 * pBallReferencesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_SetBallReferences (pBeamSet, nBallReferencesBufferSize, pBallReferencesBuffer); -} - - -Lib3MFResult CCall_lib3mf_beamset_getballreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint64 nBallReferencesBufferSize, Lib3MF_uint64* pBallReferencesNeededCount, Lib3MF_uint32 * pBallReferencesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BeamSet_GetBallReferences (pBeamSet, nBallReferencesBufferSize, pBallReferencesNeededCount, pBallReferencesBuffer); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_GetCount (pBaseMaterialGroup, pCount); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_GetAllPropertyIDs (pBaseMaterialGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_addmaterial(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, const char * pName, const sLib3MFColor * pDisplayColor, Lib3MF_uint32 * pPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_AddMaterial (pBaseMaterialGroup, pName, pDisplayColor, pPropertyID); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_removematerial(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_RemoveMaterial (pBaseMaterialGroup, nPropertyID); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_getname(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_GetName (pBaseMaterialGroup, nPropertyID, nNameBufferSize, pNameNeededChars, pNameBuffer); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_setname(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const char * pName) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_SetName (pBaseMaterialGroup, nPropertyID, pName); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_setdisplaycolor(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const sLib3MFColor * pTheColor) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_SetDisplayColor (pBaseMaterialGroup, nPropertyID, pTheColor); -} - - -Lib3MFResult CCall_lib3mf_basematerialgroup_getdisplaycolor(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, sLib3MFColor * pTheColor) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BaseMaterialGroup_GetDisplayColor (pBaseMaterialGroup, nPropertyID, pTheColor); -} - - -Lib3MFResult CCall_lib3mf_colorgroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorGroup_GetCount (pColorGroup, pCount); -} - - -Lib3MFResult CCall_lib3mf_colorgroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorGroup_GetAllPropertyIDs (pColorGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); -} - - -Lib3MFResult CCall_lib3mf_colorgroup_addcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, const sLib3MFColor * pTheColor, Lib3MF_uint32 * pPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorGroup_AddColor (pColorGroup, pTheColor, pPropertyID); -} - - -Lib3MFResult CCall_lib3mf_colorgroup_removecolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorGroup_RemoveColor (pColorGroup, nPropertyID); -} - - -Lib3MFResult CCall_lib3mf_colorgroup_setcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID, const sLib3MFColor * pTheColor) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorGroup_SetColor (pColorGroup, nPropertyID, pTheColor); -} - - -Lib3MFResult CCall_lib3mf_colorgroup_getcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID, sLib3MFColor * pTheColor) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorGroup_GetColor (pColorGroup, nPropertyID, pTheColor); -} - - -Lib3MFResult CCall_lib3mf_texture2dgroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DGroup_GetCount (pTexture2DGroup, pCount); -} - - -Lib3MFResult CCall_lib3mf_texture2dgroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DGroup_GetAllPropertyIDs (pTexture2DGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); -} - - -Lib3MFResult CCall_lib3mf_texture2dgroup_addtex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, const sLib3MFTex2Coord * pUVCoordinate, Lib3MF_uint32 * pPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DGroup_AddTex2Coord (pTexture2DGroup, pUVCoordinate, pPropertyID); -} - - -Lib3MFResult CCall_lib3mf_texture2dgroup_gettex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32 nPropertyID, sLib3MFTex2Coord * pUVCoordinate) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DGroup_GetTex2Coord (pTexture2DGroup, nPropertyID, pUVCoordinate); -} - - -Lib3MFResult CCall_lib3mf_texture2dgroup_removetex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32 nPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DGroup_RemoveTex2Coord (pTexture2DGroup, nPropertyID); -} - - -Lib3MFResult CCall_lib3mf_texture2dgroup_gettexture2d(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_Texture2D * pTexture2DInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2DGroup_GetTexture2D (pTexture2DGroup, pTexture2DInstance); -} - - -Lib3MFResult CCall_lib3mf_compositematerials_getcount(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CompositeMaterials_GetCount (pCompositeMaterials, pCount); -} - - -Lib3MFResult CCall_lib3mf_compositematerials_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CompositeMaterials_GetAllPropertyIDs (pCompositeMaterials, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); -} - - -Lib3MFResult CCall_lib3mf_compositematerials_getbasematerialgroup(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_BaseMaterialGroup * pBaseMaterialGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CompositeMaterials_GetBaseMaterialGroup (pCompositeMaterials, pBaseMaterialGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_compositematerials_addcomposite(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint64 nCompositeBufferSize, const sLib3MFCompositeConstituent * pCompositeBuffer, Lib3MF_uint32 * pPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CompositeMaterials_AddComposite (pCompositeMaterials, nCompositeBufferSize, pCompositeBuffer, pPropertyID); -} - - -Lib3MFResult CCall_lib3mf_compositematerials_removecomposite(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 nPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CompositeMaterials_RemoveComposite (pCompositeMaterials, nPropertyID); -} - - -Lib3MFResult CCall_lib3mf_compositematerials_getcomposite(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 nPropertyID, const Lib3MF_uint64 nCompositeBufferSize, Lib3MF_uint64* pCompositeNeededCount, sLib3MFCompositeConstituent * pCompositeBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CompositeMaterials_GetComposite (pCompositeMaterials, nPropertyID, nCompositeBufferSize, pCompositeNeededCount, pCompositeBuffer); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_GetCount (pMultiPropertyGroup, pCount); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_GetAllPropertyIDs (pMultiPropertyGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_addmultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint64 nPropertyIDsBufferSize, const Lib3MF_uint32 * pPropertyIDsBuffer, Lib3MF_uint32 * pPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_AddMultiProperty (pMultiPropertyGroup, nPropertyIDsBufferSize, pPropertyIDsBuffer, pPropertyID); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_setmultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID, Lib3MF_uint64 nPropertyIDsBufferSize, const Lib3MF_uint32 * pPropertyIDsBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_SetMultiProperty (pMultiPropertyGroup, nPropertyID, nPropertyIDsBufferSize, pPropertyIDsBuffer); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_getmultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_GetMultiProperty (pMultiPropertyGroup, nPropertyID, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_removemultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_RemoveMultiProperty (pMultiPropertyGroup, nPropertyID); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_getlayercount(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_GetLayerCount (pMultiPropertyGroup, pCount); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_addlayer(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, const sLib3MFMultiPropertyLayer * pTheLayer, Lib3MF_uint32 * pLayerIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_AddLayer (pMultiPropertyGroup, pTheLayer, pLayerIndex); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_getlayer(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nLayerIndex, sLib3MFMultiPropertyLayer * pTheLayer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_GetLayer (pMultiPropertyGroup, nLayerIndex, pTheLayer); -} - - -Lib3MFResult CCall_lib3mf_multipropertygroup_removelayer(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nLayerIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_MultiPropertyGroup_RemoveLayer (pMultiPropertyGroup, nLayerIndex); -} - - -Lib3MFResult CCall_lib3mf_attachment_getpath(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_GetPath (pAttachment, nPathBufferSize, pPathNeededChars, pPathBuffer); -} - - -Lib3MFResult CCall_lib3mf_attachment_setpath(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pPath) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_SetPath (pAttachment, pPath); -} - - -Lib3MFResult CCall_lib3mf_attachment_packagepart(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_PackagePart * pPackagePart) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_PackagePart (pAttachment, pPackagePart); -} - - -Lib3MFResult CCall_lib3mf_attachment_getrelationshiptype(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_GetRelationShipType (pAttachment, nPathBufferSize, pPathNeededChars, pPathBuffer); -} - - -Lib3MFResult CCall_lib3mf_attachment_setrelationshiptype(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pPath) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_SetRelationShipType (pAttachment, pPath); -} - - -Lib3MFResult CCall_lib3mf_attachment_writetofile(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pFileName) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_WriteToFile (pAttachment, pFileName); -} - - -Lib3MFResult CCall_lib3mf_attachment_readfromfile(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pFileName) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_ReadFromFile (pAttachment, pFileName); -} - - -Lib3MFResult CCall_lib3mf_attachment_readfromcallback(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MFReadCallback pTheReadCallback, Lib3MF_uint64 nStreamSize, Lib3MFSeekCallback pTheSeekCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_ReadFromCallback (pAttachment, pTheReadCallback, nStreamSize, pTheSeekCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_attachment_getstreamsize(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_uint64 * pStreamSize) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_GetStreamSize (pAttachment, pStreamSize); -} - - -Lib3MFResult CCall_lib3mf_attachment_writetobuffer(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const Lib3MF_uint64 nBufferBufferSize, Lib3MF_uint64* pBufferNeededCount, Lib3MF_uint8 * pBufferBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_WriteToBuffer (pAttachment, nBufferBufferSize, pBufferNeededCount, pBufferBuffer); -} - - -Lib3MFResult CCall_lib3mf_attachment_readfrombuffer(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_uint64 nBufferBufferSize, const Lib3MF_uint8 * pBufferBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Attachment_ReadFromBuffer (pAttachment, nBufferBufferSize, pBufferBuffer); -} - - -Lib3MFResult CCall_lib3mf_texture2d_getattachment(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, Lib3MF_Attachment * pAttachment) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_GetAttachment (pTexture2D, pAttachment); -} - - -Lib3MFResult CCall_lib3mf_texture2d_setattachment(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, Lib3MF_Attachment pAttachment) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_SetAttachment (pTexture2D, pAttachment); -} - - -Lib3MFResult CCall_lib3mf_texture2d_getcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureType * pContentType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_GetContentType (pTexture2D, pContentType); -} - - -Lib3MFResult CCall_lib3mf_texture2d_setcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureType eContentType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_SetContentType (pTexture2D, eContentType); -} - - -Lib3MFResult CCall_lib3mf_texture2d_gettilestyleuv(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureTileStyle * pTileStyleU, eLib3MFTextureTileStyle * pTileStyleV) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_GetTileStyleUV (pTexture2D, pTileStyleU, pTileStyleV); -} - - -Lib3MFResult CCall_lib3mf_texture2d_settilestyleuv(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureTileStyle eTileStyleU, eLib3MFTextureTileStyle eTileStyleV) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_SetTileStyleUV (pTexture2D, eTileStyleU, eTileStyleV); -} - - -Lib3MFResult CCall_lib3mf_texture2d_getfilter(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureFilter * pFilter) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_GetFilter (pTexture2D, pFilter); -} - - -Lib3MFResult CCall_lib3mf_texture2d_setfilter(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureFilter eFilter) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Texture2D_SetFilter (pTexture2D, eFilter); -} - - -Lib3MFResult CCall_lib3mf_builditem_getobjectresource(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_Object * pObjectResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_GetObjectResource (pBuildItem, pObjectResource); -} - - -Lib3MFResult CCall_lib3mf_builditem_getuuid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_GetUUID (pBuildItem, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_builditem_setuuid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const char * pUUID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_SetUUID (pBuildItem, pUUID); -} - - -Lib3MFResult CCall_lib3mf_builditem_getobjectresourceid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_uint32 * pUniqueResourceID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_GetObjectResourceID (pBuildItem, pUniqueResourceID); -} - - -Lib3MFResult CCall_lib3mf_builditem_hasobjecttransform(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, bool * pHasTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_HasObjectTransform (pBuildItem, pHasTransform); -} - - -Lib3MFResult CCall_lib3mf_builditem_getobjecttransform(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_GetObjectTransform (pBuildItem, pTransform); -} - - -Lib3MFResult CCall_lib3mf_builditem_setobjecttransform(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_SetObjectTransform (pBuildItem, pTransform); -} - - -Lib3MFResult CCall_lib3mf_builditem_getpartnumber(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const Lib3MF_uint32 nPartNumberBufferSize, Lib3MF_uint32* pPartNumberNeededChars, char * pPartNumberBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_GetPartNumber (pBuildItem, nPartNumberBufferSize, pPartNumberNeededChars, pPartNumberBuffer); -} - - -Lib3MFResult CCall_lib3mf_builditem_setpartnumber(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const char * pSetPartnumber) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_SetPartNumber (pBuildItem, pSetPartnumber); -} - - -Lib3MFResult CCall_lib3mf_builditem_getmetadatagroup(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_MetaDataGroup * pMetaDataGroup) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_GetMetaDataGroup (pBuildItem, pMetaDataGroup); -} - - -Lib3MFResult CCall_lib3mf_builditem_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, sLib3MFBox * pOutbox) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItem_GetOutbox (pBuildItem, pOutbox); -} - - -Lib3MFResult CCall_lib3mf_builditemiterator_movenext(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, bool * pHasNext) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItemIterator_MoveNext (pBuildItemIterator, pHasNext); -} - - -Lib3MFResult CCall_lib3mf_builditemiterator_moveprevious(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, bool * pHasPrevious) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItemIterator_MovePrevious (pBuildItemIterator, pHasPrevious); -} - - -Lib3MFResult CCall_lib3mf_builditemiterator_getcurrent(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_BuildItem * pBuildItem) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItemIterator_GetCurrent (pBuildItemIterator, pBuildItem); -} - - -Lib3MFResult CCall_lib3mf_builditemiterator_clone(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_BuildItemIterator * pOutBuildItemIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItemIterator_Clone (pBuildItemIterator, pOutBuildItemIterator); -} - - -Lib3MFResult CCall_lib3mf_builditemiterator_count(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_BuildItemIterator_Count (pBuildItemIterator, pCount); -} - - -Lib3MFResult CCall_lib3mf_slice_setvertices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nVerticesBufferSize, const sLib3MFPosition2D * pVerticesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_SetVertices (pSlice, nVerticesBufferSize, pVerticesBuffer); -} - - -Lib3MFResult CCall_lib3mf_slice_getvertices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, const Lib3MF_uint64 nVerticesBufferSize, Lib3MF_uint64* pVerticesNeededCount, sLib3MFPosition2D * pVerticesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_GetVertices (pSlice, nVerticesBufferSize, pVerticesNeededCount, pVerticesBuffer); -} - - -Lib3MFResult CCall_lib3mf_slice_getvertexcount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_GetVertexCount (pSlice, pCount); -} - - -Lib3MFResult CCall_lib3mf_slice_addpolygon(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndicesBufferSize, const Lib3MF_uint32 * pIndicesBuffer, Lib3MF_uint64 * pIndex) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_AddPolygon (pSlice, nIndicesBufferSize, pIndicesBuffer, pIndex); -} - - -Lib3MFResult CCall_lib3mf_slice_getpolygoncount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_GetPolygonCount (pSlice, pCount); -} - - -Lib3MFResult CCall_lib3mf_slice_setpolygonindices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, Lib3MF_uint64 nIndicesBufferSize, const Lib3MF_uint32 * pIndicesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_SetPolygonIndices (pSlice, nIndex, nIndicesBufferSize, pIndicesBuffer); -} - - -Lib3MFResult CCall_lib3mf_slice_getpolygonindices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, const Lib3MF_uint64 nIndicesBufferSize, Lib3MF_uint64* pIndicesNeededCount, Lib3MF_uint32 * pIndicesBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_GetPolygonIndices (pSlice, nIndex, nIndicesBufferSize, pIndicesNeededCount, pIndicesBuffer); -} - - -Lib3MFResult CCall_lib3mf_slice_getpolygonindexcount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_GetPolygonIndexCount (pSlice, nIndex, pCount); -} - - -Lib3MFResult CCall_lib3mf_slice_getztop(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_double * pZTop) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Slice_GetZTop (pSlice, pZTop); -} - - -Lib3MFResult CCall_lib3mf_slicestack_getbottomz(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_double * pZBottom) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_GetBottomZ (pSliceStack, pZBottom); -} - - -Lib3MFResult CCall_lib3mf_slicestack_getslicecount(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_GetSliceCount (pSliceStack, pCount); -} - - -Lib3MFResult CCall_lib3mf_slicestack_getslice(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 nSliceIndex, Lib3MF_Slice * pTheSlice) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_GetSlice (pSliceStack, nSliceIndex, pTheSlice); -} - - -Lib3MFResult CCall_lib3mf_slicestack_addslice(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_double dZTop, Lib3MF_Slice * pTheSlice) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_AddSlice (pSliceStack, dZTop, pTheSlice); -} - - -Lib3MFResult CCall_lib3mf_slicestack_getslicerefcount(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_GetSliceRefCount (pSliceStack, pCount); -} - - -Lib3MFResult CCall_lib3mf_slicestack_addslicestackreference(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_SliceStack pTheSliceStack) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_AddSliceStackReference (pSliceStack, pTheSliceStack); -} - - -Lib3MFResult CCall_lib3mf_slicestack_getslicestackreference(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 nSliceRefIndex, Lib3MF_SliceStack * pTheSliceStack) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_GetSliceStackReference (pSliceStack, nSliceRefIndex, pTheSliceStack); -} - - -Lib3MFResult CCall_lib3mf_slicestack_collapseslicereferences(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_CollapseSliceReferences (pSliceStack); -} - - -Lib3MFResult CCall_lib3mf_slicestack_setownpath(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, const char * pPath) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_SetOwnPath (pSliceStack, pPath); -} - - -Lib3MFResult CCall_lib3mf_slicestack_getownpath(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SliceStack_GetOwnPath (pSliceStack, nPathBufferSize, pPathNeededChars, pPathBuffer); -} - - -Lib3MFResult CCall_lib3mf_consumer_getconsumerid(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, const Lib3MF_uint32 nConsumerIDBufferSize, Lib3MF_uint32* pConsumerIDNeededChars, char * pConsumerIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Consumer_GetConsumerID (pConsumer, nConsumerIDBufferSize, pConsumerIDNeededChars, pConsumerIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_consumer_getkeyid(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, const Lib3MF_uint32 nKeyIDBufferSize, Lib3MF_uint32* pKeyIDNeededChars, char * pKeyIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Consumer_GetKeyID (pConsumer, nKeyIDBufferSize, pKeyIDNeededChars, pKeyIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_consumer_getkeyvalue(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, const Lib3MF_uint32 nKeyValueBufferSize, Lib3MF_uint32* pKeyValueNeededChars, char * pKeyValueBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Consumer_GetKeyValue (pConsumer, nKeyValueBufferSize, pKeyValueNeededChars, pKeyValueBuffer); -} - - -Lib3MFResult CCall_lib3mf_accessright_getconsumer(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, Lib3MF_Consumer * pConsumer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_AccessRight_GetConsumer (pAccessRight, pConsumer); -} - - -Lib3MFResult CCall_lib3mf_accessright_getwrappingalgorithm(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFWrappingAlgorithm * pAlgorithm) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_AccessRight_GetWrappingAlgorithm (pAccessRight, pAlgorithm); -} - - -Lib3MFResult CCall_lib3mf_accessright_getmgfalgorithm(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFMgfAlgorithm * pAlgorithm) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_AccessRight_GetMgfAlgorithm (pAccessRight, pAlgorithm); -} - - -Lib3MFResult CCall_lib3mf_accessright_getdigestmethod(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFDigestMethod * pAlgorithm) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_AccessRight_GetDigestMethod (pAccessRight, pAlgorithm); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_getencryptionalgorithm(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, eLib3MFEncryptionAlgorithm * pAlgorithm) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_GetEncryptionAlgorithm (pContentEncryptionParams, pAlgorithm); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_getkey(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_GetKey (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_getinitializationvector(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_GetInitializationVector (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_getauthenticationtag(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_GetAuthenticationTag (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_setauthenticationtag(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, Lib3MF_uint64 nByteDataBufferSize, const Lib3MF_uint8 * pByteDataBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_SetAuthenticationTag (pContentEncryptionParams, nByteDataBufferSize, pByteDataBuffer); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_getadditionalauthenticationdata(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_GetAdditionalAuthenticationData (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_getdescriptor(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, Lib3MF_uint64 * pDescriptor) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_GetDescriptor (pContentEncryptionParams, pDescriptor); -} - - -Lib3MFResult CCall_lib3mf_contentencryptionparams_getkeyuuid(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ContentEncryptionParams_GetKeyUUID (pContentEncryptionParams, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_resourcedata_getpath(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, Lib3MF_PackagePart * pPath) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceData_GetPath (pResourceData, pPath); -} - - -Lib3MFResult CCall_lib3mf_resourcedata_getencryptionalgorithm(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, eLib3MFEncryptionAlgorithm * pEncryptionAlgorithm) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceData_GetEncryptionAlgorithm (pResourceData, pEncryptionAlgorithm); -} - - -Lib3MFResult CCall_lib3mf_resourcedata_getcompression(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, eLib3MFCompression * pCompression) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceData_GetCompression (pResourceData, pCompression); -} - - -Lib3MFResult CCall_lib3mf_resourcedata_getadditionalauthenticationdata(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceData_GetAdditionalAuthenticationData (pResourceData, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); -} - - -Lib3MFResult CCall_lib3mf_resourcedatagroup_getkeyuuid(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceDataGroup_GetKeyUUID (pResourceDataGroup, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_resourcedatagroup_addaccessright(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer, eLib3MFWrappingAlgorithm eWrappingAlgorithm, eLib3MFMgfAlgorithm eMgfAlgorithm, eLib3MFDigestMethod eDigestMethod, Lib3MF_AccessRight * pTheAccessRight) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceDataGroup_AddAccessRight (pResourceDataGroup, pConsumer, eWrappingAlgorithm, eMgfAlgorithm, eDigestMethod, pTheAccessRight); -} - - -Lib3MFResult CCall_lib3mf_resourcedatagroup_findaccessrightbyconsumer(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer, Lib3MF_AccessRight * pTheAccessRight) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceDataGroup_FindAccessRightByConsumer (pResourceDataGroup, pConsumer, pTheAccessRight); -} - - -Lib3MFResult CCall_lib3mf_resourcedatagroup_removeaccessright(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ResourceDataGroup_RemoveAccessRight (pResourceDataGroup, pConsumer); -} - - -Lib3MFResult CCall_lib3mf_keystore_addconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char * pConsumerID, const char * pKeyID, const char * pKeyValue, Lib3MF_Consumer * pConsumer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_AddConsumer (pKeyStore, pConsumerID, pKeyID, pKeyValue, pConsumer); -} - - -Lib3MFResult CCall_lib3mf_keystore_getconsumercount(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_GetConsumerCount (pKeyStore, pCount); -} - - -Lib3MFResult CCall_lib3mf_keystore_getconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 nConsumerIndex, Lib3MF_Consumer * pConsumer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_GetConsumer (pKeyStore, nConsumerIndex, pConsumer); -} - - -Lib3MFResult CCall_lib3mf_keystore_removeconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_Consumer pConsumer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_RemoveConsumer (pKeyStore, pConsumer); -} - - -Lib3MFResult CCall_lib3mf_keystore_findconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char * pConsumerID, Lib3MF_Consumer * pConsumer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_FindConsumer (pKeyStore, pConsumerID, pConsumer); -} - - -Lib3MFResult CCall_lib3mf_keystore_getresourcedatagroupcount(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_GetResourceDataGroupCount (pKeyStore, pCount); -} - - -Lib3MFResult CCall_lib3mf_keystore_addresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup * pResourceDataGroup) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_AddResourceDataGroup (pKeyStore, pResourceDataGroup); -} - - -Lib3MFResult CCall_lib3mf_keystore_getresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 nResourceDataIndex, Lib3MF_ResourceDataGroup * pResourceDataGroup) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_GetResourceDataGroup (pKeyStore, nResourceDataIndex, pResourceDataGroup); -} - - -Lib3MFResult CCall_lib3mf_keystore_removeresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup pResourceDataGroup) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_RemoveResourceDataGroup (pKeyStore, pResourceDataGroup); -} - - -Lib3MFResult CCall_lib3mf_keystore_findresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_PackagePart pPartPath, Lib3MF_ResourceDataGroup * pResourceDataGroup) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_FindResourceDataGroup (pKeyStore, pPartPath, pResourceDataGroup); -} - - -Lib3MFResult CCall_lib3mf_keystore_addresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_PackagePart pPartPath, eLib3MFEncryptionAlgorithm eAlgorithm, eLib3MFCompression eCompression, Lib3MF_uint64 nAdditionalAuthenticationDataBufferSize, const Lib3MF_uint8 * pAdditionalAuthenticationDataBuffer, Lib3MF_ResourceData * pResourceData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_AddResourceData (pKeyStore, pResourceDataGroup, pPartPath, eAlgorithm, eCompression, nAdditionalAuthenticationDataBufferSize, pAdditionalAuthenticationDataBuffer, pResourceData); -} - - -Lib3MFResult CCall_lib3mf_keystore_removeresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceData pResourceData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_RemoveResourceData (pKeyStore, pResourceData); -} - - -Lib3MFResult CCall_lib3mf_keystore_findresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_PackagePart pResourcePath, Lib3MF_ResourceData * pResourceData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_FindResourceData (pKeyStore, pResourcePath, pResourceData); -} - - -Lib3MFResult CCall_lib3mf_keystore_getresourcedatacount(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 * pCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_GetResourceDataCount (pKeyStore, pCount); -} - - -Lib3MFResult CCall_lib3mf_keystore_getresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 nResourceDataIndex, Lib3MF_ResourceData * pResourceData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_GetResourceData (pKeyStore, nResourceDataIndex, pResourceData); -} - - -Lib3MFResult CCall_lib3mf_keystore_getuuid(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_GetUUID (pKeyStore, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_keystore_setuuid(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char * pUUID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_KeyStore_SetUUID (pKeyStore, pUUID); -} - - -Lib3MFResult CCall_lib3mf_model_rootmodelpart(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_PackagePart * pRootModelPart) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_RootModelPart (pModel, pRootModelPart); -} - - -Lib3MFResult CCall_lib3mf_model_findorcreatepackagepart(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pAbsolutePath, Lib3MF_PackagePart * pModelPart) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_FindOrCreatePackagePart (pModel, pAbsolutePath, pModelPart); -} - - -Lib3MFResult CCall_lib3mf_model_setunit(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, eLib3MFModelUnit eUnit) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_SetUnit (pModel, eUnit); -} - - -Lib3MFResult CCall_lib3mf_model_getunit(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, eLib3MFModelUnit * pUnit) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetUnit (pModel, pUnit); -} - - -Lib3MFResult CCall_lib3mf_model_getlanguage(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const Lib3MF_uint32 nLanguageBufferSize, Lib3MF_uint32* pLanguageNeededChars, char * pLanguageBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetLanguage (pModel, nLanguageBufferSize, pLanguageNeededChars, pLanguageBuffer); -} - - -Lib3MFResult CCall_lib3mf_model_setlanguage(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pLanguage) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_SetLanguage (pModel, pLanguage); -} - - -Lib3MFResult CCall_lib3mf_model_querywriter(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pWriterClass, Lib3MF_Writer * pWriterInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_QueryWriter (pModel, pWriterClass, pWriterInstance); -} - - -Lib3MFResult CCall_lib3mf_model_queryreader(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pReaderClass, Lib3MF_Reader * pReaderInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_QueryReader (pModel, pReaderClass, pReaderInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getresourcebyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_Resource * pResource) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetResourceByID (pModel, nUniqueResourceID, pResource); -} - - -Lib3MFResult CCall_lib3mf_model_gettexture2dbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_Texture2D * pTextureInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetTexture2DByID (pModel, nUniqueResourceID, pTextureInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getpropertytypebyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, eLib3MFPropertyType * pThePropertyType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetPropertyTypeByID (pModel, nUniqueResourceID, pThePropertyType); -} - - -Lib3MFResult CCall_lib3mf_model_getbasematerialgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_BaseMaterialGroup * pBaseMaterialGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetBaseMaterialGroupByID (pModel, nUniqueResourceID, pBaseMaterialGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_gettexture2dgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_Texture2DGroup * pTexture2DGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetTexture2DGroupByID (pModel, nUniqueResourceID, pTexture2DGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getcompositematerialsbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_CompositeMaterials * pCompositeMaterialsInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetCompositeMaterialsByID (pModel, nUniqueResourceID, pCompositeMaterialsInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getmultipropertygroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_MultiPropertyGroup * pMultiPropertyGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetMultiPropertyGroupByID (pModel, nUniqueResourceID, pMultiPropertyGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getmeshobjectbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_MeshObject * pMeshObjectInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetMeshObjectByID (pModel, nUniqueResourceID, pMeshObjectInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getcomponentsobjectbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_ComponentsObject * pComponentsObjectInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetComponentsObjectByID (pModel, nUniqueResourceID, pComponentsObjectInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getcolorgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_ColorGroup * pColorGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetColorGroupByID (pModel, nUniqueResourceID, pColorGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getslicestackbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_SliceStack * pSliceStacInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetSliceStackByID (pModel, nUniqueResourceID, pSliceStacInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getbuilduuid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetBuildUUID (pModel, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); -} - - -Lib3MFResult CCall_lib3mf_model_setbuilduuid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pUUID) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_SetBuildUUID (pModel, pUUID); -} - - -Lib3MFResult CCall_lib3mf_model_getbuilditems(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BuildItemIterator * pBuildItemIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetBuildItems (pModel, pBuildItemIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, sLib3MFBox * pOutbox) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetOutbox (pModel, pOutbox); -} - - -Lib3MFResult CCall_lib3mf_model_getresources(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ResourceIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetResources (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getobjects(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ObjectIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetObjects (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getmeshobjects(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MeshObjectIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetMeshObjects (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getcomponentsobjects(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ComponentsObjectIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetComponentsObjects (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_gettexture2ds(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2DIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetTexture2Ds (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getbasematerialgroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroupIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetBaseMaterialGroups (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getcolorgroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ColorGroupIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetColorGroups (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_gettexture2dgroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2DGroupIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetTexture2DGroups (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getcompositematerials(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_CompositeMaterialsIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetCompositeMaterials (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getmultipropertygroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MultiPropertyGroupIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetMultiPropertyGroups (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_getslicestacks(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_SliceStackIterator * pResourceIterator) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetSliceStacks (pModel, pResourceIterator); -} - - -Lib3MFResult CCall_lib3mf_model_mergetomodel(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Model * pMergedModelInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_MergeToModel (pModel, pMergedModelInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addmeshobject(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MeshObject * pMeshObjectInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddMeshObject (pModel, pMeshObjectInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addcomponentsobject(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ComponentsObject * pComponentsObjectInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddComponentsObject (pModel, pComponentsObjectInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addslicestack(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_double dZBottom, Lib3MF_SliceStack * pSliceStackInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddSliceStack (pModel, dZBottom, pSliceStackInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addtexture2dfromattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment pTextureAttachment, Lib3MF_Texture2D * pTexture2DInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddTexture2DFromAttachment (pModel, pTextureAttachment, pTexture2DInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addbasematerialgroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroup * pBaseMaterialGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddBaseMaterialGroup (pModel, pBaseMaterialGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addcolorgroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ColorGroup * pColorGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddColorGroup (pModel, pColorGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addtexture2dgroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2D pTexture2DInstance, Lib3MF_Texture2DGroup * pTexture2DGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddTexture2DGroup (pModel, pTexture2DInstance, pTexture2DGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addcompositematerials(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroup pBaseMaterialGroupInstance, Lib3MF_CompositeMaterials * pCompositeMaterialsInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddCompositeMaterials (pModel, pBaseMaterialGroupInstance, pCompositeMaterialsInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addmultipropertygroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MultiPropertyGroup * pMultiPropertyGroupInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddMultiPropertyGroup (pModel, pMultiPropertyGroupInstance); -} - - -Lib3MFResult CCall_lib3mf_model_addbuilditem(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Object pObject, const sLib3MFTransform * pTransform, Lib3MF_BuildItem * pBuildItemInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddBuildItem (pModel, pObject, pTransform, pBuildItemInstance); -} - - -Lib3MFResult CCall_lib3mf_model_removebuilditem(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BuildItem pBuildItemInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_RemoveBuildItem (pModel, pBuildItemInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getmetadatagroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MetaDataGroup * pTheMetaDataGroup) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetMetaDataGroup (pModel, pTheMetaDataGroup); -} - - -Lib3MFResult CCall_lib3mf_model_addattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pURI, const char * pRelationShipType, Lib3MF_Attachment * pAttachmentInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddAttachment (pModel, pURI, pRelationShipType, pAttachmentInstance); -} - - -Lib3MFResult CCall_lib3mf_model_removeattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment pAttachmentInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_RemoveAttachment (pModel, pAttachmentInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nIndex, Lib3MF_Attachment * pAttachmentInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetAttachment (pModel, nIndex, pAttachmentInstance); -} - - -Lib3MFResult CCall_lib3mf_model_findattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pURI, Lib3MF_Attachment * pAttachmentInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_FindAttachment (pModel, pURI, pAttachmentInstance); -} - - -Lib3MFResult CCall_lib3mf_model_getattachmentcount(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 * pAttachmentCount) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetAttachmentCount (pModel, pAttachmentCount); -} - - -Lib3MFResult CCall_lib3mf_model_haspackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, bool * pHasThumbnail) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_HasPackageThumbnailAttachment (pModel, pHasThumbnail); -} - - -Lib3MFResult CCall_lib3mf_model_createpackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment * pAttachment) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_CreatePackageThumbnailAttachment (pModel, pAttachment); -} - - -Lib3MFResult CCall_lib3mf_model_getpackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment * pAttachment) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetPackageThumbnailAttachment (pModel, pAttachment); -} - - -Lib3MFResult CCall_lib3mf_model_removepackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_RemovePackageThumbnailAttachment (pModel); -} - - -Lib3MFResult CCall_lib3mf_model_addcustomcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pExtension, const char * pContentType) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_AddCustomContentType (pModel, pExtension, pContentType); -} - - -Lib3MFResult CCall_lib3mf_model_removecustomcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pExtension) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_RemoveCustomContentType (pModel, pExtension); -} - - -Lib3MFResult CCall_lib3mf_model_setrandomnumbercallback(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MFRandomNumberCallback pTheCallback, Lib3MF_pvoid pUserData) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_SetRandomNumberCallback (pModel, pTheCallback, pUserData); -} - - -Lib3MFResult CCall_lib3mf_model_getkeystore(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_KeyStore * pKeyStore) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Model_GetKeyStore (pModel, pKeyStore); -} - - -Lib3MFResult CCall_lib3mf_getlibraryversion(Lib3MFHandle libraryHandle, Lib3MF_uint32 * pMajor, Lib3MF_uint32 * pMinor, Lib3MF_uint32 * pMicro) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetLibraryVersion (pMajor, pMinor, pMicro); -} - - -Lib3MFResult CCall_lib3mf_getprereleaseinformation(Lib3MFHandle libraryHandle, bool * pHasPrereleaseInfo, const Lib3MF_uint32 nPrereleaseInfoBufferSize, Lib3MF_uint32* pPrereleaseInfoNeededChars, char * pPrereleaseInfoBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetPrereleaseInformation (pHasPrereleaseInfo, nPrereleaseInfoBufferSize, pPrereleaseInfoNeededChars, pPrereleaseInfoBuffer); -} - - -Lib3MFResult CCall_lib3mf_getbuildinformation(Lib3MFHandle libraryHandle, bool * pHasBuildInfo, const Lib3MF_uint32 nBuildInformationBufferSize, Lib3MF_uint32* pBuildInformationNeededChars, char * pBuildInformationBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetBuildInformation (pHasBuildInfo, nBuildInformationBufferSize, pBuildInformationNeededChars, pBuildInformationBuffer); -} - - -Lib3MFResult CCall_lib3mf_getspecificationversion(Lib3MFHandle libraryHandle, const char * pSpecificationURL, bool * pIsSupported, Lib3MF_uint32 * pMajor, Lib3MF_uint32 * pMinor, Lib3MF_uint32 * pMicro) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetSpecificationVersion (pSpecificationURL, pIsSupported, pMajor, pMinor, pMicro); -} - - -Lib3MFResult CCall_lib3mf_createmodel(Lib3MFHandle libraryHandle, Lib3MF_Model * pModel) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_CreateModel (pModel); -} - - -Lib3MFResult CCall_lib3mf_release(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Release (pInstance); -} - - -Lib3MFResult CCall_lib3mf_acquire(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_Acquire (pInstance); -} - - -Lib3MFResult CCall_lib3mf_setjournal(Lib3MFHandle libraryHandle, const char * pJournalPath) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_SetJournal (pJournalPath); -} - - -Lib3MFResult CCall_lib3mf_getlasterror(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance, const Lib3MF_uint32 nLastErrorStringBufferSize, Lib3MF_uint32* pLastErrorStringNeededChars, char * pLastErrorStringBuffer, bool * pHasLastError) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetLastError (pInstance, nLastErrorStringBufferSize, pLastErrorStringNeededChars, pLastErrorStringBuffer, pHasLastError); -} - - -Lib3MFResult CCall_lib3mf_getsymbollookupmethod(Lib3MFHandle libraryHandle, Lib3MF_pvoid * pSymbolLookupMethod) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetSymbolLookupMethod (pSymbolLookupMethod); -} - - -Lib3MFResult CCall_lib3mf_retrieveprogressmessage(Lib3MFHandle libraryHandle, eLib3MFProgressIdentifier eTheProgressIdentifier, const Lib3MF_uint32 nProgressMessageBufferSize, Lib3MF_uint32* pProgressMessageNeededChars, char * pProgressMessageBuffer) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_RetrieveProgressMessage (eTheProgressIdentifier, nProgressMessageBufferSize, pProgressMessageNeededChars, pProgressMessageBuffer); -} - - -Lib3MFResult CCall_lib3mf_rgbatocolor(Lib3MFHandle libraryHandle, Lib3MF_uint8 nRed, Lib3MF_uint8 nGreen, Lib3MF_uint8 nBlue, Lib3MF_uint8 nAlpha, sLib3MFColor * pTheColor) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_RGBAToColor (nRed, nGreen, nBlue, nAlpha, pTheColor); -} - - -Lib3MFResult CCall_lib3mf_floatrgbatocolor(Lib3MFHandle libraryHandle, Lib3MF_single fRed, Lib3MF_single fGreen, Lib3MF_single fBlue, Lib3MF_single fAlpha, sLib3MFColor * pTheColor) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_FloatRGBAToColor (fRed, fGreen, fBlue, fAlpha, pTheColor); -} - - -Lib3MFResult CCall_lib3mf_colortorgba(Lib3MFHandle libraryHandle, const sLib3MFColor * pTheColor, Lib3MF_uint8 * pRed, Lib3MF_uint8 * pGreen, Lib3MF_uint8 * pBlue, Lib3MF_uint8 * pAlpha) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorToRGBA (pTheColor, pRed, pGreen, pBlue, pAlpha); -} - - -Lib3MFResult CCall_lib3mf_colortofloatrgba(Lib3MFHandle libraryHandle, const sLib3MFColor * pTheColor, Lib3MF_single * pRed, Lib3MF_single * pGreen, Lib3MF_single * pBlue, Lib3MF_single * pAlpha) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_ColorToFloatRGBA (pTheColor, pRed, pGreen, pBlue, pAlpha); -} - - -Lib3MFResult CCall_lib3mf_getidentitytransform(Lib3MFHandle libraryHandle, sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetIdentityTransform (pTransform); -} - - -Lib3MFResult CCall_lib3mf_getuniformscaletransform(Lib3MFHandle libraryHandle, Lib3MF_single fFactor, sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetUniformScaleTransform (fFactor, pTransform); -} - - -Lib3MFResult CCall_lib3mf_getscaletransform(Lib3MFHandle libraryHandle, Lib3MF_single fFactorX, Lib3MF_single fFactorY, Lib3MF_single fFactorZ, sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetScaleTransform (fFactorX, fFactorY, fFactorZ, pTransform); -} - - -Lib3MFResult CCall_lib3mf_gettranslationtransform(Lib3MFHandle libraryHandle, Lib3MF_single fVectorX, Lib3MF_single fVectorY, Lib3MF_single fVectorZ, sLib3MFTransform * pTransform) -{ - if (libraryHandle == 0) - return LIB3MF_ERROR_INVALIDCAST; - sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; - return wrapperTable->m_GetTranslationTransform (fVectorX, fVectorY, fVectorZ, pTransform); -} +#include "lib3mf_dynamic.h" */ import "C" @@ -3789,7 +528,7 @@ func keyWrappingCallback(kEKParams C.Lib3MF_AccessRight, inBuffer *C.uint8_t, ou if keyWrappingCallbackFunc == nil { return } - keyWrappingCallbackFunc(, ([][]uint8)(unsafe.Pointer(&inBuffer[0])), ([][]uint8)(unsafe.Pointer(&outBuffer[0])), uintptr(userData), (*uint64)(status)) + //keyWrappingCallbackFunc((AccessRight)(kEKParams), ([]uint8)(unsafe.Pointer(inBuffer)), ([]uint8)(unsafe.Pointer(outBuffer)), uintptr(userData), (*uint64)(status)) } // ContentEncryptionCallbackFunc a callback to encrypt/decrypt content called on each resource encrypted. This might be called several times depending on content size. If Input is not available(either null or size is 0), clients must return the result of authenticated tag generation/validation. @@ -3802,7 +541,7 @@ func contentEncryptionCallback(cEKParams C.Lib3MF_ContentEncryptionParams, input if contentEncryptionCallbackFunc == nil { return } - contentEncryptionCallbackFunc(, ([][]uint8)(unsafe.Pointer(&input[0])), ([][]uint8)(unsafe.Pointer(&output[0])), uintptr(userData), (*uint64)(status)) + //contentEncryptionCallbackFunc((ContentEncryptionParams)(cEKParams), ([]uint8)(unsafe.Pointer(input)), ([]uint8)(unsafe.Pointer(output)), uintptr(userData), (*uint64)(status)) } // Wrapper represents the number wrapper @@ -3898,7 +637,7 @@ func (inst Writer) WriteToBuffer(buffer []uint8) ([]uint8, error) { // WriteToCallback writes out the model and passes the data to a provided callback function. The file type is specified by the Model Writer class. func (inst Writer) WriteToCallback(theWriteCallback WriteCallbackFunc, theSeekCallback SeekCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_writer_writetocallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFWriteCallback)(unsafe.Pointer(C.Lib3MFWriteCallback_cgo)), (C.Lib3MFSeekCallback)(unsafe.Pointer(C.Lib3MFSeekCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_writer_writetocallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFWriteCallback)(unsafe.Pointer(&theWriteCallback)), (C.Lib3MFSeekCallback)(unsafe.Pointer(&theSeekCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -3909,7 +648,7 @@ func (inst Writer) WriteToCallback(theWriteCallback WriteCallbackFunc, theSeekCa // SetProgressCallback set the progress callback for calls to this writer. func (inst Writer) SetProgressCallback(progressCallback ProgressCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_writer_setprogresscallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFProgressCallback)(unsafe.Pointer(C.Lib3MFProgressCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_writer_setprogresscallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFProgressCallback)(unsafe.Pointer(&progressCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -3985,7 +724,7 @@ func (inst Writer) GetWarningCount() (uint32, error) { // AddKeyWrappingCallback registers a callback to deal with data key encryption/decryption from keystore. func (inst Writer) AddKeyWrappingCallback(consumerID string, theCallback KeyWrappingCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_writer_addkeywrappingcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (*C.char)(unsafe.Pointer(&[]byte(consumerID)[0])), (C.Lib3MFKeyWrappingCallback)(unsafe.Pointer(C.Lib3MFKeyWrappingCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_writer_addkeywrappingcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (*C.char)(unsafe.Pointer(&[]byte(consumerID)[0])), (C.Lib3MFKeyWrappingCallback)(unsafe.Pointer(&theCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -3995,7 +734,7 @@ func (inst Writer) AddKeyWrappingCallback(consumerID string, theCallback KeyWrap // SetContentEncryptionCallback registers a callback to deal with encryption of content. func (inst Writer) SetContentEncryptionCallback(theCallback ContentEncryptionCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_writer_setcontentencryptioncallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFContentEncryptionCallback)(unsafe.Pointer(C.Lib3MFContentEncryptionCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_writer_setcontentencryptioncallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFContentEncryptionCallback)(unsafe.Pointer(&theCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -4033,7 +772,7 @@ func (inst Reader) ReadFromBuffer(buffer []uint8) error { // ReadFromCallback reads a model and from the data provided by a callback function. func (inst Reader) ReadFromCallback(theReadCallback ReadCallbackFunc, streamSize uint64, theSeekCallback SeekCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_reader_readfromcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFReadCallback)(unsafe.Pointer(C.Lib3MFReadCallback_cgo)), C.uint64_t(streamSize), (C.Lib3MFSeekCallback)(unsafe.Pointer(C.Lib3MFSeekCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_reader_readfromcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFReadCallback)(unsafe.Pointer(&theReadCallback)), C.uint64_t(streamSize), (C.Lib3MFSeekCallback)(unsafe.Pointer(&theSeekCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -4044,7 +783,7 @@ func (inst Reader) ReadFromCallback(theReadCallback ReadCallbackFunc, streamSize // SetProgressCallback set the progress callback for calls to this writer. func (inst Reader) SetProgressCallback(progressCallback ProgressCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_reader_setprogresscallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFProgressCallback)(unsafe.Pointer(C.Lib3MFProgressCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_reader_setprogresscallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFProgressCallback)(unsafe.Pointer(&progressCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -4119,7 +858,7 @@ func (inst Reader) GetWarningCount() (uint32, error) { // AddKeyWrappingCallback registers a callback to deal with key wrapping mechanism from keystore. func (inst Reader) AddKeyWrappingCallback(consumerID string, theCallback KeyWrappingCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_reader_addkeywrappingcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (*C.char)(unsafe.Pointer(&[]byte(consumerID)[0])), (C.Lib3MFKeyWrappingCallback)(unsafe.Pointer(C.Lib3MFKeyWrappingCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_reader_addkeywrappingcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (*C.char)(unsafe.Pointer(&[]byte(consumerID)[0])), (C.Lib3MFKeyWrappingCallback)(unsafe.Pointer(&theCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -4129,7 +868,7 @@ func (inst Reader) AddKeyWrappingCallback(consumerID string, theCallback KeyWrap // SetContentEncryptionCallback registers a callback to deal with encryption of content. func (inst Reader) SetContentEncryptionCallback(theCallback ContentEncryptionCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_reader_setcontentencryptioncallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFContentEncryptionCallback)(unsafe.Pointer(C.Lib3MFContentEncryptionCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_reader_setcontentencryptioncallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFContentEncryptionCallback)(unsafe.Pointer(&theCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -6241,7 +2980,7 @@ func (inst Attachment) ReadFromFile(fileName string) error { // ReadFromCallback reads a model and from the data provided by a callback function. func (inst Attachment) ReadFromCallback(theReadCallback ReadCallbackFunc, streamSize uint64, theSeekCallback SeekCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_attachment_readfromcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFReadCallback)(unsafe.Pointer(C.Lib3MFReadCallback_cgo)), C.uint64_t(streamSize), (C.Lib3MFSeekCallback)(unsafe.Pointer(C.Lib3MFSeekCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_attachment_readfromcallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFReadCallback)(unsafe.Pointer(&theReadCallback)), C.uint64_t(streamSize), (C.Lib3MFSeekCallback)(unsafe.Pointer(&theSeekCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } @@ -7947,7 +4686,7 @@ func (inst Model) RemoveCustomContentType(extension string) error { // SetRandomNumberCallback sets the random number generator callback for use in the library. func (inst Model) SetRandomNumberCallback(theCallback RandomNumberCallbackFunc, userData uintptr) error { - ret := C.CCall_lib3mf_model_setrandomnumbercallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFRandomNumberCallback)(unsafe.Pointer(C.Lib3MFRandomNumberCallback_cgo)), (C.Lib3MF_pvoid)(userData)) + ret := C.CCall_lib3mf_model_setrandomnumbercallback(inst.wrapperRef.LibraryHandle, inst.Ref, (C.Lib3MFRandomNumberCallback)(unsafe.Pointer(&theCallback)), (C.Lib3MF_pvoid)(userData)) if ret != 0 { return makeError(uint32(ret)) } diff --git a/Autogenerated/Bindings/Go/lib3mf_dynamic.cc b/Autogenerated/Bindings/Go/lib3mf_dynamic.c similarity index 55% rename from Autogenerated/Bindings/Go/lib3mf_dynamic.cc rename to Autogenerated/Bindings/Go/lib3mf_dynamic.c index 967ef1f16..be75f04e5 100644 --- a/Autogenerated/Bindings/Go/lib3mf_dynamic.cc +++ b/Autogenerated/Bindings/Go/lib3mf_dynamic.c @@ -3696,3 +3696,3264 @@ Lib3MFResult LoadLib3MFWrapperTable(sLib3MFDynamicWrapperTable * pWrapperTable, return LIB3MF_SUCCESS; } + +Lib3MFHandle loadLib3MFLibrary (const char * pFileName) +{ + Lib3MFResult nResult; + sLib3MFDynamicWrapperTable * pWrapperTable = (sLib3MFDynamicWrapperTable *) malloc (sizeof (sLib3MFDynamicWrapperTable)); + if (pWrapperTable != NULL) { + nResult = InitLib3MFWrapperTable (pWrapperTable); + if (nResult != LIB3MF_SUCCESS) { + free (pWrapperTable); + return 0; + } + + nResult = LoadLib3MFWrapperTable (pWrapperTable, pFileName); + if (nResult != LIB3MF_SUCCESS) { + free (pWrapperTable); + return 0; + } + + return (Lib3MFHandle) pWrapperTable; + } +} + +void unloadLib3MFLibrary (Lib3MFHandle nLibraryHandle) +{ + sLib3MFDynamicWrapperTable * pWrapperTable = (sLib3MFDynamicWrapperTable *) malloc (sizeof (sLib3MFDynamicWrapperTable)); + if (pWrapperTable != NULL) { + ReleaseLib3MFWrapperTable (pWrapperTable); + free (pWrapperTable); + } +} + + +Lib3MFResult CCall_lib3mf_base_classtypeid(Lib3MFHandle libraryHandle, Lib3MF_Base pBase, Lib3MF_uint64 * pClassTypeId) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Base_ClassTypeId (pBase, pClassTypeId); +} + + +Lib3MFResult CCall_lib3mf_writer_writetofile(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, const char * pFilename) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_WriteToFile (pWriter, pFilename); +} + + +Lib3MFResult CCall_lib3mf_writer_getstreamsize(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint64 * pStreamSize) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_GetStreamSize (pWriter, pStreamSize); +} + + +Lib3MFResult CCall_lib3mf_writer_writetobuffer(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, const Lib3MF_uint64 nBufferBufferSize, Lib3MF_uint64* pBufferNeededCount, Lib3MF_uint8 * pBufferBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_WriteToBuffer (pWriter, nBufferBufferSize, pBufferNeededCount, pBufferBuffer); +} + + +Lib3MFResult CCall_lib3mf_writer_writetocallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MFWriteCallback pTheWriteCallback, Lib3MFSeekCallback pTheSeekCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_WriteToCallback (pWriter, pTheWriteCallback, pTheSeekCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_writer_setprogresscallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MFProgressCallback pProgressCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_SetProgressCallback (pWriter, pProgressCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_writer_getdecimalprecision(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 * pDecimalPrecision) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_GetDecimalPrecision (pWriter, pDecimalPrecision); +} + + +Lib3MFResult CCall_lib3mf_writer_setdecimalprecision(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 nDecimalPrecision) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_SetDecimalPrecision (pWriter, nDecimalPrecision); +} + + +Lib3MFResult CCall_lib3mf_writer_setstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, bool bStrictModeActive) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_SetStrictModeActive (pWriter, bStrictModeActive); +} + + +Lib3MFResult CCall_lib3mf_writer_getstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, bool * pStrictModeActive) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_GetStrictModeActive (pWriter, pStrictModeActive); +} + + +Lib3MFResult CCall_lib3mf_writer_getwarning(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 nIndex, Lib3MF_uint32 * pErrorCode, const Lib3MF_uint32 nWarningBufferSize, Lib3MF_uint32* pWarningNeededChars, char * pWarningBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_GetWarning (pWriter, nIndex, pErrorCode, nWarningBufferSize, pWarningNeededChars, pWarningBuffer); +} + + +Lib3MFResult CCall_lib3mf_writer_getwarningcount(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_GetWarningCount (pWriter, pCount); +} + + +Lib3MFResult CCall_lib3mf_writer_addkeywrappingcallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, const char * pConsumerID, Lib3MFKeyWrappingCallback pTheCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_AddKeyWrappingCallback (pWriter, pConsumerID, pTheCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_writer_setcontentencryptioncallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MFContentEncryptionCallback pTheCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Writer_SetContentEncryptionCallback (pWriter, pTheCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_reader_readfromfile(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pFilename) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_ReadFromFile (pReader, pFilename); +} + + +Lib3MFResult CCall_lib3mf_reader_readfrombuffer(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint64 nBufferBufferSize, const Lib3MF_uint8 * pBufferBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_ReadFromBuffer (pReader, nBufferBufferSize, pBufferBuffer); +} + + +Lib3MFResult CCall_lib3mf_reader_readfromcallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MFReadCallback pTheReadCallback, Lib3MF_uint64 nStreamSize, Lib3MFSeekCallback pTheSeekCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_ReadFromCallback (pReader, pTheReadCallback, nStreamSize, pTheSeekCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_reader_setprogresscallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MFProgressCallback pProgressCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_SetProgressCallback (pReader, pProgressCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_reader_addrelationtoread(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pRelationShipType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_AddRelationToRead (pReader, pRelationShipType); +} + + +Lib3MFResult CCall_lib3mf_reader_removerelationtoread(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pRelationShipType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_RemoveRelationToRead (pReader, pRelationShipType); +} + + +Lib3MFResult CCall_lib3mf_reader_setstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, bool bStrictModeActive) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_SetStrictModeActive (pReader, bStrictModeActive); +} + + +Lib3MFResult CCall_lib3mf_reader_getstrictmodeactive(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, bool * pStrictModeActive) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_GetStrictModeActive (pReader, pStrictModeActive); +} + + +Lib3MFResult CCall_lib3mf_reader_getwarning(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint32 nIndex, Lib3MF_uint32 * pErrorCode, const Lib3MF_uint32 nWarningBufferSize, Lib3MF_uint32* pWarningNeededChars, char * pWarningBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_GetWarning (pReader, nIndex, pErrorCode, nWarningBufferSize, pWarningNeededChars, pWarningBuffer); +} + + +Lib3MFResult CCall_lib3mf_reader_getwarningcount(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_GetWarningCount (pReader, pCount); +} + + +Lib3MFResult CCall_lib3mf_reader_addkeywrappingcallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char * pConsumerID, Lib3MFKeyWrappingCallback pTheCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_AddKeyWrappingCallback (pReader, pConsumerID, pTheCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_reader_setcontentencryptioncallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MFContentEncryptionCallback pTheCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Reader_SetContentEncryptionCallback (pReader, pTheCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_packagepart_getpath(Lib3MFHandle libraryHandle, Lib3MF_PackagePart pPackagePart, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_PackagePart_GetPath (pPackagePart, nPathBufferSize, pPathNeededChars, pPathBuffer); +} + + +Lib3MFResult CCall_lib3mf_packagepart_setpath(Lib3MFHandle libraryHandle, Lib3MF_PackagePart pPackagePart, const char * pPath) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_PackagePart_SetPath (pPackagePart, pPath); +} + + +Lib3MFResult CCall_lib3mf_resource_getresourceid(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32 * pUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Resource_GetResourceID (pResource, pUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_resource_getuniqueresourceid(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32 * pUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Resource_GetUniqueResourceID (pResource, pUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_resource_packagepart(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_PackagePart * pPackagePart) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Resource_PackagePart (pResource, pPackagePart); +} + + +Lib3MFResult CCall_lib3mf_resource_setpackagepart(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_PackagePart pPackagePart) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Resource_SetPackagePart (pResource, pPackagePart); +} + + +Lib3MFResult CCall_lib3mf_resource_getmodelresourceid(Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32 * pModelResourceId) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Resource_GetModelResourceID (pResource, pModelResourceId); +} + + +Lib3MFResult CCall_lib3mf_resourceiterator_movenext(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, bool * pHasNext) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceIterator_MoveNext (pResourceIterator, pHasNext); +} + + +Lib3MFResult CCall_lib3mf_resourceiterator_moveprevious(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, bool * pHasPrevious) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceIterator_MovePrevious (pResourceIterator, pHasPrevious); +} + + +Lib3MFResult CCall_lib3mf_resourceiterator_getcurrent(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_Resource * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceIterator_GetCurrent (pResourceIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_resourceiterator_clone(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_ResourceIterator * pOutResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceIterator_Clone (pResourceIterator, pOutResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_resourceiterator_count(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceIterator_Count (pResourceIterator, pCount); +} + + +Lib3MFResult CCall_lib3mf_slicestackiterator_getcurrentslicestack(Lib3MFHandle libraryHandle, Lib3MF_SliceStackIterator pSliceStackIterator, Lib3MF_SliceStack * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStackIterator_GetCurrentSliceStack (pSliceStackIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_objectiterator_getcurrentobject(Lib3MFHandle libraryHandle, Lib3MF_ObjectIterator pObjectIterator, Lib3MF_Object * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ObjectIterator_GetCurrentObject (pObjectIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_meshobjectiterator_getcurrentmeshobject(Lib3MFHandle libraryHandle, Lib3MF_MeshObjectIterator pMeshObjectIterator, Lib3MF_MeshObject * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObjectIterator_GetCurrentMeshObject (pMeshObjectIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_componentsobjectiterator_getcurrentcomponentsobject(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObjectIterator pComponentsObjectIterator, Lib3MF_ComponentsObject * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ComponentsObjectIterator_GetCurrentComponentsObject (pComponentsObjectIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_texture2diterator_getcurrenttexture2d(Lib3MFHandle libraryHandle, Lib3MF_Texture2DIterator pTexture2DIterator, Lib3MF_Texture2D * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DIterator_GetCurrentTexture2D (pTexture2DIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroupiterator_getcurrentbasematerialgroup(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroupIterator pBaseMaterialGroupIterator, Lib3MF_BaseMaterialGroup * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroupIterator_GetCurrentBaseMaterialGroup (pBaseMaterialGroupIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_colorgroupiterator_getcurrentcolorgroup(Lib3MFHandle libraryHandle, Lib3MF_ColorGroupIterator pColorGroupIterator, Lib3MF_ColorGroup * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorGroupIterator_GetCurrentColorGroup (pColorGroupIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_texture2dgroupiterator_getcurrenttexture2dgroup(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroupIterator pTexture2DGroupIterator, Lib3MF_Texture2DGroup * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DGroupIterator_GetCurrentTexture2DGroup (pTexture2DGroupIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_compositematerialsiterator_getcurrentcompositematerials(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterialsIterator pCompositeMaterialsIterator, Lib3MF_CompositeMaterials * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CompositeMaterialsIterator_GetCurrentCompositeMaterials (pCompositeMaterialsIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroupiterator_getcurrentmultipropertygroup(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroupIterator pMultiPropertyGroupIterator, Lib3MF_MultiPropertyGroup * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroupIterator_GetCurrentMultiPropertyGroup (pMultiPropertyGroupIterator, pResource); +} + + +Lib3MFResult CCall_lib3mf_metadata_getnamespace(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nNameSpaceBufferSize, Lib3MF_uint32* pNameSpaceNeededChars, char * pNameSpaceBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_GetNameSpace (pMetaData, nNameSpaceBufferSize, pNameSpaceNeededChars, pNameSpaceBuffer); +} + + +Lib3MFResult CCall_lib3mf_metadata_setnamespace(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pNameSpace) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_SetNameSpace (pMetaData, pNameSpace); +} + + +Lib3MFResult CCall_lib3mf_metadata_getname(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_GetName (pMetaData, nNameBufferSize, pNameNeededChars, pNameBuffer); +} + + +Lib3MFResult CCall_lib3mf_metadata_setname(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pName) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_SetName (pMetaData, pName); +} + + +Lib3MFResult CCall_lib3mf_metadata_getkey(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nKeyBufferSize, Lib3MF_uint32* pKeyNeededChars, char * pKeyBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_GetKey (pMetaData, nKeyBufferSize, pKeyNeededChars, pKeyBuffer); +} + + +Lib3MFResult CCall_lib3mf_metadata_getmustpreserve(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, bool * pMustPreserve) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_GetMustPreserve (pMetaData, pMustPreserve); +} + + +Lib3MFResult CCall_lib3mf_metadata_setmustpreserve(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, bool bMustPreserve) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_SetMustPreserve (pMetaData, bMustPreserve); +} + + +Lib3MFResult CCall_lib3mf_metadata_gettype(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nTypeBufferSize, Lib3MF_uint32* pTypeNeededChars, char * pTypeBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_GetType (pMetaData, nTypeBufferSize, pTypeNeededChars, pTypeBuffer); +} + + +Lib3MFResult CCall_lib3mf_metadata_settype(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_SetType (pMetaData, pType); +} + + +Lib3MFResult CCall_lib3mf_metadata_getvalue(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const Lib3MF_uint32 nValueBufferSize, Lib3MF_uint32* pValueNeededChars, char * pValueBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_GetValue (pMetaData, nValueBufferSize, pValueNeededChars, pValueBuffer); +} + + +Lib3MFResult CCall_lib3mf_metadata_setvalue(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char * pValue) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaData_SetValue (pMetaData, pValue); +} + + +Lib3MFResult CCall_lib3mf_metadatagroup_getmetadatacount(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaDataGroup_GetMetaDataCount (pMetaDataGroup, pCount); +} + + +Lib3MFResult CCall_lib3mf_metadatagroup_getmetadata(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 nIndex, Lib3MF_MetaData * pMetaData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaDataGroup_GetMetaData (pMetaDataGroup, nIndex, pMetaData); +} + + +Lib3MFResult CCall_lib3mf_metadatagroup_getmetadatabykey(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, const char * pNameSpace, const char * pName, Lib3MF_MetaData * pMetaData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaDataGroup_GetMetaDataByKey (pMetaDataGroup, pNameSpace, pName, pMetaData); +} + + +Lib3MFResult CCall_lib3mf_metadatagroup_removemetadatabyindex(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 nIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaDataGroup_RemoveMetaDataByIndex (pMetaDataGroup, nIndex); +} + + +Lib3MFResult CCall_lib3mf_metadatagroup_removemetadata(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_MetaData pTheMetaData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaDataGroup_RemoveMetaData (pMetaDataGroup, pTheMetaData); +} + + +Lib3MFResult CCall_lib3mf_metadatagroup_addmetadata(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, const char * pNameSpace, const char * pName, const char * pValue, const char * pType, bool bMustPreserve, Lib3MF_MetaData * pMetaData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MetaDataGroup_AddMetaData (pMetaDataGroup, pNameSpace, pName, pValue, pType, bMustPreserve, pMetaData); +} + + +Lib3MFResult CCall_lib3mf_object_gettype(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFObjectType * pObjectType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetType (pObject, pObjectType); +} + + +Lib3MFResult CCall_lib3mf_object_settype(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFObjectType eObjectType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_SetType (pObject, eObjectType); +} + + +Lib3MFResult CCall_lib3mf_object_getname(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetName (pObject, nNameBufferSize, pNameNeededChars, pNameBuffer); +} + + +Lib3MFResult CCall_lib3mf_object_setname(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char * pName) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_SetName (pObject, pName); +} + + +Lib3MFResult CCall_lib3mf_object_getpartnumber(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const Lib3MF_uint32 nPartNumberBufferSize, Lib3MF_uint32* pPartNumberNeededChars, char * pPartNumberBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetPartNumber (pObject, nPartNumberBufferSize, pPartNumberNeededChars, pPartNumberBuffer); +} + + +Lib3MFResult CCall_lib3mf_object_setpartnumber(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char * pPartNumber) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_SetPartNumber (pObject, pPartNumber); +} + + +Lib3MFResult CCall_lib3mf_object_ismeshobject(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pIsMeshObject) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_IsMeshObject (pObject, pIsMeshObject); +} + + +Lib3MFResult CCall_lib3mf_object_iscomponentsobject(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pIsComponentsObject) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_IsComponentsObject (pObject, pIsComponentsObject); +} + + +Lib3MFResult CCall_lib3mf_object_isvalid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pIsValid) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_IsValid (pObject, pIsValid); +} + + +Lib3MFResult CCall_lib3mf_object_setattachmentasthumbnail(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_Attachment pAttachment) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_SetAttachmentAsThumbnail (pObject, pAttachment); +} + + +Lib3MFResult CCall_lib3mf_object_getthumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_Attachment * pAttachment) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetThumbnailAttachment (pObject, pAttachment); +} + + +Lib3MFResult CCall_lib3mf_object_clearthumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Object pObject) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_ClearThumbnailAttachment (pObject); +} + + +Lib3MFResult CCall_lib3mf_object_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, sLib3MFBox * pOutbox) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetOutbox (pObject, pOutbox); +} + + +Lib3MFResult CCall_lib3mf_object_getuuid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetUUID (pObject, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_object_setuuid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char * pUUID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_SetUUID (pObject, pUUID); +} + + +Lib3MFResult CCall_lib3mf_object_getmetadatagroup(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_MetaDataGroup * pMetaDataGroup) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetMetaDataGroup (pObject, pMetaDataGroup); +} + + +Lib3MFResult CCall_lib3mf_object_setslicesmeshresolution(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFSlicesMeshResolution eMeshResolution) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_SetSlicesMeshResolution (pObject, eMeshResolution); +} + + +Lib3MFResult CCall_lib3mf_object_getslicesmeshresolution(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFSlicesMeshResolution * pMeshResolution) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetSlicesMeshResolution (pObject, pMeshResolution); +} + + +Lib3MFResult CCall_lib3mf_object_hasslices(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool bRecursive, bool * pHasSlices) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_HasSlices (pObject, bRecursive, pHasSlices); +} + + +Lib3MFResult CCall_lib3mf_object_clearslicestack(Lib3MFHandle libraryHandle, Lib3MF_Object pObject) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_ClearSliceStack (pObject); +} + + +Lib3MFResult CCall_lib3mf_object_getslicestack(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_SliceStack * pSliceStackInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_GetSliceStack (pObject, pSliceStackInstance); +} + + +Lib3MFResult CCall_lib3mf_object_assignslicestack(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_SliceStack pSliceStackInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Object_AssignSliceStack (pObject, pSliceStackInstance); +} + + +Lib3MFResult CCall_lib3mf_meshobject_getvertexcount(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 * pVertexCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetVertexCount (pMeshObject, pVertexCount); +} + + +Lib3MFResult CCall_lib3mf_meshobject_gettrianglecount(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 * pVertexCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetTriangleCount (pMeshObject, pVertexCount); +} + + +Lib3MFResult CCall_lib3mf_meshobject_getvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFPosition * pCoordinates) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetVertex (pMeshObject, nIndex, pCoordinates); +} + + +Lib3MFResult CCall_lib3mf_meshobject_setvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, const sLib3MFPosition * pCoordinates) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_SetVertex (pMeshObject, nIndex, pCoordinates); +} + + +Lib3MFResult CCall_lib3mf_meshobject_addvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const sLib3MFPosition * pCoordinates, Lib3MF_uint32 * pNewIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_AddVertex (pMeshObject, pCoordinates, pNewIndex); +} + + +Lib3MFResult CCall_lib3mf_meshobject_getvertices(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const Lib3MF_uint64 nVerticesBufferSize, Lib3MF_uint64* pVerticesNeededCount, sLib3MFPosition * pVerticesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetVertices (pMeshObject, nVerticesBufferSize, pVerticesNeededCount, pVerticesBuffer); +} + + +Lib3MFResult CCall_lib3mf_meshobject_gettriangle(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFTriangle * pIndices) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetTriangle (pMeshObject, nIndex, pIndices); +} + + +Lib3MFResult CCall_lib3mf_meshobject_settriangle(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, const sLib3MFTriangle * pIndices) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_SetTriangle (pMeshObject, nIndex, pIndices); +} + + +Lib3MFResult CCall_lib3mf_meshobject_addtriangle(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const sLib3MFTriangle * pIndices, Lib3MF_uint32 * pNewIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_AddTriangle (pMeshObject, pIndices, pNewIndex); +} + + +Lib3MFResult CCall_lib3mf_meshobject_gettriangleindices(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const Lib3MF_uint64 nIndicesBufferSize, Lib3MF_uint64* pIndicesNeededCount, sLib3MFTriangle * pIndicesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetTriangleIndices (pMeshObject, nIndicesBufferSize, pIndicesNeededCount, pIndicesBuffer); +} + + +Lib3MFResult CCall_lib3mf_meshobject_setobjectlevelproperty(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nUniqueResourceID, Lib3MF_uint32 nPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_SetObjectLevelProperty (pMeshObject, nUniqueResourceID, nPropertyID); +} + + +Lib3MFResult CCall_lib3mf_meshobject_getobjectlevelproperty(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 * pUniqueResourceID, Lib3MF_uint32 * pPropertyID, bool * pHasObjectLevelProperty) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetObjectLevelProperty (pMeshObject, pUniqueResourceID, pPropertyID, pHasObjectLevelProperty); +} + + +Lib3MFResult CCall_lib3mf_meshobject_settriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, const sLib3MFTriangleProperties * pProperties) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_SetTriangleProperties (pMeshObject, nIndex, pProperties); +} + + +Lib3MFResult CCall_lib3mf_meshobject_gettriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFTriangleProperties * pProperty) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetTriangleProperties (pMeshObject, nIndex, pProperty); +} + + +Lib3MFResult CCall_lib3mf_meshobject_setalltriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint64 nPropertiesArrayBufferSize, const sLib3MFTriangleProperties * pPropertiesArrayBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_SetAllTriangleProperties (pMeshObject, nPropertiesArrayBufferSize, pPropertiesArrayBuffer); +} + + +Lib3MFResult CCall_lib3mf_meshobject_getalltriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, const Lib3MF_uint64 nPropertiesArrayBufferSize, Lib3MF_uint64* pPropertiesArrayNeededCount, sLib3MFTriangleProperties * pPropertiesArrayBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_GetAllTriangleProperties (pMeshObject, nPropertiesArrayBufferSize, pPropertiesArrayNeededCount, pPropertiesArrayBuffer); +} + + +Lib3MFResult CCall_lib3mf_meshobject_clearallproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_ClearAllProperties (pMeshObject); +} + + +Lib3MFResult CCall_lib3mf_meshobject_setgeometry(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint64 nVerticesBufferSize, const sLib3MFPosition * pVerticesBuffer, Lib3MF_uint64 nIndicesBufferSize, const sLib3MFTriangle * pIndicesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_SetGeometry (pMeshObject, nVerticesBufferSize, pVerticesBuffer, nIndicesBufferSize, pIndicesBuffer); +} + + +Lib3MFResult CCall_lib3mf_meshobject_ismanifoldandoriented(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, bool * pIsManifoldAndOriented) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_IsManifoldAndOriented (pMeshObject, pIsManifoldAndOriented); +} + + +Lib3MFResult CCall_lib3mf_meshobject_beamlattice(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_BeamLattice * pTheBeamLattice) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MeshObject_BeamLattice (pMeshObject, pTheBeamLattice); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getminlength(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_double * pMinLength) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetMinLength (pBeamLattice, pMinLength); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setminlength(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_double dMinLength) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetMinLength (pBeamLattice, dMinLength); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getclipping(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeClipMode * pClipMode, Lib3MF_uint32 * pUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetClipping (pBeamLattice, pClipMode, pUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setclipping(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeClipMode eClipMode, Lib3MF_uint32 nUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetClipping (pBeamLattice, eClipMode, nUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getrepresentation(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, bool * pHasRepresentation, Lib3MF_uint32 * pUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetRepresentation (pBeamLattice, pHasRepresentation, pUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setrepresentation(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetRepresentation (pBeamLattice, nUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getballoptions(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeBallMode * pBallMode, Lib3MF_double * pBallRadius) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBallOptions (pBeamLattice, pBallMode, pBallRadius); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setballoptions(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, eLib3MFBeamLatticeBallMode eBallMode, Lib3MF_double dBallRadius) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetBallOptions (pBeamLattice, eBallMode, dBallRadius); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getbeamcount(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBeamCount (pBeamLattice, pCount); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getbeam(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, sLib3MFBeam * pBeamInfo) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBeam (pBeamLattice, nIndex, pBeamInfo); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_addbeam(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const sLib3MFBeam * pBeamInfo, Lib3MF_uint32 * pIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_AddBeam (pBeamLattice, pBeamInfo, pIndex); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setbeam(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, const sLib3MFBeam * pBeamInfo) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetBeam (pBeamLattice, nIndex, pBeamInfo); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setbeams(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint64 nBeamInfoBufferSize, const sLib3MFBeam * pBeamInfoBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetBeams (pBeamLattice, nBeamInfoBufferSize, pBeamInfoBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getbeams(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const Lib3MF_uint64 nBeamInfoBufferSize, Lib3MF_uint64* pBeamInfoNeededCount, sLib3MFBeam * pBeamInfoBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBeams (pBeamLattice, nBeamInfoBufferSize, pBeamInfoNeededCount, pBeamInfoBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getballcount(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBallCount (pBeamLattice, pCount); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getball(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, sLib3MFBall * pBallInfo) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBall (pBeamLattice, nIndex, pBallInfo); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_addball(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const sLib3MFBall * pBallInfo, Lib3MF_uint32 * pIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_AddBall (pBeamLattice, pBallInfo, pIndex); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setball(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, const sLib3MFBall * pBallInfo) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetBall (pBeamLattice, nIndex, pBallInfo); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_setballs(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint64 nBallInfoBufferSize, const sLib3MFBall * pBallInfoBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_SetBalls (pBeamLattice, nBallInfoBufferSize, pBallInfoBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getballs(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const Lib3MF_uint64 nBallInfoBufferSize, Lib3MF_uint64* pBallInfoNeededCount, sLib3MFBall * pBallInfoBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBalls (pBeamLattice, nBallInfoBufferSize, pBallInfoNeededCount, pBallInfoBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getbeamsetcount(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBeamSetCount (pBeamLattice, pCount); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_addbeamset(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_BeamSet * pBeamSet) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_AddBeamSet (pBeamLattice, pBeamSet); +} + + +Lib3MFResult CCall_lib3mf_beamlattice_getbeamset(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, Lib3MF_BeamSet * pBeamSet) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamLattice_GetBeamSet (pBeamLattice, nIndex, pBeamSet); +} + + +Lib3MFResult CCall_lib3mf_component_getobjectresource(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, Lib3MF_Object * pObjectResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Component_GetObjectResource (pComponent, pObjectResource); +} + + +Lib3MFResult CCall_lib3mf_component_getobjectresourceid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, Lib3MF_uint32 * pUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Component_GetObjectResourceID (pComponent, pUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_component_getuuid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Component_GetUUID (pComponent, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_component_setuuid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, const char * pUUID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Component_SetUUID (pComponent, pUUID); +} + + +Lib3MFResult CCall_lib3mf_component_hastransform(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, bool * pHasTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Component_HasTransform (pComponent, pHasTransform); +} + + +Lib3MFResult CCall_lib3mf_component_gettransform(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Component_GetTransform (pComponent, pTransform); +} + + +Lib3MFResult CCall_lib3mf_component_settransform(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, const sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Component_SetTransform (pComponent, pTransform); +} + + +Lib3MFResult CCall_lib3mf_componentsobject_addcomponent(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObject pComponentsObject, Lib3MF_Object pObjectResource, const sLib3MFTransform * pTransform, Lib3MF_Component * pComponentInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ComponentsObject_AddComponent (pComponentsObject, pObjectResource, pTransform, pComponentInstance); +} + + +Lib3MFResult CCall_lib3mf_componentsobject_getcomponent(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObject pComponentsObject, Lib3MF_uint32 nIndex, Lib3MF_Component * pComponentInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ComponentsObject_GetComponent (pComponentsObject, nIndex, pComponentInstance); +} + + +Lib3MFResult CCall_lib3mf_componentsobject_getcomponentcount(Lib3MFHandle libraryHandle, Lib3MF_ComponentsObject pComponentsObject, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ComponentsObject_GetComponentCount (pComponentsObject, pCount); +} + + +Lib3MFResult CCall_lib3mf_beamset_setname(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const char * pName) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_SetName (pBeamSet, pName); +} + + +Lib3MFResult CCall_lib3mf_beamset_getname(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_GetName (pBeamSet, nNameBufferSize, pNameNeededChars, pNameBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamset_setidentifier(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const char * pIdentifier) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_SetIdentifier (pBeamSet, pIdentifier); +} + + +Lib3MFResult CCall_lib3mf_beamset_getidentifier(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint32 nIdentifierBufferSize, Lib3MF_uint32* pIdentifierNeededChars, char * pIdentifierBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_GetIdentifier (pBeamSet, nIdentifierBufferSize, pIdentifierNeededChars, pIdentifierBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamset_getreferencecount(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_GetReferenceCount (pBeamSet, pCount); +} + + +Lib3MFResult CCall_lib3mf_beamset_setreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint64 nReferencesBufferSize, const Lib3MF_uint32 * pReferencesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_SetReferences (pBeamSet, nReferencesBufferSize, pReferencesBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamset_getreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint64 nReferencesBufferSize, Lib3MF_uint64* pReferencesNeededCount, Lib3MF_uint32 * pReferencesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_GetReferences (pBeamSet, nReferencesBufferSize, pReferencesNeededCount, pReferencesBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamset_getballreferencecount(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_GetBallReferenceCount (pBeamSet, pCount); +} + + +Lib3MFResult CCall_lib3mf_beamset_setballreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint64 nBallReferencesBufferSize, const Lib3MF_uint32 * pBallReferencesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_SetBallReferences (pBeamSet, nBallReferencesBufferSize, pBallReferencesBuffer); +} + + +Lib3MFResult CCall_lib3mf_beamset_getballreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const Lib3MF_uint64 nBallReferencesBufferSize, Lib3MF_uint64* pBallReferencesNeededCount, Lib3MF_uint32 * pBallReferencesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BeamSet_GetBallReferences (pBeamSet, nBallReferencesBufferSize, pBallReferencesNeededCount, pBallReferencesBuffer); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_GetCount (pBaseMaterialGroup, pCount); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_GetAllPropertyIDs (pBaseMaterialGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_addmaterial(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, const char * pName, const sLib3MFColor * pDisplayColor, Lib3MF_uint32 * pPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_AddMaterial (pBaseMaterialGroup, pName, pDisplayColor, pPropertyID); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_removematerial(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_RemoveMaterial (pBaseMaterialGroup, nPropertyID); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_getname(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char * pNameBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_GetName (pBaseMaterialGroup, nPropertyID, nNameBufferSize, pNameNeededChars, pNameBuffer); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_setname(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const char * pName) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_SetName (pBaseMaterialGroup, nPropertyID, pName); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_setdisplaycolor(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const sLib3MFColor * pTheColor) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_SetDisplayColor (pBaseMaterialGroup, nPropertyID, pTheColor); +} + + +Lib3MFResult CCall_lib3mf_basematerialgroup_getdisplaycolor(Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, sLib3MFColor * pTheColor) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BaseMaterialGroup_GetDisplayColor (pBaseMaterialGroup, nPropertyID, pTheColor); +} + + +Lib3MFResult CCall_lib3mf_colorgroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorGroup_GetCount (pColorGroup, pCount); +} + + +Lib3MFResult CCall_lib3mf_colorgroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorGroup_GetAllPropertyIDs (pColorGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); +} + + +Lib3MFResult CCall_lib3mf_colorgroup_addcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, const sLib3MFColor * pTheColor, Lib3MF_uint32 * pPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorGroup_AddColor (pColorGroup, pTheColor, pPropertyID); +} + + +Lib3MFResult CCall_lib3mf_colorgroup_removecolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorGroup_RemoveColor (pColorGroup, nPropertyID); +} + + +Lib3MFResult CCall_lib3mf_colorgroup_setcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID, const sLib3MFColor * pTheColor) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorGroup_SetColor (pColorGroup, nPropertyID, pTheColor); +} + + +Lib3MFResult CCall_lib3mf_colorgroup_getcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID, sLib3MFColor * pTheColor) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorGroup_GetColor (pColorGroup, nPropertyID, pTheColor); +} + + +Lib3MFResult CCall_lib3mf_texture2dgroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DGroup_GetCount (pTexture2DGroup, pCount); +} + + +Lib3MFResult CCall_lib3mf_texture2dgroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DGroup_GetAllPropertyIDs (pTexture2DGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); +} + + +Lib3MFResult CCall_lib3mf_texture2dgroup_addtex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, const sLib3MFTex2Coord * pUVCoordinate, Lib3MF_uint32 * pPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DGroup_AddTex2Coord (pTexture2DGroup, pUVCoordinate, pPropertyID); +} + + +Lib3MFResult CCall_lib3mf_texture2dgroup_gettex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32 nPropertyID, sLib3MFTex2Coord * pUVCoordinate) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DGroup_GetTex2Coord (pTexture2DGroup, nPropertyID, pUVCoordinate); +} + + +Lib3MFResult CCall_lib3mf_texture2dgroup_removetex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32 nPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DGroup_RemoveTex2Coord (pTexture2DGroup, nPropertyID); +} + + +Lib3MFResult CCall_lib3mf_texture2dgroup_gettexture2d(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_Texture2D * pTexture2DInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2DGroup_GetTexture2D (pTexture2DGroup, pTexture2DInstance); +} + + +Lib3MFResult CCall_lib3mf_compositematerials_getcount(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CompositeMaterials_GetCount (pCompositeMaterials, pCount); +} + + +Lib3MFResult CCall_lib3mf_compositematerials_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CompositeMaterials_GetAllPropertyIDs (pCompositeMaterials, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); +} + + +Lib3MFResult CCall_lib3mf_compositematerials_getbasematerialgroup(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_BaseMaterialGroup * pBaseMaterialGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CompositeMaterials_GetBaseMaterialGroup (pCompositeMaterials, pBaseMaterialGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_compositematerials_addcomposite(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint64 nCompositeBufferSize, const sLib3MFCompositeConstituent * pCompositeBuffer, Lib3MF_uint32 * pPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CompositeMaterials_AddComposite (pCompositeMaterials, nCompositeBufferSize, pCompositeBuffer, pPropertyID); +} + + +Lib3MFResult CCall_lib3mf_compositematerials_removecomposite(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 nPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CompositeMaterials_RemoveComposite (pCompositeMaterials, nPropertyID); +} + + +Lib3MFResult CCall_lib3mf_compositematerials_getcomposite(Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 nPropertyID, const Lib3MF_uint64 nCompositeBufferSize, Lib3MF_uint64* pCompositeNeededCount, sLib3MFCompositeConstituent * pCompositeBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CompositeMaterials_GetComposite (pCompositeMaterials, nPropertyID, nCompositeBufferSize, pCompositeNeededCount, pCompositeBuffer); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_getcount(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_GetCount (pMultiPropertyGroup, pCount); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_GetAllPropertyIDs (pMultiPropertyGroup, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_addmultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint64 nPropertyIDsBufferSize, const Lib3MF_uint32 * pPropertyIDsBuffer, Lib3MF_uint32 * pPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_AddMultiProperty (pMultiPropertyGroup, nPropertyIDsBufferSize, pPropertyIDsBuffer, pPropertyID); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_setmultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID, Lib3MF_uint64 nPropertyIDsBufferSize, const Lib3MF_uint32 * pPropertyIDsBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_SetMultiProperty (pMultiPropertyGroup, nPropertyID, nPropertyIDsBufferSize, pPropertyIDsBuffer); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_getmultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID, const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32 * pPropertyIDsBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_GetMultiProperty (pMultiPropertyGroup, nPropertyID, nPropertyIDsBufferSize, pPropertyIDsNeededCount, pPropertyIDsBuffer); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_removemultiproperty(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_RemoveMultiProperty (pMultiPropertyGroup, nPropertyID); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_getlayercount(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_GetLayerCount (pMultiPropertyGroup, pCount); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_addlayer(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, const sLib3MFMultiPropertyLayer * pTheLayer, Lib3MF_uint32 * pLayerIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_AddLayer (pMultiPropertyGroup, pTheLayer, pLayerIndex); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_getlayer(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nLayerIndex, sLib3MFMultiPropertyLayer * pTheLayer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_GetLayer (pMultiPropertyGroup, nLayerIndex, pTheLayer); +} + + +Lib3MFResult CCall_lib3mf_multipropertygroup_removelayer(Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nLayerIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_MultiPropertyGroup_RemoveLayer (pMultiPropertyGroup, nLayerIndex); +} + + +Lib3MFResult CCall_lib3mf_attachment_getpath(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_GetPath (pAttachment, nPathBufferSize, pPathNeededChars, pPathBuffer); +} + + +Lib3MFResult CCall_lib3mf_attachment_setpath(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pPath) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_SetPath (pAttachment, pPath); +} + + +Lib3MFResult CCall_lib3mf_attachment_packagepart(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_PackagePart * pPackagePart) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_PackagePart (pAttachment, pPackagePart); +} + + +Lib3MFResult CCall_lib3mf_attachment_getrelationshiptype(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_GetRelationShipType (pAttachment, nPathBufferSize, pPathNeededChars, pPathBuffer); +} + + +Lib3MFResult CCall_lib3mf_attachment_setrelationshiptype(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pPath) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_SetRelationShipType (pAttachment, pPath); +} + + +Lib3MFResult CCall_lib3mf_attachment_writetofile(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pFileName) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_WriteToFile (pAttachment, pFileName); +} + + +Lib3MFResult CCall_lib3mf_attachment_readfromfile(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char * pFileName) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_ReadFromFile (pAttachment, pFileName); +} + + +Lib3MFResult CCall_lib3mf_attachment_readfromcallback(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MFReadCallback pTheReadCallback, Lib3MF_uint64 nStreamSize, Lib3MFSeekCallback pTheSeekCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_ReadFromCallback (pAttachment, pTheReadCallback, nStreamSize, pTheSeekCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_attachment_getstreamsize(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_uint64 * pStreamSize) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_GetStreamSize (pAttachment, pStreamSize); +} + + +Lib3MFResult CCall_lib3mf_attachment_writetobuffer(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const Lib3MF_uint64 nBufferBufferSize, Lib3MF_uint64* pBufferNeededCount, Lib3MF_uint8 * pBufferBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_WriteToBuffer (pAttachment, nBufferBufferSize, pBufferNeededCount, pBufferBuffer); +} + + +Lib3MFResult CCall_lib3mf_attachment_readfrombuffer(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_uint64 nBufferBufferSize, const Lib3MF_uint8 * pBufferBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Attachment_ReadFromBuffer (pAttachment, nBufferBufferSize, pBufferBuffer); +} + + +Lib3MFResult CCall_lib3mf_texture2d_getattachment(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, Lib3MF_Attachment * pAttachment) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_GetAttachment (pTexture2D, pAttachment); +} + + +Lib3MFResult CCall_lib3mf_texture2d_setattachment(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, Lib3MF_Attachment pAttachment) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_SetAttachment (pTexture2D, pAttachment); +} + + +Lib3MFResult CCall_lib3mf_texture2d_getcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureType * pContentType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_GetContentType (pTexture2D, pContentType); +} + + +Lib3MFResult CCall_lib3mf_texture2d_setcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureType eContentType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_SetContentType (pTexture2D, eContentType); +} + + +Lib3MFResult CCall_lib3mf_texture2d_gettilestyleuv(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureTileStyle * pTileStyleU, eLib3MFTextureTileStyle * pTileStyleV) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_GetTileStyleUV (pTexture2D, pTileStyleU, pTileStyleV); +} + + +Lib3MFResult CCall_lib3mf_texture2d_settilestyleuv(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureTileStyle eTileStyleU, eLib3MFTextureTileStyle eTileStyleV) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_SetTileStyleUV (pTexture2D, eTileStyleU, eTileStyleV); +} + + +Lib3MFResult CCall_lib3mf_texture2d_getfilter(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureFilter * pFilter) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_GetFilter (pTexture2D, pFilter); +} + + +Lib3MFResult CCall_lib3mf_texture2d_setfilter(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureFilter eFilter) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Texture2D_SetFilter (pTexture2D, eFilter); +} + + +Lib3MFResult CCall_lib3mf_builditem_getobjectresource(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_Object * pObjectResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_GetObjectResource (pBuildItem, pObjectResource); +} + + +Lib3MFResult CCall_lib3mf_builditem_getuuid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_GetUUID (pBuildItem, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_builditem_setuuid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const char * pUUID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_SetUUID (pBuildItem, pUUID); +} + + +Lib3MFResult CCall_lib3mf_builditem_getobjectresourceid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_uint32 * pUniqueResourceID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_GetObjectResourceID (pBuildItem, pUniqueResourceID); +} + + +Lib3MFResult CCall_lib3mf_builditem_hasobjecttransform(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, bool * pHasTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_HasObjectTransform (pBuildItem, pHasTransform); +} + + +Lib3MFResult CCall_lib3mf_builditem_getobjecttransform(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_GetObjectTransform (pBuildItem, pTransform); +} + + +Lib3MFResult CCall_lib3mf_builditem_setobjecttransform(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_SetObjectTransform (pBuildItem, pTransform); +} + + +Lib3MFResult CCall_lib3mf_builditem_getpartnumber(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const Lib3MF_uint32 nPartNumberBufferSize, Lib3MF_uint32* pPartNumberNeededChars, char * pPartNumberBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_GetPartNumber (pBuildItem, nPartNumberBufferSize, pPartNumberNeededChars, pPartNumberBuffer); +} + + +Lib3MFResult CCall_lib3mf_builditem_setpartnumber(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const char * pSetPartnumber) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_SetPartNumber (pBuildItem, pSetPartnumber); +} + + +Lib3MFResult CCall_lib3mf_builditem_getmetadatagroup(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_MetaDataGroup * pMetaDataGroup) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_GetMetaDataGroup (pBuildItem, pMetaDataGroup); +} + + +Lib3MFResult CCall_lib3mf_builditem_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, sLib3MFBox * pOutbox) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItem_GetOutbox (pBuildItem, pOutbox); +} + + +Lib3MFResult CCall_lib3mf_builditemiterator_movenext(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, bool * pHasNext) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItemIterator_MoveNext (pBuildItemIterator, pHasNext); +} + + +Lib3MFResult CCall_lib3mf_builditemiterator_moveprevious(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, bool * pHasPrevious) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItemIterator_MovePrevious (pBuildItemIterator, pHasPrevious); +} + + +Lib3MFResult CCall_lib3mf_builditemiterator_getcurrent(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_BuildItem * pBuildItem) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItemIterator_GetCurrent (pBuildItemIterator, pBuildItem); +} + + +Lib3MFResult CCall_lib3mf_builditemiterator_clone(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_BuildItemIterator * pOutBuildItemIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItemIterator_Clone (pBuildItemIterator, pOutBuildItemIterator); +} + + +Lib3MFResult CCall_lib3mf_builditemiterator_count(Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_BuildItemIterator_Count (pBuildItemIterator, pCount); +} + + +Lib3MFResult CCall_lib3mf_slice_setvertices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nVerticesBufferSize, const sLib3MFPosition2D * pVerticesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_SetVertices (pSlice, nVerticesBufferSize, pVerticesBuffer); +} + + +Lib3MFResult CCall_lib3mf_slice_getvertices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, const Lib3MF_uint64 nVerticesBufferSize, Lib3MF_uint64* pVerticesNeededCount, sLib3MFPosition2D * pVerticesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_GetVertices (pSlice, nVerticesBufferSize, pVerticesNeededCount, pVerticesBuffer); +} + + +Lib3MFResult CCall_lib3mf_slice_getvertexcount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_GetVertexCount (pSlice, pCount); +} + + +Lib3MFResult CCall_lib3mf_slice_addpolygon(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndicesBufferSize, const Lib3MF_uint32 * pIndicesBuffer, Lib3MF_uint64 * pIndex) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_AddPolygon (pSlice, nIndicesBufferSize, pIndicesBuffer, pIndex); +} + + +Lib3MFResult CCall_lib3mf_slice_getpolygoncount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_GetPolygonCount (pSlice, pCount); +} + + +Lib3MFResult CCall_lib3mf_slice_setpolygonindices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, Lib3MF_uint64 nIndicesBufferSize, const Lib3MF_uint32 * pIndicesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_SetPolygonIndices (pSlice, nIndex, nIndicesBufferSize, pIndicesBuffer); +} + + +Lib3MFResult CCall_lib3mf_slice_getpolygonindices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, const Lib3MF_uint64 nIndicesBufferSize, Lib3MF_uint64* pIndicesNeededCount, Lib3MF_uint32 * pIndicesBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_GetPolygonIndices (pSlice, nIndex, nIndicesBufferSize, pIndicesNeededCount, pIndicesBuffer); +} + + +Lib3MFResult CCall_lib3mf_slice_getpolygonindexcount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_GetPolygonIndexCount (pSlice, nIndex, pCount); +} + + +Lib3MFResult CCall_lib3mf_slice_getztop(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_double * pZTop) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Slice_GetZTop (pSlice, pZTop); +} + + +Lib3MFResult CCall_lib3mf_slicestack_getbottomz(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_double * pZBottom) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_GetBottomZ (pSliceStack, pZBottom); +} + + +Lib3MFResult CCall_lib3mf_slicestack_getslicecount(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_GetSliceCount (pSliceStack, pCount); +} + + +Lib3MFResult CCall_lib3mf_slicestack_getslice(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 nSliceIndex, Lib3MF_Slice * pTheSlice) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_GetSlice (pSliceStack, nSliceIndex, pTheSlice); +} + + +Lib3MFResult CCall_lib3mf_slicestack_addslice(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_double dZTop, Lib3MF_Slice * pTheSlice) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_AddSlice (pSliceStack, dZTop, pTheSlice); +} + + +Lib3MFResult CCall_lib3mf_slicestack_getslicerefcount(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_GetSliceRefCount (pSliceStack, pCount); +} + + +Lib3MFResult CCall_lib3mf_slicestack_addslicestackreference(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_SliceStack pTheSliceStack) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_AddSliceStackReference (pSliceStack, pTheSliceStack); +} + + +Lib3MFResult CCall_lib3mf_slicestack_getslicestackreference(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 nSliceRefIndex, Lib3MF_SliceStack * pTheSliceStack) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_GetSliceStackReference (pSliceStack, nSliceRefIndex, pTheSliceStack); +} + + +Lib3MFResult CCall_lib3mf_slicestack_collapseslicereferences(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_CollapseSliceReferences (pSliceStack); +} + + +Lib3MFResult CCall_lib3mf_slicestack_setownpath(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, const char * pPath) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_SetOwnPath (pSliceStack, pPath); +} + + +Lib3MFResult CCall_lib3mf_slicestack_getownpath(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char * pPathBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SliceStack_GetOwnPath (pSliceStack, nPathBufferSize, pPathNeededChars, pPathBuffer); +} + + +Lib3MFResult CCall_lib3mf_consumer_getconsumerid(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, const Lib3MF_uint32 nConsumerIDBufferSize, Lib3MF_uint32* pConsumerIDNeededChars, char * pConsumerIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Consumer_GetConsumerID (pConsumer, nConsumerIDBufferSize, pConsumerIDNeededChars, pConsumerIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_consumer_getkeyid(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, const Lib3MF_uint32 nKeyIDBufferSize, Lib3MF_uint32* pKeyIDNeededChars, char * pKeyIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Consumer_GetKeyID (pConsumer, nKeyIDBufferSize, pKeyIDNeededChars, pKeyIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_consumer_getkeyvalue(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, const Lib3MF_uint32 nKeyValueBufferSize, Lib3MF_uint32* pKeyValueNeededChars, char * pKeyValueBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Consumer_GetKeyValue (pConsumer, nKeyValueBufferSize, pKeyValueNeededChars, pKeyValueBuffer); +} + + +Lib3MFResult CCall_lib3mf_accessright_getconsumer(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, Lib3MF_Consumer * pConsumer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_AccessRight_GetConsumer (pAccessRight, pConsumer); +} + + +Lib3MFResult CCall_lib3mf_accessright_getwrappingalgorithm(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFWrappingAlgorithm * pAlgorithm) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_AccessRight_GetWrappingAlgorithm (pAccessRight, pAlgorithm); +} + + +Lib3MFResult CCall_lib3mf_accessright_getmgfalgorithm(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFMgfAlgorithm * pAlgorithm) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_AccessRight_GetMgfAlgorithm (pAccessRight, pAlgorithm); +} + + +Lib3MFResult CCall_lib3mf_accessright_getdigestmethod(Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFDigestMethod * pAlgorithm) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_AccessRight_GetDigestMethod (pAccessRight, pAlgorithm); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getencryptionalgorithm(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, eLib3MFEncryptionAlgorithm * pAlgorithm) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_GetEncryptionAlgorithm (pContentEncryptionParams, pAlgorithm); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getkey(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_GetKey (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getinitializationvector(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_GetInitializationVector (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getauthenticationtag(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_GetAuthenticationTag (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_setauthenticationtag(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, Lib3MF_uint64 nByteDataBufferSize, const Lib3MF_uint8 * pByteDataBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_SetAuthenticationTag (pContentEncryptionParams, nByteDataBufferSize, pByteDataBuffer); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getadditionalauthenticationdata(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_GetAdditionalAuthenticationData (pContentEncryptionParams, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getdescriptor(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, Lib3MF_uint64 * pDescriptor) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_GetDescriptor (pContentEncryptionParams, pDescriptor); +} + + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getkeyuuid(Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ContentEncryptionParams_GetKeyUUID (pContentEncryptionParams, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_resourcedata_getpath(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, Lib3MF_PackagePart * pPath) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceData_GetPath (pResourceData, pPath); +} + + +Lib3MFResult CCall_lib3mf_resourcedata_getencryptionalgorithm(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, eLib3MFEncryptionAlgorithm * pEncryptionAlgorithm) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceData_GetEncryptionAlgorithm (pResourceData, pEncryptionAlgorithm); +} + + +Lib3MFResult CCall_lib3mf_resourcedata_getcompression(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, eLib3MFCompression * pCompression) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceData_GetCompression (pResourceData, pCompression); +} + + +Lib3MFResult CCall_lib3mf_resourcedata_getadditionalauthenticationdata(Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8 * pByteDataBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceData_GetAdditionalAuthenticationData (pResourceData, nByteDataBufferSize, pByteDataNeededCount, pByteDataBuffer); +} + + +Lib3MFResult CCall_lib3mf_resourcedatagroup_getkeyuuid(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceDataGroup_GetKeyUUID (pResourceDataGroup, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_resourcedatagroup_addaccessright(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer, eLib3MFWrappingAlgorithm eWrappingAlgorithm, eLib3MFMgfAlgorithm eMgfAlgorithm, eLib3MFDigestMethod eDigestMethod, Lib3MF_AccessRight * pTheAccessRight) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceDataGroup_AddAccessRight (pResourceDataGroup, pConsumer, eWrappingAlgorithm, eMgfAlgorithm, eDigestMethod, pTheAccessRight); +} + + +Lib3MFResult CCall_lib3mf_resourcedatagroup_findaccessrightbyconsumer(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer, Lib3MF_AccessRight * pTheAccessRight) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceDataGroup_FindAccessRightByConsumer (pResourceDataGroup, pConsumer, pTheAccessRight); +} + + +Lib3MFResult CCall_lib3mf_resourcedatagroup_removeaccessright(Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ResourceDataGroup_RemoveAccessRight (pResourceDataGroup, pConsumer); +} + + +Lib3MFResult CCall_lib3mf_keystore_addconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char * pConsumerID, const char * pKeyID, const char * pKeyValue, Lib3MF_Consumer * pConsumer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_AddConsumer (pKeyStore, pConsumerID, pKeyID, pKeyValue, pConsumer); +} + + +Lib3MFResult CCall_lib3mf_keystore_getconsumercount(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_GetConsumerCount (pKeyStore, pCount); +} + + +Lib3MFResult CCall_lib3mf_keystore_getconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 nConsumerIndex, Lib3MF_Consumer * pConsumer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_GetConsumer (pKeyStore, nConsumerIndex, pConsumer); +} + + +Lib3MFResult CCall_lib3mf_keystore_removeconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_Consumer pConsumer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_RemoveConsumer (pKeyStore, pConsumer); +} + + +Lib3MFResult CCall_lib3mf_keystore_findconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char * pConsumerID, Lib3MF_Consumer * pConsumer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_FindConsumer (pKeyStore, pConsumerID, pConsumer); +} + + +Lib3MFResult CCall_lib3mf_keystore_getresourcedatagroupcount(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_GetResourceDataGroupCount (pKeyStore, pCount); +} + + +Lib3MFResult CCall_lib3mf_keystore_addresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup * pResourceDataGroup) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_AddResourceDataGroup (pKeyStore, pResourceDataGroup); +} + + +Lib3MFResult CCall_lib3mf_keystore_getresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 nResourceDataIndex, Lib3MF_ResourceDataGroup * pResourceDataGroup) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_GetResourceDataGroup (pKeyStore, nResourceDataIndex, pResourceDataGroup); +} + + +Lib3MFResult CCall_lib3mf_keystore_removeresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup pResourceDataGroup) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_RemoveResourceDataGroup (pKeyStore, pResourceDataGroup); +} + + +Lib3MFResult CCall_lib3mf_keystore_findresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_PackagePart pPartPath, Lib3MF_ResourceDataGroup * pResourceDataGroup) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_FindResourceDataGroup (pKeyStore, pPartPath, pResourceDataGroup); +} + + +Lib3MFResult CCall_lib3mf_keystore_addresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_PackagePart pPartPath, eLib3MFEncryptionAlgorithm eAlgorithm, eLib3MFCompression eCompression, Lib3MF_uint64 nAdditionalAuthenticationDataBufferSize, const Lib3MF_uint8 * pAdditionalAuthenticationDataBuffer, Lib3MF_ResourceData * pResourceData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_AddResourceData (pKeyStore, pResourceDataGroup, pPartPath, eAlgorithm, eCompression, nAdditionalAuthenticationDataBufferSize, pAdditionalAuthenticationDataBuffer, pResourceData); +} + + +Lib3MFResult CCall_lib3mf_keystore_removeresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceData pResourceData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_RemoveResourceData (pKeyStore, pResourceData); +} + + +Lib3MFResult CCall_lib3mf_keystore_findresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_PackagePart pResourcePath, Lib3MF_ResourceData * pResourceData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_FindResourceData (pKeyStore, pResourcePath, pResourceData); +} + + +Lib3MFResult CCall_lib3mf_keystore_getresourcedatacount(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 * pCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_GetResourceDataCount (pKeyStore, pCount); +} + + +Lib3MFResult CCall_lib3mf_keystore_getresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 nResourceDataIndex, Lib3MF_ResourceData * pResourceData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_GetResourceData (pKeyStore, nResourceDataIndex, pResourceData); +} + + +Lib3MFResult CCall_lib3mf_keystore_getuuid(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_GetUUID (pKeyStore, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_keystore_setuuid(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char * pUUID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_KeyStore_SetUUID (pKeyStore, pUUID); +} + + +Lib3MFResult CCall_lib3mf_model_rootmodelpart(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_PackagePart * pRootModelPart) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_RootModelPart (pModel, pRootModelPart); +} + + +Lib3MFResult CCall_lib3mf_model_findorcreatepackagepart(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pAbsolutePath, Lib3MF_PackagePart * pModelPart) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_FindOrCreatePackagePart (pModel, pAbsolutePath, pModelPart); +} + + +Lib3MFResult CCall_lib3mf_model_setunit(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, eLib3MFModelUnit eUnit) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_SetUnit (pModel, eUnit); +} + + +Lib3MFResult CCall_lib3mf_model_getunit(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, eLib3MFModelUnit * pUnit) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetUnit (pModel, pUnit); +} + + +Lib3MFResult CCall_lib3mf_model_getlanguage(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const Lib3MF_uint32 nLanguageBufferSize, Lib3MF_uint32* pLanguageNeededChars, char * pLanguageBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetLanguage (pModel, nLanguageBufferSize, pLanguageNeededChars, pLanguageBuffer); +} + + +Lib3MFResult CCall_lib3mf_model_setlanguage(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pLanguage) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_SetLanguage (pModel, pLanguage); +} + + +Lib3MFResult CCall_lib3mf_model_querywriter(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pWriterClass, Lib3MF_Writer * pWriterInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_QueryWriter (pModel, pWriterClass, pWriterInstance); +} + + +Lib3MFResult CCall_lib3mf_model_queryreader(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pReaderClass, Lib3MF_Reader * pReaderInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_QueryReader (pModel, pReaderClass, pReaderInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getresourcebyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_Resource * pResource) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetResourceByID (pModel, nUniqueResourceID, pResource); +} + + +Lib3MFResult CCall_lib3mf_model_gettexture2dbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_Texture2D * pTextureInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetTexture2DByID (pModel, nUniqueResourceID, pTextureInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getpropertytypebyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, eLib3MFPropertyType * pThePropertyType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetPropertyTypeByID (pModel, nUniqueResourceID, pThePropertyType); +} + + +Lib3MFResult CCall_lib3mf_model_getbasematerialgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_BaseMaterialGroup * pBaseMaterialGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetBaseMaterialGroupByID (pModel, nUniqueResourceID, pBaseMaterialGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_gettexture2dgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_Texture2DGroup * pTexture2DGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetTexture2DGroupByID (pModel, nUniqueResourceID, pTexture2DGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getcompositematerialsbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_CompositeMaterials * pCompositeMaterialsInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetCompositeMaterialsByID (pModel, nUniqueResourceID, pCompositeMaterialsInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getmultipropertygroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_MultiPropertyGroup * pMultiPropertyGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetMultiPropertyGroupByID (pModel, nUniqueResourceID, pMultiPropertyGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getmeshobjectbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_MeshObject * pMeshObjectInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetMeshObjectByID (pModel, nUniqueResourceID, pMeshObjectInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getcomponentsobjectbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_ComponentsObject * pComponentsObjectInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetComponentsObjectByID (pModel, nUniqueResourceID, pComponentsObjectInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getcolorgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_ColorGroup * pColorGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetColorGroupByID (pModel, nUniqueResourceID, pColorGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getslicestackbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_SliceStack * pSliceStacInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetSliceStackByID (pModel, nUniqueResourceID, pSliceStacInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getbuilduuid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, bool * pHasUUID, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char * pUUIDBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetBuildUUID (pModel, pHasUUID, nUUIDBufferSize, pUUIDNeededChars, pUUIDBuffer); +} + + +Lib3MFResult CCall_lib3mf_model_setbuilduuid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pUUID) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_SetBuildUUID (pModel, pUUID); +} + + +Lib3MFResult CCall_lib3mf_model_getbuilditems(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BuildItemIterator * pBuildItemIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetBuildItems (pModel, pBuildItemIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, sLib3MFBox * pOutbox) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetOutbox (pModel, pOutbox); +} + + +Lib3MFResult CCall_lib3mf_model_getresources(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ResourceIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetResources (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getobjects(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ObjectIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetObjects (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getmeshobjects(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MeshObjectIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetMeshObjects (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getcomponentsobjects(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ComponentsObjectIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetComponentsObjects (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_gettexture2ds(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2DIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetTexture2Ds (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getbasematerialgroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroupIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetBaseMaterialGroups (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getcolorgroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ColorGroupIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetColorGroups (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_gettexture2dgroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2DGroupIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetTexture2DGroups (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getcompositematerials(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_CompositeMaterialsIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetCompositeMaterials (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getmultipropertygroups(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MultiPropertyGroupIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetMultiPropertyGroups (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_getslicestacks(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_SliceStackIterator * pResourceIterator) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetSliceStacks (pModel, pResourceIterator); +} + + +Lib3MFResult CCall_lib3mf_model_mergetomodel(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Model * pMergedModelInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_MergeToModel (pModel, pMergedModelInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addmeshobject(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MeshObject * pMeshObjectInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddMeshObject (pModel, pMeshObjectInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addcomponentsobject(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ComponentsObject * pComponentsObjectInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddComponentsObject (pModel, pComponentsObjectInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addslicestack(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_double dZBottom, Lib3MF_SliceStack * pSliceStackInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddSliceStack (pModel, dZBottom, pSliceStackInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addtexture2dfromattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment pTextureAttachment, Lib3MF_Texture2D * pTexture2DInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddTexture2DFromAttachment (pModel, pTextureAttachment, pTexture2DInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addbasematerialgroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroup * pBaseMaterialGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddBaseMaterialGroup (pModel, pBaseMaterialGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addcolorgroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ColorGroup * pColorGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddColorGroup (pModel, pColorGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addtexture2dgroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2D pTexture2DInstance, Lib3MF_Texture2DGroup * pTexture2DGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddTexture2DGroup (pModel, pTexture2DInstance, pTexture2DGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addcompositematerials(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroup pBaseMaterialGroupInstance, Lib3MF_CompositeMaterials * pCompositeMaterialsInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddCompositeMaterials (pModel, pBaseMaterialGroupInstance, pCompositeMaterialsInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addmultipropertygroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MultiPropertyGroup * pMultiPropertyGroupInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddMultiPropertyGroup (pModel, pMultiPropertyGroupInstance); +} + + +Lib3MFResult CCall_lib3mf_model_addbuilditem(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Object pObject, const sLib3MFTransform * pTransform, Lib3MF_BuildItem * pBuildItemInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddBuildItem (pModel, pObject, pTransform, pBuildItemInstance); +} + + +Lib3MFResult CCall_lib3mf_model_removebuilditem(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BuildItem pBuildItemInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_RemoveBuildItem (pModel, pBuildItemInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getmetadatagroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MetaDataGroup * pTheMetaDataGroup) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetMetaDataGroup (pModel, pTheMetaDataGroup); +} + + +Lib3MFResult CCall_lib3mf_model_addattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pURI, const char * pRelationShipType, Lib3MF_Attachment * pAttachmentInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddAttachment (pModel, pURI, pRelationShipType, pAttachmentInstance); +} + + +Lib3MFResult CCall_lib3mf_model_removeattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment pAttachmentInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_RemoveAttachment (pModel, pAttachmentInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nIndex, Lib3MF_Attachment * pAttachmentInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetAttachment (pModel, nIndex, pAttachmentInstance); +} + + +Lib3MFResult CCall_lib3mf_model_findattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pURI, Lib3MF_Attachment * pAttachmentInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_FindAttachment (pModel, pURI, pAttachmentInstance); +} + + +Lib3MFResult CCall_lib3mf_model_getattachmentcount(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 * pAttachmentCount) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetAttachmentCount (pModel, pAttachmentCount); +} + + +Lib3MFResult CCall_lib3mf_model_haspackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, bool * pHasThumbnail) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_HasPackageThumbnailAttachment (pModel, pHasThumbnail); +} + + +Lib3MFResult CCall_lib3mf_model_createpackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment * pAttachment) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_CreatePackageThumbnailAttachment (pModel, pAttachment); +} + + +Lib3MFResult CCall_lib3mf_model_getpackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment * pAttachment) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetPackageThumbnailAttachment (pModel, pAttachment); +} + + +Lib3MFResult CCall_lib3mf_model_removepackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_RemovePackageThumbnailAttachment (pModel); +} + + +Lib3MFResult CCall_lib3mf_model_addcustomcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pExtension, const char * pContentType) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_AddCustomContentType (pModel, pExtension, pContentType); +} + + +Lib3MFResult CCall_lib3mf_model_removecustomcontenttype(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char * pExtension) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_RemoveCustomContentType (pModel, pExtension); +} + + +Lib3MFResult CCall_lib3mf_model_setrandomnumbercallback(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MFRandomNumberCallback pTheCallback, Lib3MF_pvoid pUserData) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_SetRandomNumberCallback (pModel, pTheCallback, pUserData); +} + + +Lib3MFResult CCall_lib3mf_model_getkeystore(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_KeyStore * pKeyStore) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Model_GetKeyStore (pModel, pKeyStore); +} + + +Lib3MFResult CCall_lib3mf_getlibraryversion(Lib3MFHandle libraryHandle, Lib3MF_uint32 * pMajor, Lib3MF_uint32 * pMinor, Lib3MF_uint32 * pMicro) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetLibraryVersion (pMajor, pMinor, pMicro); +} + + +Lib3MFResult CCall_lib3mf_getprereleaseinformation(Lib3MFHandle libraryHandle, bool * pHasPrereleaseInfo, const Lib3MF_uint32 nPrereleaseInfoBufferSize, Lib3MF_uint32* pPrereleaseInfoNeededChars, char * pPrereleaseInfoBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetPrereleaseInformation (pHasPrereleaseInfo, nPrereleaseInfoBufferSize, pPrereleaseInfoNeededChars, pPrereleaseInfoBuffer); +} + + +Lib3MFResult CCall_lib3mf_getbuildinformation(Lib3MFHandle libraryHandle, bool * pHasBuildInfo, const Lib3MF_uint32 nBuildInformationBufferSize, Lib3MF_uint32* pBuildInformationNeededChars, char * pBuildInformationBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetBuildInformation (pHasBuildInfo, nBuildInformationBufferSize, pBuildInformationNeededChars, pBuildInformationBuffer); +} + + +Lib3MFResult CCall_lib3mf_getspecificationversion(Lib3MFHandle libraryHandle, const char * pSpecificationURL, bool * pIsSupported, Lib3MF_uint32 * pMajor, Lib3MF_uint32 * pMinor, Lib3MF_uint32 * pMicro) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetSpecificationVersion (pSpecificationURL, pIsSupported, pMajor, pMinor, pMicro); +} + + +Lib3MFResult CCall_lib3mf_createmodel(Lib3MFHandle libraryHandle, Lib3MF_Model * pModel) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_CreateModel (pModel); +} + + +Lib3MFResult CCall_lib3mf_release(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Release (pInstance); +} + + +Lib3MFResult CCall_lib3mf_acquire(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_Acquire (pInstance); +} + + +Lib3MFResult CCall_lib3mf_setjournal(Lib3MFHandle libraryHandle, const char * pJournalPath) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_SetJournal (pJournalPath); +} + + +Lib3MFResult CCall_lib3mf_getlasterror(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance, const Lib3MF_uint32 nLastErrorStringBufferSize, Lib3MF_uint32* pLastErrorStringNeededChars, char * pLastErrorStringBuffer, bool * pHasLastError) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetLastError (pInstance, nLastErrorStringBufferSize, pLastErrorStringNeededChars, pLastErrorStringBuffer, pHasLastError); +} + + +Lib3MFResult CCall_lib3mf_getsymbollookupmethod(Lib3MFHandle libraryHandle, Lib3MF_pvoid * pSymbolLookupMethod) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetSymbolLookupMethod (pSymbolLookupMethod); +} + + +Lib3MFResult CCall_lib3mf_retrieveprogressmessage(Lib3MFHandle libraryHandle, eLib3MFProgressIdentifier eTheProgressIdentifier, const Lib3MF_uint32 nProgressMessageBufferSize, Lib3MF_uint32* pProgressMessageNeededChars, char * pProgressMessageBuffer) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_RetrieveProgressMessage (eTheProgressIdentifier, nProgressMessageBufferSize, pProgressMessageNeededChars, pProgressMessageBuffer); +} + + +Lib3MFResult CCall_lib3mf_rgbatocolor(Lib3MFHandle libraryHandle, Lib3MF_uint8 nRed, Lib3MF_uint8 nGreen, Lib3MF_uint8 nBlue, Lib3MF_uint8 nAlpha, sLib3MFColor * pTheColor) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_RGBAToColor (nRed, nGreen, nBlue, nAlpha, pTheColor); +} + + +Lib3MFResult CCall_lib3mf_floatrgbatocolor(Lib3MFHandle libraryHandle, Lib3MF_single fRed, Lib3MF_single fGreen, Lib3MF_single fBlue, Lib3MF_single fAlpha, sLib3MFColor * pTheColor) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_FloatRGBAToColor (fRed, fGreen, fBlue, fAlpha, pTheColor); +} + + +Lib3MFResult CCall_lib3mf_colortorgba(Lib3MFHandle libraryHandle, const sLib3MFColor * pTheColor, Lib3MF_uint8 * pRed, Lib3MF_uint8 * pGreen, Lib3MF_uint8 * pBlue, Lib3MF_uint8 * pAlpha) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorToRGBA (pTheColor, pRed, pGreen, pBlue, pAlpha); +} + + +Lib3MFResult CCall_lib3mf_colortofloatrgba(Lib3MFHandle libraryHandle, const sLib3MFColor * pTheColor, Lib3MF_single * pRed, Lib3MF_single * pGreen, Lib3MF_single * pBlue, Lib3MF_single * pAlpha) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_ColorToFloatRGBA (pTheColor, pRed, pGreen, pBlue, pAlpha); +} + + +Lib3MFResult CCall_lib3mf_getidentitytransform(Lib3MFHandle libraryHandle, sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetIdentityTransform (pTransform); +} + + +Lib3MFResult CCall_lib3mf_getuniformscaletransform(Lib3MFHandle libraryHandle, Lib3MF_single fFactor, sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetUniformScaleTransform (fFactor, pTransform); +} + + +Lib3MFResult CCall_lib3mf_getscaletransform(Lib3MFHandle libraryHandle, Lib3MF_single fFactorX, Lib3MF_single fFactorY, Lib3MF_single fFactorZ, sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetScaleTransform (fFactorX, fFactorY, fFactorZ, pTransform); +} + + +Lib3MFResult CCall_lib3mf_gettranslationtransform(Lib3MFHandle libraryHandle, Lib3MF_single fVectorX, Lib3MF_single fVectorY, Lib3MF_single fVectorZ, sLib3MFTransform * pTransform) +{ + if (libraryHandle == 0) + return LIB3MF_ERROR_INVALIDCAST; + sLib3MFDynamicWrapperTable * wrapperTable = (sLib3MFDynamicWrapperTable *) libraryHandle; + return wrapperTable->m_GetTranslationTransform (fVectorX, fVectorY, fVectorZ, pTransform); +} diff --git a/Autogenerated/Bindings/Go/lib3mf_dynamic.h b/Autogenerated/Bindings/Go/lib3mf_dynamic.h index c92306d14..4ed106bab 100644 --- a/Autogenerated/Bindings/Go/lib3mf_dynamic.h +++ b/Autogenerated/Bindings/Go/lib3mf_dynamic.h @@ -4087,5 +4087,1088 @@ Lib3MFResult InitLib3MFWrapperTable(sLib3MFDynamicWrapperTable * pWrapperTable); Lib3MFResult ReleaseLib3MFWrapperTable(sLib3MFDynamicWrapperTable * pWrapperTable); Lib3MFResult LoadLib3MFWrapperTable(sLib3MFDynamicWrapperTable * pWrapperTable, const char * pLibraryFileName); +Lib3MFHandle loadLib3MFLibrary(const char* pFileName); + +void unloadLib3MFLibrary(Lib3MFHandle nLibraryHandle); + +Lib3MFResult CCall_lib3mf_base_classtypeid(Lib3MFHandle libraryHandle, Lib3MF_Base pBase, Lib3MF_uint64* pClassTypeId); + +Lib3MFResult CCall_lib3mf_writer_writetofile(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, const char* pFilename); + +Lib3MFResult CCall_lib3mf_writer_getstreamsize( + Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint64* pStreamSize); + +Lib3MFResult CCall_lib3mf_writer_writetobuffer(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, + const Lib3MF_uint64 nBufferBufferSize, Lib3MF_uint64* pBufferNeededCount, Lib3MF_uint8* pBufferBuffer); + +Lib3MFResult CCall_lib3mf_writer_writetocallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, + Lib3MFWriteCallback pTheWriteCallback, Lib3MFSeekCallback pTheSeekCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_writer_setprogresscallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, + Lib3MFProgressCallback pProgressCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_writer_getdecimalprecision( + Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32* pDecimalPrecision); + +Lib3MFResult CCall_lib3mf_writer_setdecimalprecision( + Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 nDecimalPrecision); + +Lib3MFResult CCall_lib3mf_writer_setstrictmodeactive( + Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, bool bStrictModeActive); + +Lib3MFResult CCall_lib3mf_writer_getstrictmodeactive( + Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, bool* pStrictModeActive); + +Lib3MFResult CCall_lib3mf_writer_getwarning(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32 nIndex, + Lib3MF_uint32* pErrorCode, const Lib3MF_uint32 nWarningBufferSize, Lib3MF_uint32* pWarningNeededChars, + char* pWarningBuffer); + +Lib3MFResult CCall_lib3mf_writer_getwarningcount( + Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_writer_addkeywrappingcallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, + const char* pConsumerID, Lib3MFKeyWrappingCallback pTheCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_writer_setcontentencryptioncallback(Lib3MFHandle libraryHandle, Lib3MF_Writer pWriter, + Lib3MFContentEncryptionCallback pTheCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_reader_readfromfile(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char* pFilename); + +Lib3MFResult CCall_lib3mf_reader_readfrombuffer(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, + Lib3MF_uint64 nBufferBufferSize, const Lib3MF_uint8* pBufferBuffer); + +Lib3MFResult CCall_lib3mf_reader_readfromcallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, + Lib3MFReadCallback pTheReadCallback, Lib3MF_uint64 nStreamSize, Lib3MFSeekCallback pTheSeekCallback, + Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_reader_setprogresscallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, + Lib3MFProgressCallback pProgressCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_reader_addrelationtoread( + Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char* pRelationShipType); + +Lib3MFResult CCall_lib3mf_reader_removerelationtoread( + Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, const char* pRelationShipType); + +Lib3MFResult CCall_lib3mf_reader_setstrictmodeactive( + Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, bool bStrictModeActive); + +Lib3MFResult CCall_lib3mf_reader_getstrictmodeactive( + Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, bool* pStrictModeActive); + +Lib3MFResult CCall_lib3mf_reader_getwarning(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint32 nIndex, + Lib3MF_uint32* pErrorCode, const Lib3MF_uint32 nWarningBufferSize, Lib3MF_uint32* pWarningNeededChars, + char* pWarningBuffer); + +Lib3MFResult CCall_lib3mf_reader_getwarningcount( + Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_reader_addkeywrappingcallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, + const char* pConsumerID, Lib3MFKeyWrappingCallback pTheCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_reader_setcontentencryptioncallback(Lib3MFHandle libraryHandle, Lib3MF_Reader pReader, + Lib3MFContentEncryptionCallback pTheCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_packagepart_getpath(Lib3MFHandle libraryHandle, Lib3MF_PackagePart pPackagePart, + const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char* pPathBuffer); + +Lib3MFResult CCall_lib3mf_packagepart_setpath( + Lib3MFHandle libraryHandle, Lib3MF_PackagePart pPackagePart, const char* pPath); + +Lib3MFResult CCall_lib3mf_resource_getresourceid( + Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32* pUniqueResourceID); + +Lib3MFResult CCall_lib3mf_resource_getuniqueresourceid( + Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32* pUniqueResourceID); + +Lib3MFResult CCall_lib3mf_resource_packagepart( + Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_PackagePart* pPackagePart); + +Lib3MFResult CCall_lib3mf_resource_setpackagepart( + Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_PackagePart pPackagePart); + +Lib3MFResult CCall_lib3mf_resource_getmodelresourceid( + Lib3MFHandle libraryHandle, Lib3MF_Resource pResource, Lib3MF_uint32* pModelResourceId); + +Lib3MFResult CCall_lib3mf_resourceiterator_movenext( + Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, bool* pHasNext); + +Lib3MFResult CCall_lib3mf_resourceiterator_moveprevious( + Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, bool* pHasPrevious); + +Lib3MFResult CCall_lib3mf_resourceiterator_getcurrent( + Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_Resource* pResource); + +Lib3MFResult CCall_lib3mf_resourceiterator_clone(Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, + Lib3MF_ResourceIterator* pOutResourceIterator); + +Lib3MFResult CCall_lib3mf_resourceiterator_count( + Lib3MFHandle libraryHandle, Lib3MF_ResourceIterator pResourceIterator, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_slicestackiterator_getcurrentslicestack( + Lib3MFHandle libraryHandle, Lib3MF_SliceStackIterator pSliceStackIterator, Lib3MF_SliceStack* pResource); + +Lib3MFResult CCall_lib3mf_objectiterator_getcurrentobject( + Lib3MFHandle libraryHandle, Lib3MF_ObjectIterator pObjectIterator, Lib3MF_Object* pResource); + +Lib3MFResult CCall_lib3mf_meshobjectiterator_getcurrentmeshobject( + Lib3MFHandle libraryHandle, Lib3MF_MeshObjectIterator pMeshObjectIterator, Lib3MF_MeshObject* pResource); + +Lib3MFResult CCall_lib3mf_componentsobjectiterator_getcurrentcomponentsobject(Lib3MFHandle libraryHandle, + Lib3MF_ComponentsObjectIterator pComponentsObjectIterator, Lib3MF_ComponentsObject* pResource); + +Lib3MFResult CCall_lib3mf_texture2diterator_getcurrenttexture2d( + Lib3MFHandle libraryHandle, Lib3MF_Texture2DIterator pTexture2DIterator, Lib3MF_Texture2D* pResource); + +Lib3MFResult CCall_lib3mf_basematerialgroupiterator_getcurrentbasematerialgroup(Lib3MFHandle libraryHandle, + Lib3MF_BaseMaterialGroupIterator pBaseMaterialGroupIterator, Lib3MF_BaseMaterialGroup* pResource); + +Lib3MFResult CCall_lib3mf_colorgroupiterator_getcurrentcolorgroup( + Lib3MFHandle libraryHandle, Lib3MF_ColorGroupIterator pColorGroupIterator, Lib3MF_ColorGroup* pResource); + +Lib3MFResult CCall_lib3mf_texture2dgroupiterator_getcurrenttexture2dgroup(Lib3MFHandle libraryHandle, + Lib3MF_Texture2DGroupIterator pTexture2DGroupIterator, Lib3MF_Texture2DGroup* pResource); + +Lib3MFResult CCall_lib3mf_compositematerialsiterator_getcurrentcompositematerials(Lib3MFHandle libraryHandle, + Lib3MF_CompositeMaterialsIterator pCompositeMaterialsIterator, Lib3MF_CompositeMaterials* pResource); + +Lib3MFResult CCall_lib3mf_multipropertygroupiterator_getcurrentmultipropertygroup(Lib3MFHandle libraryHandle, + Lib3MF_MultiPropertyGroupIterator pMultiPropertyGroupIterator, Lib3MF_MultiPropertyGroup* pResource); + +Lib3MFResult CCall_lib3mf_metadata_getnamespace(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, + const Lib3MF_uint32 nNameSpaceBufferSize, Lib3MF_uint32* pNameSpaceNeededChars, char* pNameSpaceBuffer); + +Lib3MFResult CCall_lib3mf_metadata_setnamespace( + Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char* pNameSpace); + +Lib3MFResult CCall_lib3mf_metadata_getname(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, + const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char* pNameBuffer); + +Lib3MFResult CCall_lib3mf_metadata_setname(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char* pName); + +Lib3MFResult CCall_lib3mf_metadata_getkey(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, + const Lib3MF_uint32 nKeyBufferSize, Lib3MF_uint32* pKeyNeededChars, char* pKeyBuffer); + +Lib3MFResult CCall_lib3mf_metadata_getmustpreserve( + Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, bool* pMustPreserve); + +Lib3MFResult CCall_lib3mf_metadata_setmustpreserve( + Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, bool bMustPreserve); + +Lib3MFResult CCall_lib3mf_metadata_gettype(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, + const Lib3MF_uint32 nTypeBufferSize, Lib3MF_uint32* pTypeNeededChars, char* pTypeBuffer); + +Lib3MFResult CCall_lib3mf_metadata_settype(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char* pType); + +Lib3MFResult CCall_lib3mf_metadata_getvalue(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, + const Lib3MF_uint32 nValueBufferSize, Lib3MF_uint32* pValueNeededChars, char* pValueBuffer); + +Lib3MFResult CCall_lib3mf_metadata_setvalue(Lib3MFHandle libraryHandle, Lib3MF_MetaData pMetaData, const char* pValue); + +Lib3MFResult CCall_lib3mf_metadatagroup_getmetadatacount( + Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_metadatagroup_getmetadata( + Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 nIndex, Lib3MF_MetaData* pMetaData); + +Lib3MFResult CCall_lib3mf_metadatagroup_getmetadatabykey(Lib3MFHandle libraryHandle, + Lib3MF_MetaDataGroup pMetaDataGroup, const char* pNameSpace, const char* pName, Lib3MF_MetaData* pMetaData); + +Lib3MFResult CCall_lib3mf_metadatagroup_removemetadatabyindex( + Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_uint32 nIndex); + +Lib3MFResult CCall_lib3mf_metadatagroup_removemetadata( + Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, Lib3MF_MetaData pTheMetaData); + +Lib3MFResult CCall_lib3mf_metadatagroup_addmetadata(Lib3MFHandle libraryHandle, Lib3MF_MetaDataGroup pMetaDataGroup, + const char* pNameSpace, const char* pName, const char* pValue, const char* pType, bool bMustPreserve, + Lib3MF_MetaData* pMetaData); + +Lib3MFResult CCall_lib3mf_object_gettype( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFObjectType* pObjectType); + +Lib3MFResult CCall_lib3mf_object_settype( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFObjectType eObjectType); + +Lib3MFResult CCall_lib3mf_object_getname(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, + const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char* pNameBuffer); + +Lib3MFResult CCall_lib3mf_object_setname(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char* pName); + +Lib3MFResult CCall_lib3mf_object_getpartnumber(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, + const Lib3MF_uint32 nPartNumberBufferSize, Lib3MF_uint32* pPartNumberNeededChars, char* pPartNumberBuffer); + +Lib3MFResult CCall_lib3mf_object_setpartnumber( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char* pPartNumber); + +Lib3MFResult CCall_lib3mf_object_ismeshobject(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool* pIsMeshObject); + +Lib3MFResult CCall_lib3mf_object_iscomponentsobject( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool* pIsComponentsObject); + +Lib3MFResult CCall_lib3mf_object_isvalid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool* pIsValid); + +Lib3MFResult CCall_lib3mf_object_setattachmentasthumbnail( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_Attachment pAttachment); + +Lib3MFResult CCall_lib3mf_object_getthumbnailattachment( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_Attachment* pAttachment); + +Lib3MFResult CCall_lib3mf_object_clearthumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Object pObject); + +Lib3MFResult CCall_lib3mf_object_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, sLib3MFBox* pOutbox); + +Lib3MFResult CCall_lib3mf_object_getuuid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool* pHasUUID, + const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char* pUUIDBuffer); + +Lib3MFResult CCall_lib3mf_object_setuuid(Lib3MFHandle libraryHandle, Lib3MF_Object pObject, const char* pUUID); + +Lib3MFResult CCall_lib3mf_object_getmetadatagroup( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_MetaDataGroup* pMetaDataGroup); + +Lib3MFResult CCall_lib3mf_object_setslicesmeshresolution( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFSlicesMeshResolution eMeshResolution); + +Lib3MFResult CCall_lib3mf_object_getslicesmeshresolution( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, eLib3MFSlicesMeshResolution* pMeshResolution); + +Lib3MFResult CCall_lib3mf_object_hasslices( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, bool bRecursive, bool* pHasSlices); + +Lib3MFResult CCall_lib3mf_object_clearslicestack(Lib3MFHandle libraryHandle, Lib3MF_Object pObject); + +Lib3MFResult CCall_lib3mf_object_getslicestack( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_SliceStack* pSliceStackInstance); + +Lib3MFResult CCall_lib3mf_object_assignslicestack( + Lib3MFHandle libraryHandle, Lib3MF_Object pObject, Lib3MF_SliceStack pSliceStackInstance); + +Lib3MFResult CCall_lib3mf_meshobject_getvertexcount( + Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32* pVertexCount); + +Lib3MFResult CCall_lib3mf_meshobject_gettrianglecount( + Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32* pVertexCount); + +Lib3MFResult CCall_lib3mf_meshobject_getvertex( + Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFPosition* pCoordinates); + +Lib3MFResult CCall_lib3mf_meshobject_setvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + Lib3MF_uint32 nIndex, const sLib3MFPosition* pCoordinates); + +Lib3MFResult CCall_lib3mf_meshobject_addvertex(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + const sLib3MFPosition* pCoordinates, Lib3MF_uint32* pNewIndex); + +Lib3MFResult CCall_lib3mf_meshobject_getvertices(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + const Lib3MF_uint64 nVerticesBufferSize, Lib3MF_uint64* pVerticesNeededCount, sLib3MFPosition* pVerticesBuffer); + +Lib3MFResult CCall_lib3mf_meshobject_gettriangle( + Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, sLib3MFTriangle* pIndices); + +Lib3MFResult CCall_lib3mf_meshobject_settriangle( + Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_uint32 nIndex, const sLib3MFTriangle* pIndices); + +Lib3MFResult CCall_lib3mf_meshobject_addtriangle(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + const sLib3MFTriangle* pIndices, Lib3MF_uint32* pNewIndex); + +Lib3MFResult CCall_lib3mf_meshobject_gettriangleindices(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + const Lib3MF_uint64 nIndicesBufferSize, Lib3MF_uint64* pIndicesNeededCount, sLib3MFTriangle* pIndicesBuffer); + +Lib3MFResult CCall_lib3mf_meshobject_setobjectlevelproperty(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_uint32 nPropertyID); + +Lib3MFResult CCall_lib3mf_meshobject_getobjectlevelproperty(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + Lib3MF_uint32* pUniqueResourceID, Lib3MF_uint32* pPropertyID, bool* pHasObjectLevelProperty); + +Lib3MFResult CCall_lib3mf_meshobject_settriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + Lib3MF_uint32 nIndex, const sLib3MFTriangleProperties* pProperties); + +Lib3MFResult CCall_lib3mf_meshobject_gettriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + Lib3MF_uint32 nIndex, sLib3MFTriangleProperties* pProperty); + +Lib3MFResult CCall_lib3mf_meshobject_setalltriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + Lib3MF_uint64 nPropertiesArrayBufferSize, const sLib3MFTriangleProperties* pPropertiesArrayBuffer); + +Lib3MFResult CCall_lib3mf_meshobject_getalltriangleproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + const Lib3MF_uint64 nPropertiesArrayBufferSize, Lib3MF_uint64* pPropertiesArrayNeededCount, + sLib3MFTriangleProperties* pPropertiesArrayBuffer); + +Lib3MFResult CCall_lib3mf_meshobject_clearallproperties(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject); + +Lib3MFResult CCall_lib3mf_meshobject_setgeometry(Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, + Lib3MF_uint64 nVerticesBufferSize, const sLib3MFPosition* pVerticesBuffer, Lib3MF_uint64 nIndicesBufferSize, + const sLib3MFTriangle* pIndicesBuffer); + +Lib3MFResult CCall_lib3mf_meshobject_ismanifoldandoriented( + Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, bool* pIsManifoldAndOriented); + +Lib3MFResult CCall_lib3mf_meshobject_beamlattice( + Lib3MFHandle libraryHandle, Lib3MF_MeshObject pMeshObject, Lib3MF_BeamLattice* pTheBeamLattice); + +Lib3MFResult CCall_lib3mf_beamlattice_getminlength( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_double* pMinLength); + +Lib3MFResult CCall_lib3mf_beamlattice_setminlength( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_double dMinLength); + +Lib3MFResult CCall_lib3mf_beamlattice_getclipping(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + eLib3MFBeamLatticeClipMode* pClipMode, Lib3MF_uint32* pUniqueResourceID); + +Lib3MFResult CCall_lib3mf_beamlattice_setclipping(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + eLib3MFBeamLatticeClipMode eClipMode, Lib3MF_uint32 nUniqueResourceID); + +Lib3MFResult CCall_lib3mf_beamlattice_getrepresentation(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + bool* pHasRepresentation, Lib3MF_uint32* pUniqueResourceID); + +Lib3MFResult CCall_lib3mf_beamlattice_setrepresentation( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nUniqueResourceID); + +Lib3MFResult CCall_lib3mf_beamlattice_getballoptions(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + eLib3MFBeamLatticeBallMode* pBallMode, Lib3MF_double* pBallRadius); + +Lib3MFResult CCall_lib3mf_beamlattice_setballoptions(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + eLib3MFBeamLatticeBallMode eBallMode, Lib3MF_double dBallRadius); + +Lib3MFResult CCall_lib3mf_beamlattice_getbeamcount( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_beamlattice_getbeam( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, sLib3MFBeam* pBeamInfo); + +Lib3MFResult CCall_lib3mf_beamlattice_addbeam( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const sLib3MFBeam* pBeamInfo, Lib3MF_uint32* pIndex); + +Lib3MFResult CCall_lib3mf_beamlattice_setbeam( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, const sLib3MFBeam* pBeamInfo); + +Lib3MFResult CCall_lib3mf_beamlattice_setbeams(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + Lib3MF_uint64 nBeamInfoBufferSize, const sLib3MFBeam* pBeamInfoBuffer); + +Lib3MFResult CCall_lib3mf_beamlattice_getbeams(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + const Lib3MF_uint64 nBeamInfoBufferSize, Lib3MF_uint64* pBeamInfoNeededCount, sLib3MFBeam* pBeamInfoBuffer); + +Lib3MFResult CCall_lib3mf_beamlattice_getballcount( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_beamlattice_getball( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, sLib3MFBall* pBallInfo); + +Lib3MFResult CCall_lib3mf_beamlattice_addball( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, const sLib3MFBall* pBallInfo, Lib3MF_uint32* pIndex); + +Lib3MFResult CCall_lib3mf_beamlattice_setball( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, const sLib3MFBall* pBallInfo); + +Lib3MFResult CCall_lib3mf_beamlattice_setballs(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + Lib3MF_uint64 nBallInfoBufferSize, const sLib3MFBall* pBallInfoBuffer); + +Lib3MFResult CCall_lib3mf_beamlattice_getballs(Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, + const Lib3MF_uint64 nBallInfoBufferSize, Lib3MF_uint64* pBallInfoNeededCount, sLib3MFBall* pBallInfoBuffer); + +Lib3MFResult CCall_lib3mf_beamlattice_getbeamsetcount( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_beamlattice_addbeamset( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_BeamSet* pBeamSet); + +Lib3MFResult CCall_lib3mf_beamlattice_getbeamset( + Lib3MFHandle libraryHandle, Lib3MF_BeamLattice pBeamLattice, Lib3MF_uint32 nIndex, Lib3MF_BeamSet* pBeamSet); + +Lib3MFResult CCall_lib3mf_component_getobjectresource( + Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, Lib3MF_Object* pObjectResource); + +Lib3MFResult CCall_lib3mf_component_getobjectresourceid( + Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, Lib3MF_uint32* pUniqueResourceID); + +Lib3MFResult CCall_lib3mf_component_getuuid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, bool* pHasUUID, + const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char* pUUIDBuffer); + +Lib3MFResult CCall_lib3mf_component_setuuid(Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, const char* pUUID); + +Lib3MFResult CCall_lib3mf_component_hastransform( + Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, bool* pHasTransform); + +Lib3MFResult CCall_lib3mf_component_gettransform( + Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, sLib3MFTransform* pTransform); + +Lib3MFResult CCall_lib3mf_component_settransform( + Lib3MFHandle libraryHandle, Lib3MF_Component pComponent, const sLib3MFTransform* pTransform); + +Lib3MFResult CCall_lib3mf_componentsobject_addcomponent(Lib3MFHandle libraryHandle, + Lib3MF_ComponentsObject pComponentsObject, Lib3MF_Object pObjectResource, const sLib3MFTransform* pTransform, + Lib3MF_Component* pComponentInstance); + +Lib3MFResult CCall_lib3mf_componentsobject_getcomponent(Lib3MFHandle libraryHandle, + Lib3MF_ComponentsObject pComponentsObject, Lib3MF_uint32 nIndex, Lib3MF_Component* pComponentInstance); + +Lib3MFResult CCall_lib3mf_componentsobject_getcomponentcount( + Lib3MFHandle libraryHandle, Lib3MF_ComponentsObject pComponentsObject, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_beamset_setname(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const char* pName); + +Lib3MFResult CCall_lib3mf_beamset_getname(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, + const Lib3MF_uint32 nNameBufferSize, Lib3MF_uint32* pNameNeededChars, char* pNameBuffer); + +Lib3MFResult CCall_lib3mf_beamset_setidentifier( + Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, const char* pIdentifier); + +Lib3MFResult CCall_lib3mf_beamset_getidentifier(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, + const Lib3MF_uint32 nIdentifierBufferSize, Lib3MF_uint32* pIdentifierNeededChars, char* pIdentifierBuffer); + +Lib3MFResult CCall_lib3mf_beamset_getreferencecount( + Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_beamset_setreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, + Lib3MF_uint64 nReferencesBufferSize, const Lib3MF_uint32* pReferencesBuffer); + +Lib3MFResult CCall_lib3mf_beamset_getreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, + const Lib3MF_uint64 nReferencesBufferSize, Lib3MF_uint64* pReferencesNeededCount, Lib3MF_uint32* pReferencesBuffer); + +Lib3MFResult CCall_lib3mf_beamset_getballreferencecount( + Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_beamset_setballreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, + Lib3MF_uint64 nBallReferencesBufferSize, const Lib3MF_uint32* pBallReferencesBuffer); + +Lib3MFResult CCall_lib3mf_beamset_getballreferences(Lib3MFHandle libraryHandle, Lib3MF_BeamSet pBeamSet, + const Lib3MF_uint64 nBallReferencesBufferSize, Lib3MF_uint64* pBallReferencesNeededCount, + Lib3MF_uint32* pBallReferencesBuffer); + +Lib3MFResult CCall_lib3mf_basematerialgroup_getcount( + Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_basematerialgroup_getallpropertyids(Lib3MFHandle libraryHandle, + Lib3MF_BaseMaterialGroup pBaseMaterialGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, + Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32* pPropertyIDsBuffer); + +Lib3MFResult CCall_lib3mf_basematerialgroup_addmaterial(Lib3MFHandle libraryHandle, + Lib3MF_BaseMaterialGroup pBaseMaterialGroup, const char* pName, const sLib3MFColor* pDisplayColor, + Lib3MF_uint32* pPropertyID); + +Lib3MFResult CCall_lib3mf_basematerialgroup_removematerial( + Lib3MFHandle libraryHandle, Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID); + +Lib3MFResult CCall_lib3mf_basematerialgroup_getname(Lib3MFHandle libraryHandle, + Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const Lib3MF_uint32 nNameBufferSize, + Lib3MF_uint32* pNameNeededChars, char* pNameBuffer); + +Lib3MFResult CCall_lib3mf_basematerialgroup_setname(Lib3MFHandle libraryHandle, + Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const char* pName); + +Lib3MFResult CCall_lib3mf_basematerialgroup_setdisplaycolor(Lib3MFHandle libraryHandle, + Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, const sLib3MFColor* pTheColor); + +Lib3MFResult CCall_lib3mf_basematerialgroup_getdisplaycolor(Lib3MFHandle libraryHandle, + Lib3MF_BaseMaterialGroup pBaseMaterialGroup, Lib3MF_uint32 nPropertyID, sLib3MFColor* pTheColor); + +Lib3MFResult CCall_lib3mf_colorgroup_getcount( + Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_colorgroup_getallpropertyids(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, + const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, + Lib3MF_uint32* pPropertyIDsBuffer); + +Lib3MFResult CCall_lib3mf_colorgroup_addcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, + const sLib3MFColor* pTheColor, Lib3MF_uint32* pPropertyID); + +Lib3MFResult CCall_lib3mf_colorgroup_removecolor( + Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID); + +Lib3MFResult CCall_lib3mf_colorgroup_setcolor(Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, + Lib3MF_uint32 nPropertyID, const sLib3MFColor* pTheColor); + +Lib3MFResult CCall_lib3mf_colorgroup_getcolor( + Lib3MFHandle libraryHandle, Lib3MF_ColorGroup pColorGroup, Lib3MF_uint32 nPropertyID, sLib3MFColor* pTheColor); + +Lib3MFResult CCall_lib3mf_texture2dgroup_getcount( + Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_texture2dgroup_getallpropertyids(Lib3MFHandle libraryHandle, + Lib3MF_Texture2DGroup pTexture2DGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, + Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32* pPropertyIDsBuffer); + +Lib3MFResult CCall_lib3mf_texture2dgroup_addtex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, + const sLib3MFTex2Coord* pUVCoordinate, Lib3MF_uint32* pPropertyID); + +Lib3MFResult CCall_lib3mf_texture2dgroup_gettex2coord(Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, + Lib3MF_uint32 nPropertyID, sLib3MFTex2Coord* pUVCoordinate); + +Lib3MFResult CCall_lib3mf_texture2dgroup_removetex2coord( + Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_uint32 nPropertyID); + +Lib3MFResult CCall_lib3mf_texture2dgroup_gettexture2d( + Lib3MFHandle libraryHandle, Lib3MF_Texture2DGroup pTexture2DGroup, Lib3MF_Texture2D* pTexture2DInstance); + +Lib3MFResult CCall_lib3mf_compositematerials_getcount( + Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_compositematerials_getallpropertyids(Lib3MFHandle libraryHandle, + Lib3MF_CompositeMaterials pCompositeMaterials, const Lib3MF_uint64 nPropertyIDsBufferSize, + Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32* pPropertyIDsBuffer); + +Lib3MFResult CCall_lib3mf_compositematerials_getbasematerialgroup(Lib3MFHandle libraryHandle, + Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_BaseMaterialGroup* pBaseMaterialGroupInstance); + +Lib3MFResult CCall_lib3mf_compositematerials_addcomposite(Lib3MFHandle libraryHandle, + Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint64 nCompositeBufferSize, + const sLib3MFCompositeConstituent* pCompositeBuffer, Lib3MF_uint32* pPropertyID); + +Lib3MFResult CCall_lib3mf_compositematerials_removecomposite( + Lib3MFHandle libraryHandle, Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 nPropertyID); + +Lib3MFResult CCall_lib3mf_compositematerials_getcomposite(Lib3MFHandle libraryHandle, + Lib3MF_CompositeMaterials pCompositeMaterials, Lib3MF_uint32 nPropertyID, const Lib3MF_uint64 nCompositeBufferSize, + Lib3MF_uint64* pCompositeNeededCount, sLib3MFCompositeConstituent* pCompositeBuffer); + +Lib3MFResult CCall_lib3mf_multipropertygroup_getcount( + Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_multipropertygroup_getallpropertyids(Lib3MFHandle libraryHandle, + Lib3MF_MultiPropertyGroup pMultiPropertyGroup, const Lib3MF_uint64 nPropertyIDsBufferSize, + Lib3MF_uint64* pPropertyIDsNeededCount, Lib3MF_uint32* pPropertyIDsBuffer); + +Lib3MFResult CCall_lib3mf_multipropertygroup_addmultiproperty(Lib3MFHandle libraryHandle, + Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint64 nPropertyIDsBufferSize, + const Lib3MF_uint32* pPropertyIDsBuffer, Lib3MF_uint32* pPropertyID); + +Lib3MFResult CCall_lib3mf_multipropertygroup_setmultiproperty(Lib3MFHandle libraryHandle, + Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID, Lib3MF_uint64 nPropertyIDsBufferSize, + const Lib3MF_uint32* pPropertyIDsBuffer); + +Lib3MFResult CCall_lib3mf_multipropertygroup_getmultiproperty(Lib3MFHandle libraryHandle, + Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID, + const Lib3MF_uint64 nPropertyIDsBufferSize, Lib3MF_uint64* pPropertyIDsNeededCount, + Lib3MF_uint32* pPropertyIDsBuffer); + +Lib3MFResult CCall_lib3mf_multipropertygroup_removemultiproperty( + Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nPropertyID); + +Lib3MFResult CCall_lib3mf_multipropertygroup_getlayercount( + Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32* pCount); + +Lib3MFResult CCall_lib3mf_multipropertygroup_addlayer(Lib3MFHandle libraryHandle, + Lib3MF_MultiPropertyGroup pMultiPropertyGroup, const sLib3MFMultiPropertyLayer* pTheLayer, + Lib3MF_uint32* pLayerIndex); + +Lib3MFResult CCall_lib3mf_multipropertygroup_getlayer(Lib3MFHandle libraryHandle, + Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nLayerIndex, sLib3MFMultiPropertyLayer* pTheLayer); + +Lib3MFResult CCall_lib3mf_multipropertygroup_removelayer( + Lib3MFHandle libraryHandle, Lib3MF_MultiPropertyGroup pMultiPropertyGroup, Lib3MF_uint32 nLayerIndex); + +Lib3MFResult CCall_lib3mf_attachment_getpath(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, + const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char* pPathBuffer); + +Lib3MFResult CCall_lib3mf_attachment_setpath( + Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char* pPath); + +Lib3MFResult CCall_lib3mf_attachment_packagepart( + Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_PackagePart* pPackagePart); + +Lib3MFResult CCall_lib3mf_attachment_getrelationshiptype(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, + const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char* pPathBuffer); + +Lib3MFResult CCall_lib3mf_attachment_setrelationshiptype( + Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char* pPath); + +Lib3MFResult CCall_lib3mf_attachment_writetofile( + Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char* pFileName); + +Lib3MFResult CCall_lib3mf_attachment_readfromfile( + Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, const char* pFileName); + +Lib3MFResult CCall_lib3mf_attachment_readfromcallback(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, + Lib3MFReadCallback pTheReadCallback, Lib3MF_uint64 nStreamSize, Lib3MFSeekCallback pTheSeekCallback, + Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_attachment_getstreamsize( + Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, Lib3MF_uint64* pStreamSize); + +Lib3MFResult CCall_lib3mf_attachment_writetobuffer(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, + const Lib3MF_uint64 nBufferBufferSize, Lib3MF_uint64* pBufferNeededCount, Lib3MF_uint8* pBufferBuffer); + +Lib3MFResult CCall_lib3mf_attachment_readfrombuffer(Lib3MFHandle libraryHandle, Lib3MF_Attachment pAttachment, + Lib3MF_uint64 nBufferBufferSize, const Lib3MF_uint8* pBufferBuffer); + +Lib3MFResult CCall_lib3mf_texture2d_getattachment( + Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, Lib3MF_Attachment* pAttachment); + +Lib3MFResult CCall_lib3mf_texture2d_setattachment( + Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, Lib3MF_Attachment pAttachment); + +Lib3MFResult CCall_lib3mf_texture2d_getcontenttype( + Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureType* pContentType); + +Lib3MFResult CCall_lib3mf_texture2d_setcontenttype( + Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureType eContentType); + +Lib3MFResult CCall_lib3mf_texture2d_gettilestyleuv(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, + eLib3MFTextureTileStyle* pTileStyleU, eLib3MFTextureTileStyle* pTileStyleV); + +Lib3MFResult CCall_lib3mf_texture2d_settilestyleuv(Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, + eLib3MFTextureTileStyle eTileStyleU, eLib3MFTextureTileStyle eTileStyleV); + +Lib3MFResult CCall_lib3mf_texture2d_getfilter( + Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureFilter* pFilter); + +Lib3MFResult CCall_lib3mf_texture2d_setfilter( + Lib3MFHandle libraryHandle, Lib3MF_Texture2D pTexture2D, eLib3MFTextureFilter eFilter); + +Lib3MFResult CCall_lib3mf_builditem_getobjectresource( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_Object* pObjectResource); + +Lib3MFResult CCall_lib3mf_builditem_getuuid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, bool* pHasUUID, + const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char* pUUIDBuffer); + +Lib3MFResult CCall_lib3mf_builditem_setuuid(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const char* pUUID); + +Lib3MFResult CCall_lib3mf_builditem_getobjectresourceid( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_uint32* pUniqueResourceID); + +Lib3MFResult CCall_lib3mf_builditem_hasobjecttransform( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, bool* pHasTransform); + +Lib3MFResult CCall_lib3mf_builditem_getobjecttransform( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, sLib3MFTransform* pTransform); + +Lib3MFResult CCall_lib3mf_builditem_setobjecttransform( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const sLib3MFTransform* pTransform); + +Lib3MFResult CCall_lib3mf_builditem_getpartnumber(Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, + const Lib3MF_uint32 nPartNumberBufferSize, Lib3MF_uint32* pPartNumberNeededChars, char* pPartNumberBuffer); + +Lib3MFResult CCall_lib3mf_builditem_setpartnumber( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, const char* pSetPartnumber); + +Lib3MFResult CCall_lib3mf_builditem_getmetadatagroup( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, Lib3MF_MetaDataGroup* pMetaDataGroup); + +Lib3MFResult CCall_lib3mf_builditem_getoutbox( + Lib3MFHandle libraryHandle, Lib3MF_BuildItem pBuildItem, sLib3MFBox* pOutbox); + +Lib3MFResult CCall_lib3mf_builditemiterator_movenext( + Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, bool* pHasNext); + +Lib3MFResult CCall_lib3mf_builditemiterator_moveprevious( + Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, bool* pHasPrevious); + +Lib3MFResult CCall_lib3mf_builditemiterator_getcurrent( + Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_BuildItem* pBuildItem); + +Lib3MFResult CCall_lib3mf_builditemiterator_clone(Lib3MFHandle libraryHandle, + Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_BuildItemIterator* pOutBuildItemIterator); + +Lib3MFResult CCall_lib3mf_builditemiterator_count( + Lib3MFHandle libraryHandle, Lib3MF_BuildItemIterator pBuildItemIterator, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_slice_setvertices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, + Lib3MF_uint64 nVerticesBufferSize, const sLib3MFPosition2D* pVerticesBuffer); + +Lib3MFResult CCall_lib3mf_slice_getvertices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, + const Lib3MF_uint64 nVerticesBufferSize, Lib3MF_uint64* pVerticesNeededCount, sLib3MFPosition2D* pVerticesBuffer); + +Lib3MFResult CCall_lib3mf_slice_getvertexcount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_slice_addpolygon(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, + Lib3MF_uint64 nIndicesBufferSize, const Lib3MF_uint32* pIndicesBuffer, Lib3MF_uint64* pIndex); + +Lib3MFResult CCall_lib3mf_slice_getpolygoncount(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_slice_setpolygonindices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, + Lib3MF_uint64 nIndicesBufferSize, const Lib3MF_uint32* pIndicesBuffer); + +Lib3MFResult CCall_lib3mf_slice_getpolygonindices(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, + const Lib3MF_uint64 nIndicesBufferSize, Lib3MF_uint64* pIndicesNeededCount, Lib3MF_uint32* pIndicesBuffer); + +Lib3MFResult CCall_lib3mf_slice_getpolygonindexcount( + Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_uint64 nIndex, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_slice_getztop(Lib3MFHandle libraryHandle, Lib3MF_Slice pSlice, Lib3MF_double* pZTop); + +Lib3MFResult CCall_lib3mf_slicestack_getbottomz( + Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_double* pZBottom); + +Lib3MFResult CCall_lib3mf_slicestack_getslicecount( + Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_slicestack_getslice( + Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64 nSliceIndex, Lib3MF_Slice* pTheSlice); + +Lib3MFResult CCall_lib3mf_slicestack_addslice( + Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_double dZTop, Lib3MF_Slice* pTheSlice); + +Lib3MFResult CCall_lib3mf_slicestack_getslicerefcount( + Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_slicestack_addslicestackreference( + Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, Lib3MF_SliceStack pTheSliceStack); + +Lib3MFResult CCall_lib3mf_slicestack_getslicestackreference(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, + Lib3MF_uint64 nSliceRefIndex, Lib3MF_SliceStack* pTheSliceStack); + +Lib3MFResult CCall_lib3mf_slicestack_collapseslicereferences(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack); + +Lib3MFResult CCall_lib3mf_slicestack_setownpath( + Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, const char* pPath); + +Lib3MFResult CCall_lib3mf_slicestack_getownpath(Lib3MFHandle libraryHandle, Lib3MF_SliceStack pSliceStack, + const Lib3MF_uint32 nPathBufferSize, Lib3MF_uint32* pPathNeededChars, char* pPathBuffer); + +Lib3MFResult CCall_lib3mf_consumer_getconsumerid(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, + const Lib3MF_uint32 nConsumerIDBufferSize, Lib3MF_uint32* pConsumerIDNeededChars, char* pConsumerIDBuffer); + +Lib3MFResult CCall_lib3mf_consumer_getkeyid(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, + const Lib3MF_uint32 nKeyIDBufferSize, Lib3MF_uint32* pKeyIDNeededChars, char* pKeyIDBuffer); + +Lib3MFResult CCall_lib3mf_consumer_getkeyvalue(Lib3MFHandle libraryHandle, Lib3MF_Consumer pConsumer, + const Lib3MF_uint32 nKeyValueBufferSize, Lib3MF_uint32* pKeyValueNeededChars, char* pKeyValueBuffer); + +Lib3MFResult CCall_lib3mf_accessright_getconsumer( + Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, Lib3MF_Consumer* pConsumer); + +Lib3MFResult CCall_lib3mf_accessright_getwrappingalgorithm( + Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFWrappingAlgorithm* pAlgorithm); + +Lib3MFResult CCall_lib3mf_accessright_getmgfalgorithm( + Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFMgfAlgorithm* pAlgorithm); + +Lib3MFResult CCall_lib3mf_accessright_getdigestmethod( + Lib3MFHandle libraryHandle, Lib3MF_AccessRight pAccessRight, eLib3MFDigestMethod* pAlgorithm); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getencryptionalgorithm(Lib3MFHandle libraryHandle, + Lib3MF_ContentEncryptionParams pContentEncryptionParams, eLib3MFEncryptionAlgorithm* pAlgorithm); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getkey(Lib3MFHandle libraryHandle, + Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, + Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8* pByteDataBuffer); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getinitializationvector(Lib3MFHandle libraryHandle, + Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, + Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8* pByteDataBuffer); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getauthenticationtag(Lib3MFHandle libraryHandle, + Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, + Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8* pByteDataBuffer); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_setauthenticationtag(Lib3MFHandle libraryHandle, + Lib3MF_ContentEncryptionParams pContentEncryptionParams, Lib3MF_uint64 nByteDataBufferSize, + const Lib3MF_uint8* pByteDataBuffer); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getadditionalauthenticationdata(Lib3MFHandle libraryHandle, + Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint64 nByteDataBufferSize, + Lib3MF_uint64* pByteDataNeededCount, Lib3MF_uint8* pByteDataBuffer); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getdescriptor( + Lib3MFHandle libraryHandle, Lib3MF_ContentEncryptionParams pContentEncryptionParams, Lib3MF_uint64* pDescriptor); + +Lib3MFResult CCall_lib3mf_contentencryptionparams_getkeyuuid(Lib3MFHandle libraryHandle, + Lib3MF_ContentEncryptionParams pContentEncryptionParams, const Lib3MF_uint32 nUUIDBufferSize, + Lib3MF_uint32* pUUIDNeededChars, char* pUUIDBuffer); + +Lib3MFResult CCall_lib3mf_resourcedata_getpath( + Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, Lib3MF_PackagePart* pPath); + +Lib3MFResult CCall_lib3mf_resourcedata_getencryptionalgorithm( + Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, eLib3MFEncryptionAlgorithm* pEncryptionAlgorithm); + +Lib3MFResult CCall_lib3mf_resourcedata_getcompression( + Lib3MFHandle libraryHandle, Lib3MF_ResourceData pResourceData, eLib3MFCompression* pCompression); + +Lib3MFResult CCall_lib3mf_resourcedata_getadditionalauthenticationdata(Lib3MFHandle libraryHandle, + Lib3MF_ResourceData pResourceData, const Lib3MF_uint64 nByteDataBufferSize, Lib3MF_uint64* pByteDataNeededCount, + Lib3MF_uint8* pByteDataBuffer); + +Lib3MFResult CCall_lib3mf_resourcedatagroup_getkeyuuid(Lib3MFHandle libraryHandle, + Lib3MF_ResourceDataGroup pResourceDataGroup, const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, + char* pUUIDBuffer); + +Lib3MFResult CCall_lib3mf_resourcedatagroup_addaccessright(Lib3MFHandle libraryHandle, + Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer, eLib3MFWrappingAlgorithm eWrappingAlgorithm, + eLib3MFMgfAlgorithm eMgfAlgorithm, eLib3MFDigestMethod eDigestMethod, Lib3MF_AccessRight* pTheAccessRight); + +Lib3MFResult CCall_lib3mf_resourcedatagroup_findaccessrightbyconsumer(Lib3MFHandle libraryHandle, + Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer, Lib3MF_AccessRight* pTheAccessRight); + +Lib3MFResult CCall_lib3mf_resourcedatagroup_removeaccessright( + Lib3MFHandle libraryHandle, Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_Consumer pConsumer); + +Lib3MFResult CCall_lib3mf_keystore_addconsumer(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, + const char* pConsumerID, const char* pKeyID, const char* pKeyValue, Lib3MF_Consumer* pConsumer); + +Lib3MFResult CCall_lib3mf_keystore_getconsumercount( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_keystore_getconsumer( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64 nConsumerIndex, Lib3MF_Consumer* pConsumer); + +Lib3MFResult CCall_lib3mf_keystore_removeconsumer( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_Consumer pConsumer); + +Lib3MFResult CCall_lib3mf_keystore_findconsumer( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char* pConsumerID, Lib3MF_Consumer* pConsumer); + +Lib3MFResult CCall_lib3mf_keystore_getresourcedatagroupcount( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_keystore_addresourcedatagroup( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup* pResourceDataGroup); + +Lib3MFResult CCall_lib3mf_keystore_getresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, + Lib3MF_uint64 nResourceDataIndex, Lib3MF_ResourceDataGroup* pResourceDataGroup); + +Lib3MFResult CCall_lib3mf_keystore_removeresourcedatagroup( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceDataGroup pResourceDataGroup); + +Lib3MFResult CCall_lib3mf_keystore_findresourcedatagroup(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, + Lib3MF_PackagePart pPartPath, Lib3MF_ResourceDataGroup* pResourceDataGroup); + +Lib3MFResult CCall_lib3mf_keystore_addresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, + Lib3MF_ResourceDataGroup pResourceDataGroup, Lib3MF_PackagePart pPartPath, eLib3MFEncryptionAlgorithm eAlgorithm, + eLib3MFCompression eCompression, Lib3MF_uint64 nAdditionalAuthenticationDataBufferSize, + const Lib3MF_uint8* pAdditionalAuthenticationDataBuffer, Lib3MF_ResourceData* pResourceData); + +Lib3MFResult CCall_lib3mf_keystore_removeresourcedata( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_ResourceData pResourceData); + +Lib3MFResult CCall_lib3mf_keystore_findresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, + Lib3MF_PackagePart pResourcePath, Lib3MF_ResourceData* pResourceData); + +Lib3MFResult CCall_lib3mf_keystore_getresourcedatacount( + Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, Lib3MF_uint64* pCount); + +Lib3MFResult CCall_lib3mf_keystore_getresourcedata(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, + Lib3MF_uint64 nResourceDataIndex, Lib3MF_ResourceData* pResourceData); + +Lib3MFResult CCall_lib3mf_keystore_getuuid(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, bool* pHasUUID, + const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char* pUUIDBuffer); + +Lib3MFResult CCall_lib3mf_keystore_setuuid(Lib3MFHandle libraryHandle, Lib3MF_KeyStore pKeyStore, const char* pUUID); + +Lib3MFResult CCall_lib3mf_model_rootmodelpart( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_PackagePart* pRootModelPart); + +Lib3MFResult CCall_lib3mf_model_findorcreatepackagepart( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pAbsolutePath, Lib3MF_PackagePart* pModelPart); + +Lib3MFResult CCall_lib3mf_model_setunit(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, eLib3MFModelUnit eUnit); + +Lib3MFResult CCall_lib3mf_model_getunit(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, eLib3MFModelUnit* pUnit); + +Lib3MFResult CCall_lib3mf_model_getlanguage(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + const Lib3MF_uint32 nLanguageBufferSize, Lib3MF_uint32* pLanguageNeededChars, char* pLanguageBuffer); + +Lib3MFResult CCall_lib3mf_model_setlanguage(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pLanguage); + +Lib3MFResult CCall_lib3mf_model_querywriter( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pWriterClass, Lib3MF_Writer* pWriterInstance); + +Lib3MFResult CCall_lib3mf_model_queryreader( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pReaderClass, Lib3MF_Reader* pReaderInstance); + +Lib3MFResult CCall_lib3mf_model_getresourcebyid( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nUniqueResourceID, Lib3MF_Resource* pResource); + +Lib3MFResult CCall_lib3mf_model_gettexture2dbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_Texture2D* pTextureInstance); + +Lib3MFResult CCall_lib3mf_model_getpropertytypebyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, eLib3MFPropertyType* pThePropertyType); + +Lib3MFResult CCall_lib3mf_model_getbasematerialgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_BaseMaterialGroup* pBaseMaterialGroupInstance); + +Lib3MFResult CCall_lib3mf_model_gettexture2dgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_Texture2DGroup* pTexture2DGroupInstance); + +Lib3MFResult CCall_lib3mf_model_getcompositematerialsbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_CompositeMaterials* pCompositeMaterialsInstance); + +Lib3MFResult CCall_lib3mf_model_getmultipropertygroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_MultiPropertyGroup* pMultiPropertyGroupInstance); + +Lib3MFResult CCall_lib3mf_model_getmeshobjectbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_MeshObject* pMeshObjectInstance); + +Lib3MFResult CCall_lib3mf_model_getcomponentsobjectbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_ComponentsObject* pComponentsObjectInstance); + +Lib3MFResult CCall_lib3mf_model_getcolorgroupbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_ColorGroup* pColorGroupInstance); + +Lib3MFResult CCall_lib3mf_model_getslicestackbyid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_uint32 nUniqueResourceID, Lib3MF_SliceStack* pSliceStacInstance); + +Lib3MFResult CCall_lib3mf_model_getbuilduuid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, bool* pHasUUID, + const Lib3MF_uint32 nUUIDBufferSize, Lib3MF_uint32* pUUIDNeededChars, char* pUUIDBuffer); + +Lib3MFResult CCall_lib3mf_model_setbuilduuid(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pUUID); + +Lib3MFResult CCall_lib3mf_model_getbuilditems( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BuildItemIterator* pBuildItemIterator); + +Lib3MFResult CCall_lib3mf_model_getoutbox(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, sLib3MFBox* pOutbox); + +Lib3MFResult CCall_lib3mf_model_getresources( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ResourceIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getobjects( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ObjectIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getmeshobjects( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MeshObjectIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getcomponentsobjects( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ComponentsObjectIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_gettexture2ds( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2DIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getbasematerialgroups( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroupIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getcolorgroups( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ColorGroupIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_gettexture2dgroups( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Texture2DGroupIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getcompositematerials( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_CompositeMaterialsIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getmultipropertygroups( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MultiPropertyGroupIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_getslicestacks( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_SliceStackIterator* pResourceIterator); + +Lib3MFResult CCall_lib3mf_model_mergetomodel( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Model* pMergedModelInstance); + +Lib3MFResult CCall_lib3mf_model_addmeshobject( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MeshObject* pMeshObjectInstance); + +Lib3MFResult CCall_lib3mf_model_addcomponentsobject( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ComponentsObject* pComponentsObjectInstance); + +Lib3MFResult CCall_lib3mf_model_addslicestack( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_double dZBottom, Lib3MF_SliceStack* pSliceStackInstance); + +Lib3MFResult CCall_lib3mf_model_addtexture2dfromattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_Attachment pTextureAttachment, Lib3MF_Texture2D* pTexture2DInstance); + +Lib3MFResult CCall_lib3mf_model_addbasematerialgroup( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BaseMaterialGroup* pBaseMaterialGroupInstance); + +Lib3MFResult CCall_lib3mf_model_addcolorgroup( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_ColorGroup* pColorGroupInstance); + +Lib3MFResult CCall_lib3mf_model_addtexture2dgroup(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_Texture2D pTexture2DInstance, Lib3MF_Texture2DGroup* pTexture2DGroupInstance); + +Lib3MFResult CCall_lib3mf_model_addcompositematerials(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, + Lib3MF_BaseMaterialGroup pBaseMaterialGroupInstance, Lib3MF_CompositeMaterials* pCompositeMaterialsInstance); + +Lib3MFResult CCall_lib3mf_model_addmultipropertygroup( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MultiPropertyGroup* pMultiPropertyGroupInstance); + +Lib3MFResult CCall_lib3mf_model_addbuilditem(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Object pObject, + const sLib3MFTransform* pTransform, Lib3MF_BuildItem* pBuildItemInstance); + +Lib3MFResult CCall_lib3mf_model_removebuilditem( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_BuildItem pBuildItemInstance); + +Lib3MFResult CCall_lib3mf_model_getmetadatagroup( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_MetaDataGroup* pTheMetaDataGroup); + +Lib3MFResult CCall_lib3mf_model_addattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pURI, + const char* pRelationShipType, Lib3MF_Attachment* pAttachmentInstance); + +Lib3MFResult CCall_lib3mf_model_removeattachment( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment pAttachmentInstance); + +Lib3MFResult CCall_lib3mf_model_getattachment( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32 nIndex, Lib3MF_Attachment* pAttachmentInstance); + +Lib3MFResult CCall_lib3mf_model_findattachment( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pURI, Lib3MF_Attachment* pAttachmentInstance); + +Lib3MFResult CCall_lib3mf_model_getattachmentcount( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_uint32* pAttachmentCount); + +Lib3MFResult CCall_lib3mf_model_haspackagethumbnailattachment( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, bool* pHasThumbnail); + +Lib3MFResult CCall_lib3mf_model_createpackagethumbnailattachment( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment* pAttachment); + +Lib3MFResult CCall_lib3mf_model_getpackagethumbnailattachment( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_Attachment* pAttachment); + +Lib3MFResult CCall_lib3mf_model_removepackagethumbnailattachment(Lib3MFHandle libraryHandle, Lib3MF_Model pModel); + +Lib3MFResult CCall_lib3mf_model_addcustomcontenttype( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pExtension, const char* pContentType); + +Lib3MFResult CCall_lib3mf_model_removecustomcontenttype( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, const char* pExtension); + +Lib3MFResult CCall_lib3mf_model_setrandomnumbercallback( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MFRandomNumberCallback pTheCallback, Lib3MF_pvoid pUserData); + +Lib3MFResult CCall_lib3mf_model_getkeystore( + Lib3MFHandle libraryHandle, Lib3MF_Model pModel, Lib3MF_KeyStore* pKeyStore); + +Lib3MFResult CCall_lib3mf_getlibraryversion( + Lib3MFHandle libraryHandle, Lib3MF_uint32* pMajor, Lib3MF_uint32* pMinor, Lib3MF_uint32* pMicro); + +Lib3MFResult CCall_lib3mf_getprereleaseinformation(Lib3MFHandle libraryHandle, bool* pHasPrereleaseInfo, + const Lib3MF_uint32 nPrereleaseInfoBufferSize, Lib3MF_uint32* pPrereleaseInfoNeededChars, + char* pPrereleaseInfoBuffer); + +Lib3MFResult CCall_lib3mf_getbuildinformation(Lib3MFHandle libraryHandle, bool* pHasBuildInfo, + const Lib3MF_uint32 nBuildInformationBufferSize, Lib3MF_uint32* pBuildInformationNeededChars, + char* pBuildInformationBuffer); + +Lib3MFResult CCall_lib3mf_getspecificationversion(Lib3MFHandle libraryHandle, const char* pSpecificationURL, + bool* pIsSupported, Lib3MF_uint32* pMajor, Lib3MF_uint32* pMinor, Lib3MF_uint32* pMicro); + +Lib3MFResult CCall_lib3mf_createmodel(Lib3MFHandle libraryHandle, Lib3MF_Model* pModel); + +Lib3MFResult CCall_lib3mf_release(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance); + +Lib3MFResult CCall_lib3mf_acquire(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance); + +Lib3MFResult CCall_lib3mf_setjournal(Lib3MFHandle libraryHandle, const char* pJournalPath); + +Lib3MFResult CCall_lib3mf_getlasterror(Lib3MFHandle libraryHandle, Lib3MF_Base pInstance, + const Lib3MF_uint32 nLastErrorStringBufferSize, Lib3MF_uint32* pLastErrorStringNeededChars, + char* pLastErrorStringBuffer, bool* pHasLastError); + +Lib3MFResult CCall_lib3mf_getsymbollookupmethod(Lib3MFHandle libraryHandle, Lib3MF_pvoid* pSymbolLookupMethod); + +Lib3MFResult CCall_lib3mf_retrieveprogressmessage(Lib3MFHandle libraryHandle, + eLib3MFProgressIdentifier eTheProgressIdentifier, const Lib3MF_uint32 nProgressMessageBufferSize, + Lib3MF_uint32* pProgressMessageNeededChars, char* pProgressMessageBuffer); + +Lib3MFResult CCall_lib3mf_rgbatocolor(Lib3MFHandle libraryHandle, Lib3MF_uint8 nRed, Lib3MF_uint8 nGreen, + Lib3MF_uint8 nBlue, Lib3MF_uint8 nAlpha, sLib3MFColor* pTheColor); + +Lib3MFResult CCall_lib3mf_floatrgbatocolor(Lib3MFHandle libraryHandle, Lib3MF_single fRed, Lib3MF_single fGreen, + Lib3MF_single fBlue, Lib3MF_single fAlpha, sLib3MFColor* pTheColor); + +Lib3MFResult CCall_lib3mf_colortorgba(Lib3MFHandle libraryHandle, const sLib3MFColor* pTheColor, Lib3MF_uint8* pRed, + Lib3MF_uint8* pGreen, Lib3MF_uint8* pBlue, Lib3MF_uint8* pAlpha); + +Lib3MFResult CCall_lib3mf_colortofloatrgba(Lib3MFHandle libraryHandle, const sLib3MFColor* pTheColor, + Lib3MF_single* pRed, Lib3MF_single* pGreen, Lib3MF_single* pBlue, Lib3MF_single* pAlpha); + +Lib3MFResult CCall_lib3mf_getidentitytransform(Lib3MFHandle libraryHandle, sLib3MFTransform * pTransform); + +Lib3MFResult CCall_lib3mf_getuniformscaletransform(Lib3MFHandle libraryHandle, Lib3MF_single fFactor, sLib3MFTransform * pTransform); + +Lib3MFResult CCall_lib3mf_getscaletransform(Lib3MFHandle libraryHandle, Lib3MF_single fFactorX, Lib3MF_single fFactorY, Lib3MF_single fFactorZ, sLib3MFTransform * pTransform); + +Lib3MFResult CCall_lib3mf_gettranslationtransform(Lib3MFHandle libraryHandle, Lib3MF_single fVectorX, Lib3MF_single fVectorY, Lib3MF_single fVectorZ, sLib3MFTransform * pTransform); + + #endif // __LIB3MF_DYNAMICHEADER diff --git a/Autogenerated/Bindings/Go/lib3mf_impl.go b/Autogenerated/Bindings/Go/lib3mf_impl.go deleted file mode 100644 index 8ef411b33..000000000 --- a/Autogenerated/Bindings/Go/lib3mf_impl.go +++ /dev/null @@ -1,9033 +0,0 @@ -/*++ - -Copyright (C) 2019 3MF Consortium (Original Author) - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, -are permitted provided that the following conditions are met: - -1. Redistributions of source code must retain the above copyright notice, this -list of conditions and the following disclaimer. -2. Redistributions in binary form must reproduce the above copyright notice, -this list of conditions and the following disclaimer in the documentation -and/or other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND -ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -This file has been generated by the Automatic Component Toolkit (ACT) version 1.6.0. - -Abstract: This is an autogenerated Go implementation file in order to allow an easy - use of the 3MF Library - -Interface version: 2.3.0 - -*/ - - -package lib3mf - -// #include -import "C" - -import ( - "fmt" - "errors" - "syscall" - "unsafe" -) - -type Lib3MFImplementation struct { - Initialized bool - DLLHandle syscall.Handle - Lib3MF_writer_writetofile uintptr - Lib3MF_writer_getstreamsize uintptr - Lib3MF_writer_writetobuffer uintptr - Lib3MF_writer_writetocallback uintptr - Lib3MF_writer_setprogresscallback uintptr - Lib3MF_writer_getdecimalprecision uintptr - Lib3MF_writer_setdecimalprecision uintptr - Lib3MF_writer_setstrictmodeactive uintptr - Lib3MF_writer_getstrictmodeactive uintptr - Lib3MF_writer_getwarning uintptr - Lib3MF_writer_getwarningcount uintptr - Lib3MF_writer_addkeywrappingcallback uintptr - Lib3MF_writer_setcontentencryptioncallback uintptr - Lib3MF_reader_readfromfile uintptr - Lib3MF_reader_readfrombuffer uintptr - Lib3MF_reader_readfromcallback uintptr - Lib3MF_reader_setprogresscallback uintptr - Lib3MF_reader_addrelationtoread uintptr - Lib3MF_reader_removerelationtoread uintptr - Lib3MF_reader_setstrictmodeactive uintptr - Lib3MF_reader_getstrictmodeactive uintptr - Lib3MF_reader_getwarning uintptr - Lib3MF_reader_getwarningcount uintptr - Lib3MF_reader_addkeywrappingcallback uintptr - Lib3MF_reader_setcontentencryptioncallback uintptr - Lib3MF_packagepart_getpath uintptr - Lib3MF_packagepart_setpath uintptr - Lib3MF_resource_getresourceid uintptr - Lib3MF_resource_getuniqueresourceid uintptr - Lib3MF_resource_packagepart uintptr - Lib3MF_resource_setpackagepart uintptr - Lib3MF_resource_getmodelresourceid uintptr - Lib3MF_resourceiterator_movenext uintptr - Lib3MF_resourceiterator_moveprevious uintptr - Lib3MF_resourceiterator_getcurrent uintptr - Lib3MF_resourceiterator_clone uintptr - Lib3MF_resourceiterator_count uintptr - Lib3MF_slicestackiterator_getcurrentslicestack uintptr - Lib3MF_objectiterator_getcurrentobject uintptr - Lib3MF_meshobjectiterator_getcurrentmeshobject uintptr - Lib3MF_componentsobjectiterator_getcurrentcomponentsobject uintptr - Lib3MF_texture2diterator_getcurrenttexture2d uintptr - Lib3MF_basematerialgroupiterator_getcurrentbasematerialgroup uintptr - Lib3MF_colorgroupiterator_getcurrentcolorgroup uintptr - Lib3MF_texture2dgroupiterator_getcurrenttexture2dgroup uintptr - Lib3MF_compositematerialsiterator_getcurrentcompositematerials uintptr - Lib3MF_multipropertygroupiterator_getcurrentmultipropertygroup uintptr - Lib3MF_metadata_getnamespace uintptr - Lib3MF_metadata_setnamespace uintptr - Lib3MF_metadata_getname uintptr - Lib3MF_metadata_setname uintptr - Lib3MF_metadata_getkey uintptr - Lib3MF_metadata_getmustpreserve uintptr - Lib3MF_metadata_setmustpreserve uintptr - Lib3MF_metadata_gettype uintptr - Lib3MF_metadata_settype uintptr - Lib3MF_metadata_getvalue uintptr - Lib3MF_metadata_setvalue uintptr - Lib3MF_metadatagroup_getmetadatacount uintptr - Lib3MF_metadatagroup_getmetadata uintptr - Lib3MF_metadatagroup_getmetadatabykey uintptr - Lib3MF_metadatagroup_removemetadatabyindex uintptr - Lib3MF_metadatagroup_removemetadata uintptr - Lib3MF_metadatagroup_addmetadata uintptr - Lib3MF_object_gettype uintptr - Lib3MF_object_settype uintptr - Lib3MF_object_getname uintptr - Lib3MF_object_setname uintptr - Lib3MF_object_getpartnumber uintptr - Lib3MF_object_setpartnumber uintptr - Lib3MF_object_ismeshobject uintptr - Lib3MF_object_iscomponentsobject uintptr - Lib3MF_object_isvalid uintptr - Lib3MF_object_setattachmentasthumbnail uintptr - Lib3MF_object_getthumbnailattachment uintptr - Lib3MF_object_clearthumbnailattachment uintptr - Lib3MF_object_getoutbox uintptr - Lib3MF_object_getuuid uintptr - Lib3MF_object_setuuid uintptr - Lib3MF_object_getmetadatagroup uintptr - Lib3MF_object_setslicesmeshresolution uintptr - Lib3MF_object_getslicesmeshresolution uintptr - Lib3MF_object_hasslices uintptr - Lib3MF_object_clearslicestack uintptr - Lib3MF_object_getslicestack uintptr - Lib3MF_object_assignslicestack uintptr - Lib3MF_meshobject_getvertexcount uintptr - Lib3MF_meshobject_gettrianglecount uintptr - Lib3MF_meshobject_getvertex uintptr - Lib3MF_meshobject_setvertex uintptr - Lib3MF_meshobject_addvertex uintptr - Lib3MF_meshobject_getvertices uintptr - Lib3MF_meshobject_gettriangle uintptr - Lib3MF_meshobject_settriangle uintptr - Lib3MF_meshobject_addtriangle uintptr - Lib3MF_meshobject_gettriangleindices uintptr - Lib3MF_meshobject_setobjectlevelproperty uintptr - Lib3MF_meshobject_getobjectlevelproperty uintptr - Lib3MF_meshobject_settriangleproperties uintptr - Lib3MF_meshobject_gettriangleproperties uintptr - Lib3MF_meshobject_setalltriangleproperties uintptr - Lib3MF_meshobject_getalltriangleproperties uintptr - Lib3MF_meshobject_clearallproperties uintptr - Lib3MF_meshobject_setgeometry uintptr - Lib3MF_meshobject_ismanifoldandoriented uintptr - Lib3MF_meshobject_beamlattice uintptr - Lib3MF_beamlattice_getminlength uintptr - Lib3MF_beamlattice_setminlength uintptr - Lib3MF_beamlattice_getclipping uintptr - Lib3MF_beamlattice_setclipping uintptr - Lib3MF_beamlattice_getrepresentation uintptr - Lib3MF_beamlattice_setrepresentation uintptr - Lib3MF_beamlattice_getballoptions uintptr - Lib3MF_beamlattice_setballoptions uintptr - Lib3MF_beamlattice_getbeamcount uintptr - Lib3MF_beamlattice_getbeam uintptr - Lib3MF_beamlattice_addbeam uintptr - Lib3MF_beamlattice_setbeam uintptr - Lib3MF_beamlattice_setbeams uintptr - Lib3MF_beamlattice_getbeams uintptr - Lib3MF_beamlattice_getballcount uintptr - Lib3MF_beamlattice_getball uintptr - Lib3MF_beamlattice_addball uintptr - Lib3MF_beamlattice_setball uintptr - Lib3MF_beamlattice_setballs uintptr - Lib3MF_beamlattice_getballs uintptr - Lib3MF_beamlattice_getbeamsetcount uintptr - Lib3MF_beamlattice_addbeamset uintptr - Lib3MF_beamlattice_getbeamset uintptr - Lib3MF_component_getobjectresource uintptr - Lib3MF_component_getobjectresourceid uintptr - Lib3MF_component_getuuid uintptr - Lib3MF_component_setuuid uintptr - Lib3MF_component_hastransform uintptr - Lib3MF_component_gettransform uintptr - Lib3MF_component_settransform uintptr - Lib3MF_componentsobject_addcomponent uintptr - Lib3MF_componentsobject_getcomponent uintptr - Lib3MF_componentsobject_getcomponentcount uintptr - Lib3MF_beamset_setname uintptr - Lib3MF_beamset_getname uintptr - Lib3MF_beamset_setidentifier uintptr - Lib3MF_beamset_getidentifier uintptr - Lib3MF_beamset_getreferencecount uintptr - Lib3MF_beamset_setreferences uintptr - Lib3MF_beamset_getreferences uintptr - Lib3MF_beamset_getballreferencecount uintptr - Lib3MF_beamset_setballreferences uintptr - Lib3MF_beamset_getballreferences uintptr - Lib3MF_basematerialgroup_getcount uintptr - Lib3MF_basematerialgroup_getallpropertyids uintptr - Lib3MF_basematerialgroup_addmaterial uintptr - Lib3MF_basematerialgroup_removematerial uintptr - Lib3MF_basematerialgroup_getname uintptr - Lib3MF_basematerialgroup_setname uintptr - Lib3MF_basematerialgroup_setdisplaycolor uintptr - Lib3MF_basematerialgroup_getdisplaycolor uintptr - Lib3MF_colorgroup_getcount uintptr - Lib3MF_colorgroup_getallpropertyids uintptr - Lib3MF_colorgroup_addcolor uintptr - Lib3MF_colorgroup_removecolor uintptr - Lib3MF_colorgroup_setcolor uintptr - Lib3MF_colorgroup_getcolor uintptr - Lib3MF_texture2dgroup_getcount uintptr - Lib3MF_texture2dgroup_getallpropertyids uintptr - Lib3MF_texture2dgroup_addtex2coord uintptr - Lib3MF_texture2dgroup_gettex2coord uintptr - Lib3MF_texture2dgroup_removetex2coord uintptr - Lib3MF_texture2dgroup_gettexture2d uintptr - Lib3MF_compositematerials_getcount uintptr - Lib3MF_compositematerials_getallpropertyids uintptr - Lib3MF_compositematerials_getbasematerialgroup uintptr - Lib3MF_compositematerials_addcomposite uintptr - Lib3MF_compositematerials_removecomposite uintptr - Lib3MF_compositematerials_getcomposite uintptr - Lib3MF_multipropertygroup_getcount uintptr - Lib3MF_multipropertygroup_getallpropertyids uintptr - Lib3MF_multipropertygroup_addmultiproperty uintptr - Lib3MF_multipropertygroup_setmultiproperty uintptr - Lib3MF_multipropertygroup_getmultiproperty uintptr - Lib3MF_multipropertygroup_removemultiproperty uintptr - Lib3MF_multipropertygroup_getlayercount uintptr - Lib3MF_multipropertygroup_addlayer uintptr - Lib3MF_multipropertygroup_getlayer uintptr - Lib3MF_multipropertygroup_removelayer uintptr - Lib3MF_attachment_getpath uintptr - Lib3MF_attachment_setpath uintptr - Lib3MF_attachment_packagepart uintptr - Lib3MF_attachment_getrelationshiptype uintptr - Lib3MF_attachment_setrelationshiptype uintptr - Lib3MF_attachment_writetofile uintptr - Lib3MF_attachment_readfromfile uintptr - Lib3MF_attachment_readfromcallback uintptr - Lib3MF_attachment_getstreamsize uintptr - Lib3MF_attachment_writetobuffer uintptr - Lib3MF_attachment_readfrombuffer uintptr - Lib3MF_texture2d_getattachment uintptr - Lib3MF_texture2d_setattachment uintptr - Lib3MF_texture2d_getcontenttype uintptr - Lib3MF_texture2d_setcontenttype uintptr - Lib3MF_texture2d_gettilestyleuv uintptr - Lib3MF_texture2d_settilestyleuv uintptr - Lib3MF_texture2d_getfilter uintptr - Lib3MF_texture2d_setfilter uintptr - Lib3MF_builditem_getobjectresource uintptr - Lib3MF_builditem_getuuid uintptr - Lib3MF_builditem_setuuid uintptr - Lib3MF_builditem_getobjectresourceid uintptr - Lib3MF_builditem_hasobjecttransform uintptr - Lib3MF_builditem_getobjecttransform uintptr - Lib3MF_builditem_setobjecttransform uintptr - Lib3MF_builditem_getpartnumber uintptr - Lib3MF_builditem_setpartnumber uintptr - Lib3MF_builditem_getmetadatagroup uintptr - Lib3MF_builditem_getoutbox uintptr - Lib3MF_builditemiterator_movenext uintptr - Lib3MF_builditemiterator_moveprevious uintptr - Lib3MF_builditemiterator_getcurrent uintptr - Lib3MF_builditemiterator_clone uintptr - Lib3MF_builditemiterator_count uintptr - Lib3MF_slice_setvertices uintptr - Lib3MF_slice_getvertices uintptr - Lib3MF_slice_getvertexcount uintptr - Lib3MF_slice_addpolygon uintptr - Lib3MF_slice_getpolygoncount uintptr - Lib3MF_slice_setpolygonindices uintptr - Lib3MF_slice_getpolygonindices uintptr - Lib3MF_slice_getpolygonindexcount uintptr - Lib3MF_slice_getztop uintptr - Lib3MF_slicestack_getbottomz uintptr - Lib3MF_slicestack_getslicecount uintptr - Lib3MF_slicestack_getslice uintptr - Lib3MF_slicestack_addslice uintptr - Lib3MF_slicestack_getslicerefcount uintptr - Lib3MF_slicestack_addslicestackreference uintptr - Lib3MF_slicestack_getslicestackreference uintptr - Lib3MF_slicestack_collapseslicereferences uintptr - Lib3MF_slicestack_setownpath uintptr - Lib3MF_slicestack_getownpath uintptr - Lib3MF_consumer_getconsumerid uintptr - Lib3MF_consumer_getkeyid uintptr - Lib3MF_consumer_getkeyvalue uintptr - Lib3MF_accessright_getconsumer uintptr - Lib3MF_accessright_getwrappingalgorithm uintptr - Lib3MF_accessright_getmgfalgorithm uintptr - Lib3MF_accessright_getdigestmethod uintptr - Lib3MF_contentencryptionparams_getencryptionalgorithm uintptr - Lib3MF_contentencryptionparams_getkey uintptr - Lib3MF_contentencryptionparams_getinitializationvector uintptr - Lib3MF_contentencryptionparams_getauthenticationtag uintptr - Lib3MF_contentencryptionparams_setauthenticationtag uintptr - Lib3MF_contentencryptionparams_getadditionalauthenticationdata uintptr - Lib3MF_contentencryptionparams_getdescriptor uintptr - Lib3MF_contentencryptionparams_getkeyuuid uintptr - Lib3MF_resourcedata_getpath uintptr - Lib3MF_resourcedata_getencryptionalgorithm uintptr - Lib3MF_resourcedata_getcompression uintptr - Lib3MF_resourcedata_getadditionalauthenticationdata uintptr - Lib3MF_resourcedatagroup_getkeyuuid uintptr - Lib3MF_resourcedatagroup_addaccessright uintptr - Lib3MF_resourcedatagroup_findaccessrightbyconsumer uintptr - Lib3MF_resourcedatagroup_removeaccessright uintptr - Lib3MF_keystore_addconsumer uintptr - Lib3MF_keystore_getconsumercount uintptr - Lib3MF_keystore_getconsumer uintptr - Lib3MF_keystore_removeconsumer uintptr - Lib3MF_keystore_findconsumer uintptr - Lib3MF_keystore_getresourcedatagroupcount uintptr - Lib3MF_keystore_addresourcedatagroup uintptr - Lib3MF_keystore_getresourcedatagroup uintptr - Lib3MF_keystore_removeresourcedatagroup uintptr - Lib3MF_keystore_findresourcedatagroup uintptr - Lib3MF_keystore_addresourcedata uintptr - Lib3MF_keystore_removeresourcedata uintptr - Lib3MF_keystore_findresourcedata uintptr - Lib3MF_keystore_getresourcedatacount uintptr - Lib3MF_keystore_getresourcedata uintptr - Lib3MF_keystore_getuuid uintptr - Lib3MF_keystore_setuuid uintptr - Lib3MF_model_rootmodelpart uintptr - Lib3MF_model_findorcreatepackagepart uintptr - Lib3MF_model_setunit uintptr - Lib3MF_model_getunit uintptr - Lib3MF_model_getlanguage uintptr - Lib3MF_model_setlanguage uintptr - Lib3MF_model_querywriter uintptr - Lib3MF_model_queryreader uintptr - Lib3MF_model_gettexture2dbyid uintptr - Lib3MF_model_getpropertytypebyid uintptr - Lib3MF_model_getbasematerialgroupbyid uintptr - Lib3MF_model_gettexture2dgroupbyid uintptr - Lib3MF_model_getcompositematerialsbyid uintptr - Lib3MF_model_getmultipropertygroupbyid uintptr - Lib3MF_model_getmeshobjectbyid uintptr - Lib3MF_model_getcomponentsobjectbyid uintptr - Lib3MF_model_getcolorgroupbyid uintptr - Lib3MF_model_getslicestackbyid uintptr - Lib3MF_model_getbuilduuid uintptr - Lib3MF_model_setbuilduuid uintptr - Lib3MF_model_getbuilditems uintptr - Lib3MF_model_getoutbox uintptr - Lib3MF_model_getresources uintptr - Lib3MF_model_getobjects uintptr - Lib3MF_model_getmeshobjects uintptr - Lib3MF_model_getcomponentsobjects uintptr - Lib3MF_model_gettexture2ds uintptr - Lib3MF_model_getbasematerialgroups uintptr - Lib3MF_model_getcolorgroups uintptr - Lib3MF_model_gettexture2dgroups uintptr - Lib3MF_model_getcompositematerials uintptr - Lib3MF_model_getmultipropertygroups uintptr - Lib3MF_model_getslicestacks uintptr - Lib3MF_model_mergetomodel uintptr - Lib3MF_model_addmeshobject uintptr - Lib3MF_model_addcomponentsobject uintptr - Lib3MF_model_addslicestack uintptr - Lib3MF_model_addtexture2dfromattachment uintptr - Lib3MF_model_addbasematerialgroup uintptr - Lib3MF_model_addcolorgroup uintptr - Lib3MF_model_addtexture2dgroup uintptr - Lib3MF_model_addcompositematerials uintptr - Lib3MF_model_addmultipropertygroup uintptr - Lib3MF_model_addbuilditem uintptr - Lib3MF_model_removebuilditem uintptr - Lib3MF_model_getmetadatagroup uintptr - Lib3MF_model_addattachment uintptr - Lib3MF_model_removeattachment uintptr - Lib3MF_model_getattachment uintptr - Lib3MF_model_findattachment uintptr - Lib3MF_model_getattachmentcount uintptr - Lib3MF_model_haspackagethumbnailattachment uintptr - Lib3MF_model_createpackagethumbnailattachment uintptr - Lib3MF_model_getpackagethumbnailattachment uintptr - Lib3MF_model_removepackagethumbnailattachment uintptr - Lib3MF_model_addcustomcontenttype uintptr - Lib3MF_model_removecustomcontenttype uintptr - Lib3MF_model_setrandomnumbercallback uintptr - Lib3MF_model_getkeystore uintptr - Lib3MF_getlibraryversion uintptr - Lib3MF_getprereleaseinformation uintptr - Lib3MF_getbuildinformation uintptr - Lib3MF_getspecificationversion uintptr - Lib3MF_createmodel uintptr - Lib3MF_release uintptr - Lib3MF_acquire uintptr - Lib3MF_setjournal uintptr - Lib3MF_getlasterror uintptr - Lib3MF_getsymbollookupmethod uintptr - Lib3MF_retrieveprogressmessage uintptr - Lib3MF_rgbatocolor uintptr - Lib3MF_floatrgbatocolor uintptr - Lib3MF_colortorgba uintptr - Lib3MF_colortofloatrgba uintptr - Lib3MF_getidentitytransform uintptr - Lib3MF_getuniformscaletransform uintptr - Lib3MF_getscaletransform uintptr - Lib3MF_gettranslationtransform uintptr -} - -type Lib3MFImplementationHandle interface { - Lib3MFHandle - - GetDLLInHandle() (uintptr) - GetDLLOutHandle() (uintptr) - GetWrapper() (*Lib3MFImplementation) -} - -type Lib3MFImplementationHandleStruct struct { - Implementation * Lib3MFImplementation - DLLhandle uintptr -} - -func (handle *Lib3MFImplementationHandleStruct) Close() (error) { - if (handle.DLLhandle != 0) { - if (handle.Implementation == nil) { - return errors.New("Uninitialized DLL Implementation Handle") - } - - dllhandle := handle.DLLhandle - handle.DLLhandle = 0; - - return handle.Implementation.CallFunction(handle.Implementation.Lib3MF_release, dllhandle) - } - - return nil -} - -func (handle *Lib3MFImplementationHandleStruct) IsValid() (bool) { - return (handle.DLLhandle != 0) -} - -func (handle *Lib3MFImplementationHandleStruct) GetDLLInHandle() (uintptr) { - return handle.DLLhandle; -} - -func (handle *Lib3MFImplementationHandleStruct) GetDLLOutHandle() (uintptr) { - return uintptr(unsafe.Pointer(&handle.DLLhandle)); -} - -func (handle *Lib3MFImplementationHandleStruct) GetWrapper() (*Lib3MFImplementation) { - return handle.Implementation; -} - -func Int8OutValue(reference * int8) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func Int8InValue(value int8) uintptr { - return uintptr(value) -} -func Int16OutValue(reference * int16) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func Int16InValue(value int16) uintptr { - return uintptr(value) -} -func Int32OutValue(reference * int32) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func Int32InValue(value int32) uintptr { - return uintptr(value) -} -func Int64OutValue(reference * int64) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func Int64InValue(value int64) uintptr { - return uintptr(value) -} -func UInt8OutValue(reference * uint8) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func UInt8InValue(value uint8) uintptr { - return uintptr(value) -} -func UInt16OutValue(reference * uint16) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func UInt16InValue(value uint16) uintptr { - return uintptr(value) -} -func UInt32OutValue(reference * uint32) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func UInt32InValue(value uint32) uintptr { - return uintptr(value) -} -func UInt64OutValue(reference * uint64) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func UInt64InValue(value uint64) uintptr { - return uintptr(value) -} -func Float32OutValue(reference * float32) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func Float32InValue(value float32) uintptr { - return uintptr(value) -} -func Float64OutValue(reference * float64) uintptr { - return uintptr(unsafe.Pointer(reference)) -} -func Float64InValue(value float64) uintptr { - return uintptr(value) -} -func StringInValue (value string) uintptr { - bytePtr, err := syscall.BytePtrFromString(value) - if err != nil { - return 0 - } - return uintptr(unsafe.Pointer(bytePtr)) -} - -func PtrOutValue(ptr * uintptr) uintptr { - return uintptr(unsafe.Pointer(ptr)) -} - -func BytesOutValue(bytePtr * []byte) uintptr { - return uintptr(unsafe.Pointer(bytePtr)) -} - - -func GetLib3MFErrorMessage(errorcode uint32) (string) { - switch (errorcode) { - case 1: return "NOTIMPLEMENTED"; - case 2: return "INVALIDPARAM"; - case 3: return "INVALIDCAST"; - case 4: return "BUFFERTOOSMALL"; - case 5: return "GENERICEXCEPTION"; - case 6: return "COULDNOTLOADLIBRARY"; - case 7: return "COULDNOTFINDLIBRARYEXPORT"; - case 8: return "INCOMPATIBLEBINARYVERSION"; - case 10: return "CALCULATIONABORTED"; - case 11: return "SHOULDNOTBECALLED"; - case 100: return "READERCLASSUNKNOWN"; - case 101: return "WRITERCLASSUNKNOWN"; - case 102: return "ITERATORINVALIDINDEX"; - case 103: return "INVALIDMODELRESOURCE"; - case 104: return "RESOURCENOTFOUND"; - case 105: return "INVALIDMODEL"; - case 106: return "INVALIDOBJECT"; - case 107: return "INVALIDMESHOBJECT"; - case 108: return "INVALIDCOMPONENTSOBJECT"; - case 109: return "INVALIDCOMPONENT"; - case 110: return "INVALIDBUILDITEM"; - case 111: return "INVALIDBASEMATERIALGROUP"; - case 112: return "INVALIDSLICESTACKRESOURCE"; - case 113: return "INVALIDTEXTURERESOURCE"; - case 114: return "INVALIDCOLORGROUP"; - case 115: return "INVALIDTEXTURE2DGROUP"; - case 116: return "INVALIDCOMPOSITEMATERIALS"; - case 117: return "INVALIDMULTIPROPERTYGROUP"; - case 120: return "INVALIDRESOURCEINDEX"; - case 121: return "ATTACHMENTNOTFOUND"; - case 130: return "FORBIDDENCYCLICREFERENCE"; - case 131: return "INVALIDATTACHMENTSTREAM"; - case 132: return "INVALIDPROPERTYCOUNT"; - case 140: return "UNKOWNPROGRESSIDENTIFIER"; - case 141: return "ELEMENTCOUNTEXCEEDSLIMIT"; - case 2000: return "BEAMLATTICE_INVALID_OBJECTTYPE"; - case 3000: return "INVALIDKEYSTORE"; - case 3001: return "INVALIDKEYSTORECONSUMER"; - case 3002: return "KEYSTORECONSUMERNOTFOUND"; - case 3003: return "KEYSTORERESOURCEDATANOTFOUND"; - case 3004: return "SECURECONTEXTNOTREGISTERED"; - default: - return "unknown"; - } -} - - -func (implementation *Lib3MFImplementation) GetWrapperHandle(handle Lib3MFHandle) (Lib3MFImplementationHandle, error) { - implementation_handle, ok := handle.(Lib3MFImplementationHandle) - if ok { - handle_implementation := implementation_handle.GetWrapper() - if (handle_implementation == implementation) { - return implementation_handle, nil - } - return nil, errors.New("Invalid Implementation for DLL handle.") - } - return nil, errors.New("Could not cast DLL handle.") -} - -func (implementation *Lib3MFImplementation) Initialize(DLLFileName string) error { - implementation.Initialized = false; - implementation.DLLHandle = 0; - - dllHandle, err := syscall.LoadLibrary(DLLFileName); - if (err != nil) { - return err; - } - - implementation.Lib3MF_writer_writetofile, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_writetofile") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_writetofile: " + err.Error()) - } - - implementation.Lib3MF_writer_getstreamsize, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_getstreamsize") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_getstreamsize: " + err.Error()) - } - - implementation.Lib3MF_writer_writetobuffer, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_writetobuffer") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_writetobuffer: " + err.Error()) - } - - implementation.Lib3MF_writer_writetocallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_writetocallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_writetocallback: " + err.Error()) - } - - implementation.Lib3MF_writer_setprogresscallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_setprogresscallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_setprogresscallback: " + err.Error()) - } - - implementation.Lib3MF_writer_getdecimalprecision, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_getdecimalprecision") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_getdecimalprecision: " + err.Error()) - } - - implementation.Lib3MF_writer_setdecimalprecision, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_setdecimalprecision") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_setdecimalprecision: " + err.Error()) - } - - implementation.Lib3MF_writer_setstrictmodeactive, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_setstrictmodeactive") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_setstrictmodeactive: " + err.Error()) - } - - implementation.Lib3MF_writer_getstrictmodeactive, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_getstrictmodeactive") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_getstrictmodeactive: " + err.Error()) - } - - implementation.Lib3MF_writer_getwarning, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_getwarning") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_getwarning: " + err.Error()) - } - - implementation.Lib3MF_writer_getwarningcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_getwarningcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_getwarningcount: " + err.Error()) - } - - implementation.Lib3MF_writer_addkeywrappingcallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_addkeywrappingcallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_addkeywrappingcallback: " + err.Error()) - } - - implementation.Lib3MF_writer_setcontentencryptioncallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_writer_setcontentencryptioncallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_writer_setcontentencryptioncallback: " + err.Error()) - } - - implementation.Lib3MF_reader_readfromfile, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_readfromfile") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_readfromfile: " + err.Error()) - } - - implementation.Lib3MF_reader_readfrombuffer, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_readfrombuffer") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_readfrombuffer: " + err.Error()) - } - - implementation.Lib3MF_reader_readfromcallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_readfromcallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_readfromcallback: " + err.Error()) - } - - implementation.Lib3MF_reader_setprogresscallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_setprogresscallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_setprogresscallback: " + err.Error()) - } - - implementation.Lib3MF_reader_addrelationtoread, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_addrelationtoread") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_addrelationtoread: " + err.Error()) - } - - implementation.Lib3MF_reader_removerelationtoread, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_removerelationtoread") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_removerelationtoread: " + err.Error()) - } - - implementation.Lib3MF_reader_setstrictmodeactive, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_setstrictmodeactive") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_setstrictmodeactive: " + err.Error()) - } - - implementation.Lib3MF_reader_getstrictmodeactive, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_getstrictmodeactive") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_getstrictmodeactive: " + err.Error()) - } - - implementation.Lib3MF_reader_getwarning, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_getwarning") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_getwarning: " + err.Error()) - } - - implementation.Lib3MF_reader_getwarningcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_getwarningcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_getwarningcount: " + err.Error()) - } - - implementation.Lib3MF_reader_addkeywrappingcallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_addkeywrappingcallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_addkeywrappingcallback: " + err.Error()) - } - - implementation.Lib3MF_reader_setcontentencryptioncallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_reader_setcontentencryptioncallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_reader_setcontentencryptioncallback: " + err.Error()) - } - - implementation.Lib3MF_packagepart_getpath, err = syscall.GetProcAddress(dllHandle, "lib3mf_packagepart_getpath") - if (err != nil) { - return errors.New("Could not get function lib3mf_packagepart_getpath: " + err.Error()) - } - - implementation.Lib3MF_packagepart_setpath, err = syscall.GetProcAddress(dllHandle, "lib3mf_packagepart_setpath") - if (err != nil) { - return errors.New("Could not get function lib3mf_packagepart_setpath: " + err.Error()) - } - - implementation.Lib3MF_resource_getresourceid, err = syscall.GetProcAddress(dllHandle, "lib3mf_resource_getresourceid") - if (err != nil) { - return errors.New("Could not get function lib3mf_resource_getresourceid: " + err.Error()) - } - - implementation.Lib3MF_resource_getuniqueresourceid, err = syscall.GetProcAddress(dllHandle, "lib3mf_resource_getuniqueresourceid") - if (err != nil) { - return errors.New("Could not get function lib3mf_resource_getuniqueresourceid: " + err.Error()) - } - - implementation.Lib3MF_resource_packagepart, err = syscall.GetProcAddress(dllHandle, "lib3mf_resource_packagepart") - if (err != nil) { - return errors.New("Could not get function lib3mf_resource_packagepart: " + err.Error()) - } - - implementation.Lib3MF_resource_setpackagepart, err = syscall.GetProcAddress(dllHandle, "lib3mf_resource_setpackagepart") - if (err != nil) { - return errors.New("Could not get function lib3mf_resource_setpackagepart: " + err.Error()) - } - - implementation.Lib3MF_resource_getmodelresourceid, err = syscall.GetProcAddress(dllHandle, "lib3mf_resource_getmodelresourceid") - if (err != nil) { - return errors.New("Could not get function lib3mf_resource_getmodelresourceid: " + err.Error()) - } - - implementation.Lib3MF_resourceiterator_movenext, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourceiterator_movenext") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourceiterator_movenext: " + err.Error()) - } - - implementation.Lib3MF_resourceiterator_moveprevious, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourceiterator_moveprevious") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourceiterator_moveprevious: " + err.Error()) - } - - implementation.Lib3MF_resourceiterator_getcurrent, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourceiterator_getcurrent") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourceiterator_getcurrent: " + err.Error()) - } - - implementation.Lib3MF_resourceiterator_clone, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourceiterator_clone") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourceiterator_clone: " + err.Error()) - } - - implementation.Lib3MF_resourceiterator_count, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourceiterator_count") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourceiterator_count: " + err.Error()) - } - - implementation.Lib3MF_slicestackiterator_getcurrentslicestack, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestackiterator_getcurrentslicestack") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestackiterator_getcurrentslicestack: " + err.Error()) - } - - implementation.Lib3MF_objectiterator_getcurrentobject, err = syscall.GetProcAddress(dllHandle, "lib3mf_objectiterator_getcurrentobject") - if (err != nil) { - return errors.New("Could not get function lib3mf_objectiterator_getcurrentobject: " + err.Error()) - } - - implementation.Lib3MF_meshobjectiterator_getcurrentmeshobject, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobjectiterator_getcurrentmeshobject") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobjectiterator_getcurrentmeshobject: " + err.Error()) - } - - implementation.Lib3MF_componentsobjectiterator_getcurrentcomponentsobject, err = syscall.GetProcAddress(dllHandle, "lib3mf_componentsobjectiterator_getcurrentcomponentsobject") - if (err != nil) { - return errors.New("Could not get function lib3mf_componentsobjectiterator_getcurrentcomponentsobject: " + err.Error()) - } - - implementation.Lib3MF_texture2diterator_getcurrenttexture2d, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2diterator_getcurrenttexture2d") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2diterator_getcurrenttexture2d: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroupiterator_getcurrentbasematerialgroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroupiterator_getcurrentbasematerialgroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroupiterator_getcurrentbasematerialgroup: " + err.Error()) - } - - implementation.Lib3MF_colorgroupiterator_getcurrentcolorgroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_colorgroupiterator_getcurrentcolorgroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_colorgroupiterator_getcurrentcolorgroup: " + err.Error()) - } - - implementation.Lib3MF_texture2dgroupiterator_getcurrenttexture2dgroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2dgroupiterator_getcurrenttexture2dgroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2dgroupiterator_getcurrenttexture2dgroup: " + err.Error()) - } - - implementation.Lib3MF_compositematerialsiterator_getcurrentcompositematerials, err = syscall.GetProcAddress(dllHandle, "lib3mf_compositematerialsiterator_getcurrentcompositematerials") - if (err != nil) { - return errors.New("Could not get function lib3mf_compositematerialsiterator_getcurrentcompositematerials: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroupiterator_getcurrentmultipropertygroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroupiterator_getcurrentmultipropertygroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroupiterator_getcurrentmultipropertygroup: " + err.Error()) - } - - implementation.Lib3MF_metadata_getnamespace, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_getnamespace") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_getnamespace: " + err.Error()) - } - - implementation.Lib3MF_metadata_setnamespace, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_setnamespace") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_setnamespace: " + err.Error()) - } - - implementation.Lib3MF_metadata_getname, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_getname") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_getname: " + err.Error()) - } - - implementation.Lib3MF_metadata_setname, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_setname") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_setname: " + err.Error()) - } - - implementation.Lib3MF_metadata_getkey, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_getkey") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_getkey: " + err.Error()) - } - - implementation.Lib3MF_metadata_getmustpreserve, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_getmustpreserve") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_getmustpreserve: " + err.Error()) - } - - implementation.Lib3MF_metadata_setmustpreserve, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_setmustpreserve") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_setmustpreserve: " + err.Error()) - } - - implementation.Lib3MF_metadata_gettype, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_gettype") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_gettype: " + err.Error()) - } - - implementation.Lib3MF_metadata_settype, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_settype") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_settype: " + err.Error()) - } - - implementation.Lib3MF_metadata_getvalue, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_getvalue") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_getvalue: " + err.Error()) - } - - implementation.Lib3MF_metadata_setvalue, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadata_setvalue") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadata_setvalue: " + err.Error()) - } - - implementation.Lib3MF_metadatagroup_getmetadatacount, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadatagroup_getmetadatacount") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadatagroup_getmetadatacount: " + err.Error()) - } - - implementation.Lib3MF_metadatagroup_getmetadata, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadatagroup_getmetadata") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadatagroup_getmetadata: " + err.Error()) - } - - implementation.Lib3MF_metadatagroup_getmetadatabykey, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadatagroup_getmetadatabykey") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadatagroup_getmetadatabykey: " + err.Error()) - } - - implementation.Lib3MF_metadatagroup_removemetadatabyindex, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadatagroup_removemetadatabyindex") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadatagroup_removemetadatabyindex: " + err.Error()) - } - - implementation.Lib3MF_metadatagroup_removemetadata, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadatagroup_removemetadata") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadatagroup_removemetadata: " + err.Error()) - } - - implementation.Lib3MF_metadatagroup_addmetadata, err = syscall.GetProcAddress(dllHandle, "lib3mf_metadatagroup_addmetadata") - if (err != nil) { - return errors.New("Could not get function lib3mf_metadatagroup_addmetadata: " + err.Error()) - } - - implementation.Lib3MF_object_gettype, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_gettype") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_gettype: " + err.Error()) - } - - implementation.Lib3MF_object_settype, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_settype") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_settype: " + err.Error()) - } - - implementation.Lib3MF_object_getname, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getname") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getname: " + err.Error()) - } - - implementation.Lib3MF_object_setname, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_setname") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_setname: " + err.Error()) - } - - implementation.Lib3MF_object_getpartnumber, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getpartnumber") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getpartnumber: " + err.Error()) - } - - implementation.Lib3MF_object_setpartnumber, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_setpartnumber") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_setpartnumber: " + err.Error()) - } - - implementation.Lib3MF_object_ismeshobject, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_ismeshobject") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_ismeshobject: " + err.Error()) - } - - implementation.Lib3MF_object_iscomponentsobject, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_iscomponentsobject") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_iscomponentsobject: " + err.Error()) - } - - implementation.Lib3MF_object_isvalid, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_isvalid") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_isvalid: " + err.Error()) - } - - implementation.Lib3MF_object_setattachmentasthumbnail, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_setattachmentasthumbnail") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_setattachmentasthumbnail: " + err.Error()) - } - - implementation.Lib3MF_object_getthumbnailattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getthumbnailattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getthumbnailattachment: " + err.Error()) - } - - implementation.Lib3MF_object_clearthumbnailattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_clearthumbnailattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_clearthumbnailattachment: " + err.Error()) - } - - implementation.Lib3MF_object_getoutbox, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getoutbox") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getoutbox: " + err.Error()) - } - - implementation.Lib3MF_object_getuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getuuid: " + err.Error()) - } - - implementation.Lib3MF_object_setuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_setuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_setuuid: " + err.Error()) - } - - implementation.Lib3MF_object_getmetadatagroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getmetadatagroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getmetadatagroup: " + err.Error()) - } - - implementation.Lib3MF_object_setslicesmeshresolution, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_setslicesmeshresolution") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_setslicesmeshresolution: " + err.Error()) - } - - implementation.Lib3MF_object_getslicesmeshresolution, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getslicesmeshresolution") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getslicesmeshresolution: " + err.Error()) - } - - implementation.Lib3MF_object_hasslices, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_hasslices") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_hasslices: " + err.Error()) - } - - implementation.Lib3MF_object_clearslicestack, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_clearslicestack") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_clearslicestack: " + err.Error()) - } - - implementation.Lib3MF_object_getslicestack, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_getslicestack") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_getslicestack: " + err.Error()) - } - - implementation.Lib3MF_object_assignslicestack, err = syscall.GetProcAddress(dllHandle, "lib3mf_object_assignslicestack") - if (err != nil) { - return errors.New("Could not get function lib3mf_object_assignslicestack: " + err.Error()) - } - - implementation.Lib3MF_meshobject_getvertexcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_getvertexcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_getvertexcount: " + err.Error()) - } - - implementation.Lib3MF_meshobject_gettrianglecount, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_gettrianglecount") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_gettrianglecount: " + err.Error()) - } - - implementation.Lib3MF_meshobject_getvertex, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_getvertex") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_getvertex: " + err.Error()) - } - - implementation.Lib3MF_meshobject_setvertex, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_setvertex") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_setvertex: " + err.Error()) - } - - implementation.Lib3MF_meshobject_addvertex, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_addvertex") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_addvertex: " + err.Error()) - } - - implementation.Lib3MF_meshobject_getvertices, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_getvertices") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_getvertices: " + err.Error()) - } - - implementation.Lib3MF_meshobject_gettriangle, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_gettriangle") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_gettriangle: " + err.Error()) - } - - implementation.Lib3MF_meshobject_settriangle, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_settriangle") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_settriangle: " + err.Error()) - } - - implementation.Lib3MF_meshobject_addtriangle, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_addtriangle") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_addtriangle: " + err.Error()) - } - - implementation.Lib3MF_meshobject_gettriangleindices, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_gettriangleindices") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_gettriangleindices: " + err.Error()) - } - - implementation.Lib3MF_meshobject_setobjectlevelproperty, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_setobjectlevelproperty") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_setobjectlevelproperty: " + err.Error()) - } - - implementation.Lib3MF_meshobject_getobjectlevelproperty, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_getobjectlevelproperty") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_getobjectlevelproperty: " + err.Error()) - } - - implementation.Lib3MF_meshobject_settriangleproperties, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_settriangleproperties") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_settriangleproperties: " + err.Error()) - } - - implementation.Lib3MF_meshobject_gettriangleproperties, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_gettriangleproperties") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_gettriangleproperties: " + err.Error()) - } - - implementation.Lib3MF_meshobject_setalltriangleproperties, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_setalltriangleproperties") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_setalltriangleproperties: " + err.Error()) - } - - implementation.Lib3MF_meshobject_getalltriangleproperties, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_getalltriangleproperties") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_getalltriangleproperties: " + err.Error()) - } - - implementation.Lib3MF_meshobject_clearallproperties, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_clearallproperties") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_clearallproperties: " + err.Error()) - } - - implementation.Lib3MF_meshobject_setgeometry, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_setgeometry") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_setgeometry: " + err.Error()) - } - - implementation.Lib3MF_meshobject_ismanifoldandoriented, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_ismanifoldandoriented") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_ismanifoldandoriented: " + err.Error()) - } - - implementation.Lib3MF_meshobject_beamlattice, err = syscall.GetProcAddress(dllHandle, "lib3mf_meshobject_beamlattice") - if (err != nil) { - return errors.New("Could not get function lib3mf_meshobject_beamlattice: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getminlength, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getminlength") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getminlength: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setminlength, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setminlength") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setminlength: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getclipping, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getclipping") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getclipping: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setclipping, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setclipping") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setclipping: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getrepresentation, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getrepresentation") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getrepresentation: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setrepresentation, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setrepresentation") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setrepresentation: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getballoptions, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getballoptions") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getballoptions: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setballoptions, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setballoptions") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setballoptions: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getbeamcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getbeamcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getbeamcount: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getbeam, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getbeam") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getbeam: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_addbeam, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_addbeam") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_addbeam: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setbeam, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setbeam") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setbeam: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setbeams, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setbeams") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setbeams: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getbeams, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getbeams") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getbeams: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getballcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getballcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getballcount: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getball, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getball") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getball: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_addball, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_addball") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_addball: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setball, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setball") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setball: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_setballs, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_setballs") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_setballs: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getballs, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getballs") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getballs: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getbeamsetcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getbeamsetcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getbeamsetcount: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_addbeamset, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_addbeamset") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_addbeamset: " + err.Error()) - } - - implementation.Lib3MF_beamlattice_getbeamset, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamlattice_getbeamset") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamlattice_getbeamset: " + err.Error()) - } - - implementation.Lib3MF_component_getobjectresource, err = syscall.GetProcAddress(dllHandle, "lib3mf_component_getobjectresource") - if (err != nil) { - return errors.New("Could not get function lib3mf_component_getobjectresource: " + err.Error()) - } - - implementation.Lib3MF_component_getobjectresourceid, err = syscall.GetProcAddress(dllHandle, "lib3mf_component_getobjectresourceid") - if (err != nil) { - return errors.New("Could not get function lib3mf_component_getobjectresourceid: " + err.Error()) - } - - implementation.Lib3MF_component_getuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_component_getuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_component_getuuid: " + err.Error()) - } - - implementation.Lib3MF_component_setuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_component_setuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_component_setuuid: " + err.Error()) - } - - implementation.Lib3MF_component_hastransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_component_hastransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_component_hastransform: " + err.Error()) - } - - implementation.Lib3MF_component_gettransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_component_gettransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_component_gettransform: " + err.Error()) - } - - implementation.Lib3MF_component_settransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_component_settransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_component_settransform: " + err.Error()) - } - - implementation.Lib3MF_componentsobject_addcomponent, err = syscall.GetProcAddress(dllHandle, "lib3mf_componentsobject_addcomponent") - if (err != nil) { - return errors.New("Could not get function lib3mf_componentsobject_addcomponent: " + err.Error()) - } - - implementation.Lib3MF_componentsobject_getcomponent, err = syscall.GetProcAddress(dllHandle, "lib3mf_componentsobject_getcomponent") - if (err != nil) { - return errors.New("Could not get function lib3mf_componentsobject_getcomponent: " + err.Error()) - } - - implementation.Lib3MF_componentsobject_getcomponentcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_componentsobject_getcomponentcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_componentsobject_getcomponentcount: " + err.Error()) - } - - implementation.Lib3MF_beamset_setname, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_setname") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_setname: " + err.Error()) - } - - implementation.Lib3MF_beamset_getname, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_getname") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_getname: " + err.Error()) - } - - implementation.Lib3MF_beamset_setidentifier, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_setidentifier") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_setidentifier: " + err.Error()) - } - - implementation.Lib3MF_beamset_getidentifier, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_getidentifier") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_getidentifier: " + err.Error()) - } - - implementation.Lib3MF_beamset_getreferencecount, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_getreferencecount") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_getreferencecount: " + err.Error()) - } - - implementation.Lib3MF_beamset_setreferences, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_setreferences") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_setreferences: " + err.Error()) - } - - implementation.Lib3MF_beamset_getreferences, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_getreferences") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_getreferences: " + err.Error()) - } - - implementation.Lib3MF_beamset_getballreferencecount, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_getballreferencecount") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_getballreferencecount: " + err.Error()) - } - - implementation.Lib3MF_beamset_setballreferences, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_setballreferences") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_setballreferences: " + err.Error()) - } - - implementation.Lib3MF_beamset_getballreferences, err = syscall.GetProcAddress(dllHandle, "lib3mf_beamset_getballreferences") - if (err != nil) { - return errors.New("Could not get function lib3mf_beamset_getballreferences: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_getcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_getcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_getcount: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_getallpropertyids, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_getallpropertyids") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_getallpropertyids: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_addmaterial, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_addmaterial") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_addmaterial: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_removematerial, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_removematerial") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_removematerial: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_getname, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_getname") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_getname: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_setname, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_setname") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_setname: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_setdisplaycolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_setdisplaycolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_setdisplaycolor: " + err.Error()) - } - - implementation.Lib3MF_basematerialgroup_getdisplaycolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_basematerialgroup_getdisplaycolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_basematerialgroup_getdisplaycolor: " + err.Error()) - } - - implementation.Lib3MF_colorgroup_getcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_colorgroup_getcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_colorgroup_getcount: " + err.Error()) - } - - implementation.Lib3MF_colorgroup_getallpropertyids, err = syscall.GetProcAddress(dllHandle, "lib3mf_colorgroup_getallpropertyids") - if (err != nil) { - return errors.New("Could not get function lib3mf_colorgroup_getallpropertyids: " + err.Error()) - } - - implementation.Lib3MF_colorgroup_addcolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_colorgroup_addcolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_colorgroup_addcolor: " + err.Error()) - } - - implementation.Lib3MF_colorgroup_removecolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_colorgroup_removecolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_colorgroup_removecolor: " + err.Error()) - } - - implementation.Lib3MF_colorgroup_setcolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_colorgroup_setcolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_colorgroup_setcolor: " + err.Error()) - } - - implementation.Lib3MF_colorgroup_getcolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_colorgroup_getcolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_colorgroup_getcolor: " + err.Error()) - } - - implementation.Lib3MF_texture2dgroup_getcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2dgroup_getcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2dgroup_getcount: " + err.Error()) - } - - implementation.Lib3MF_texture2dgroup_getallpropertyids, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2dgroup_getallpropertyids") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2dgroup_getallpropertyids: " + err.Error()) - } - - implementation.Lib3MF_texture2dgroup_addtex2coord, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2dgroup_addtex2coord") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2dgroup_addtex2coord: " + err.Error()) - } - - implementation.Lib3MF_texture2dgroup_gettex2coord, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2dgroup_gettex2coord") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2dgroup_gettex2coord: " + err.Error()) - } - - implementation.Lib3MF_texture2dgroup_removetex2coord, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2dgroup_removetex2coord") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2dgroup_removetex2coord: " + err.Error()) - } - - implementation.Lib3MF_texture2dgroup_gettexture2d, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2dgroup_gettexture2d") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2dgroup_gettexture2d: " + err.Error()) - } - - implementation.Lib3MF_compositematerials_getcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_compositematerials_getcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_compositematerials_getcount: " + err.Error()) - } - - implementation.Lib3MF_compositematerials_getallpropertyids, err = syscall.GetProcAddress(dllHandle, "lib3mf_compositematerials_getallpropertyids") - if (err != nil) { - return errors.New("Could not get function lib3mf_compositematerials_getallpropertyids: " + err.Error()) - } - - implementation.Lib3MF_compositematerials_getbasematerialgroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_compositematerials_getbasematerialgroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_compositematerials_getbasematerialgroup: " + err.Error()) - } - - implementation.Lib3MF_compositematerials_addcomposite, err = syscall.GetProcAddress(dllHandle, "lib3mf_compositematerials_addcomposite") - if (err != nil) { - return errors.New("Could not get function lib3mf_compositematerials_addcomposite: " + err.Error()) - } - - implementation.Lib3MF_compositematerials_removecomposite, err = syscall.GetProcAddress(dllHandle, "lib3mf_compositematerials_removecomposite") - if (err != nil) { - return errors.New("Could not get function lib3mf_compositematerials_removecomposite: " + err.Error()) - } - - implementation.Lib3MF_compositematerials_getcomposite, err = syscall.GetProcAddress(dllHandle, "lib3mf_compositematerials_getcomposite") - if (err != nil) { - return errors.New("Could not get function lib3mf_compositematerials_getcomposite: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_getcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_getcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_getcount: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_getallpropertyids, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_getallpropertyids") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_getallpropertyids: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_addmultiproperty, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_addmultiproperty") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_addmultiproperty: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_setmultiproperty, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_setmultiproperty") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_setmultiproperty: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_getmultiproperty, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_getmultiproperty") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_getmultiproperty: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_removemultiproperty, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_removemultiproperty") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_removemultiproperty: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_getlayercount, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_getlayercount") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_getlayercount: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_addlayer, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_addlayer") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_addlayer: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_getlayer, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_getlayer") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_getlayer: " + err.Error()) - } - - implementation.Lib3MF_multipropertygroup_removelayer, err = syscall.GetProcAddress(dllHandle, "lib3mf_multipropertygroup_removelayer") - if (err != nil) { - return errors.New("Could not get function lib3mf_multipropertygroup_removelayer: " + err.Error()) - } - - implementation.Lib3MF_attachment_getpath, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_getpath") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_getpath: " + err.Error()) - } - - implementation.Lib3MF_attachment_setpath, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_setpath") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_setpath: " + err.Error()) - } - - implementation.Lib3MF_attachment_packagepart, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_packagepart") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_packagepart: " + err.Error()) - } - - implementation.Lib3MF_attachment_getrelationshiptype, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_getrelationshiptype") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_getrelationshiptype: " + err.Error()) - } - - implementation.Lib3MF_attachment_setrelationshiptype, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_setrelationshiptype") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_setrelationshiptype: " + err.Error()) - } - - implementation.Lib3MF_attachment_writetofile, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_writetofile") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_writetofile: " + err.Error()) - } - - implementation.Lib3MF_attachment_readfromfile, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_readfromfile") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_readfromfile: " + err.Error()) - } - - implementation.Lib3MF_attachment_readfromcallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_readfromcallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_readfromcallback: " + err.Error()) - } - - implementation.Lib3MF_attachment_getstreamsize, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_getstreamsize") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_getstreamsize: " + err.Error()) - } - - implementation.Lib3MF_attachment_writetobuffer, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_writetobuffer") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_writetobuffer: " + err.Error()) - } - - implementation.Lib3MF_attachment_readfrombuffer, err = syscall.GetProcAddress(dllHandle, "lib3mf_attachment_readfrombuffer") - if (err != nil) { - return errors.New("Could not get function lib3mf_attachment_readfrombuffer: " + err.Error()) - } - - implementation.Lib3MF_texture2d_getattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_getattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_getattachment: " + err.Error()) - } - - implementation.Lib3MF_texture2d_setattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_setattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_setattachment: " + err.Error()) - } - - implementation.Lib3MF_texture2d_getcontenttype, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_getcontenttype") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_getcontenttype: " + err.Error()) - } - - implementation.Lib3MF_texture2d_setcontenttype, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_setcontenttype") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_setcontenttype: " + err.Error()) - } - - implementation.Lib3MF_texture2d_gettilestyleuv, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_gettilestyleuv") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_gettilestyleuv: " + err.Error()) - } - - implementation.Lib3MF_texture2d_settilestyleuv, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_settilestyleuv") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_settilestyleuv: " + err.Error()) - } - - implementation.Lib3MF_texture2d_getfilter, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_getfilter") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_getfilter: " + err.Error()) - } - - implementation.Lib3MF_texture2d_setfilter, err = syscall.GetProcAddress(dllHandle, "lib3mf_texture2d_setfilter") - if (err != nil) { - return errors.New("Could not get function lib3mf_texture2d_setfilter: " + err.Error()) - } - - implementation.Lib3MF_builditem_getobjectresource, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_getobjectresource") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_getobjectresource: " + err.Error()) - } - - implementation.Lib3MF_builditem_getuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_getuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_getuuid: " + err.Error()) - } - - implementation.Lib3MF_builditem_setuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_setuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_setuuid: " + err.Error()) - } - - implementation.Lib3MF_builditem_getobjectresourceid, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_getobjectresourceid") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_getobjectresourceid: " + err.Error()) - } - - implementation.Lib3MF_builditem_hasobjecttransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_hasobjecttransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_hasobjecttransform: " + err.Error()) - } - - implementation.Lib3MF_builditem_getobjecttransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_getobjecttransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_getobjecttransform: " + err.Error()) - } - - implementation.Lib3MF_builditem_setobjecttransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_setobjecttransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_setobjecttransform: " + err.Error()) - } - - implementation.Lib3MF_builditem_getpartnumber, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_getpartnumber") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_getpartnumber: " + err.Error()) - } - - implementation.Lib3MF_builditem_setpartnumber, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_setpartnumber") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_setpartnumber: " + err.Error()) - } - - implementation.Lib3MF_builditem_getmetadatagroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_getmetadatagroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_getmetadatagroup: " + err.Error()) - } - - implementation.Lib3MF_builditem_getoutbox, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditem_getoutbox") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditem_getoutbox: " + err.Error()) - } - - implementation.Lib3MF_builditemiterator_movenext, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditemiterator_movenext") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditemiterator_movenext: " + err.Error()) - } - - implementation.Lib3MF_builditemiterator_moveprevious, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditemiterator_moveprevious") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditemiterator_moveprevious: " + err.Error()) - } - - implementation.Lib3MF_builditemiterator_getcurrent, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditemiterator_getcurrent") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditemiterator_getcurrent: " + err.Error()) - } - - implementation.Lib3MF_builditemiterator_clone, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditemiterator_clone") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditemiterator_clone: " + err.Error()) - } - - implementation.Lib3MF_builditemiterator_count, err = syscall.GetProcAddress(dllHandle, "lib3mf_builditemiterator_count") - if (err != nil) { - return errors.New("Could not get function lib3mf_builditemiterator_count: " + err.Error()) - } - - implementation.Lib3MF_slice_setvertices, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_setvertices") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_setvertices: " + err.Error()) - } - - implementation.Lib3MF_slice_getvertices, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_getvertices") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_getvertices: " + err.Error()) - } - - implementation.Lib3MF_slice_getvertexcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_getvertexcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_getvertexcount: " + err.Error()) - } - - implementation.Lib3MF_slice_addpolygon, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_addpolygon") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_addpolygon: " + err.Error()) - } - - implementation.Lib3MF_slice_getpolygoncount, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_getpolygoncount") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_getpolygoncount: " + err.Error()) - } - - implementation.Lib3MF_slice_setpolygonindices, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_setpolygonindices") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_setpolygonindices: " + err.Error()) - } - - implementation.Lib3MF_slice_getpolygonindices, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_getpolygonindices") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_getpolygonindices: " + err.Error()) - } - - implementation.Lib3MF_slice_getpolygonindexcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_getpolygonindexcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_getpolygonindexcount: " + err.Error()) - } - - implementation.Lib3MF_slice_getztop, err = syscall.GetProcAddress(dllHandle, "lib3mf_slice_getztop") - if (err != nil) { - return errors.New("Could not get function lib3mf_slice_getztop: " + err.Error()) - } - - implementation.Lib3MF_slicestack_getbottomz, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_getbottomz") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_getbottomz: " + err.Error()) - } - - implementation.Lib3MF_slicestack_getslicecount, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_getslicecount") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_getslicecount: " + err.Error()) - } - - implementation.Lib3MF_slicestack_getslice, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_getslice") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_getslice: " + err.Error()) - } - - implementation.Lib3MF_slicestack_addslice, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_addslice") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_addslice: " + err.Error()) - } - - implementation.Lib3MF_slicestack_getslicerefcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_getslicerefcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_getslicerefcount: " + err.Error()) - } - - implementation.Lib3MF_slicestack_addslicestackreference, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_addslicestackreference") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_addslicestackreference: " + err.Error()) - } - - implementation.Lib3MF_slicestack_getslicestackreference, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_getslicestackreference") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_getslicestackreference: " + err.Error()) - } - - implementation.Lib3MF_slicestack_collapseslicereferences, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_collapseslicereferences") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_collapseslicereferences: " + err.Error()) - } - - implementation.Lib3MF_slicestack_setownpath, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_setownpath") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_setownpath: " + err.Error()) - } - - implementation.Lib3MF_slicestack_getownpath, err = syscall.GetProcAddress(dllHandle, "lib3mf_slicestack_getownpath") - if (err != nil) { - return errors.New("Could not get function lib3mf_slicestack_getownpath: " + err.Error()) - } - - implementation.Lib3MF_consumer_getconsumerid, err = syscall.GetProcAddress(dllHandle, "lib3mf_consumer_getconsumerid") - if (err != nil) { - return errors.New("Could not get function lib3mf_consumer_getconsumerid: " + err.Error()) - } - - implementation.Lib3MF_consumer_getkeyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_consumer_getkeyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_consumer_getkeyid: " + err.Error()) - } - - implementation.Lib3MF_consumer_getkeyvalue, err = syscall.GetProcAddress(dllHandle, "lib3mf_consumer_getkeyvalue") - if (err != nil) { - return errors.New("Could not get function lib3mf_consumer_getkeyvalue: " + err.Error()) - } - - implementation.Lib3MF_accessright_getconsumer, err = syscall.GetProcAddress(dllHandle, "lib3mf_accessright_getconsumer") - if (err != nil) { - return errors.New("Could not get function lib3mf_accessright_getconsumer: " + err.Error()) - } - - implementation.Lib3MF_accessright_getwrappingalgorithm, err = syscall.GetProcAddress(dllHandle, "lib3mf_accessright_getwrappingalgorithm") - if (err != nil) { - return errors.New("Could not get function lib3mf_accessright_getwrappingalgorithm: " + err.Error()) - } - - implementation.Lib3MF_accessright_getmgfalgorithm, err = syscall.GetProcAddress(dllHandle, "lib3mf_accessright_getmgfalgorithm") - if (err != nil) { - return errors.New("Could not get function lib3mf_accessright_getmgfalgorithm: " + err.Error()) - } - - implementation.Lib3MF_accessright_getdigestmethod, err = syscall.GetProcAddress(dllHandle, "lib3mf_accessright_getdigestmethod") - if (err != nil) { - return errors.New("Could not get function lib3mf_accessright_getdigestmethod: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_getencryptionalgorithm, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_getencryptionalgorithm") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_getencryptionalgorithm: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_getkey, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_getkey") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_getkey: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_getinitializationvector, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_getinitializationvector") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_getinitializationvector: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_getauthenticationtag, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_getauthenticationtag") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_getauthenticationtag: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_setauthenticationtag, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_setauthenticationtag") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_setauthenticationtag: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_getadditionalauthenticationdata, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_getadditionalauthenticationdata") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_getadditionalauthenticationdata: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_getdescriptor, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_getdescriptor") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_getdescriptor: " + err.Error()) - } - - implementation.Lib3MF_contentencryptionparams_getkeyuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_contentencryptionparams_getkeyuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_contentencryptionparams_getkeyuuid: " + err.Error()) - } - - implementation.Lib3MF_resourcedata_getpath, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedata_getpath") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedata_getpath: " + err.Error()) - } - - implementation.Lib3MF_resourcedata_getencryptionalgorithm, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedata_getencryptionalgorithm") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedata_getencryptionalgorithm: " + err.Error()) - } - - implementation.Lib3MF_resourcedata_getcompression, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedata_getcompression") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedata_getcompression: " + err.Error()) - } - - implementation.Lib3MF_resourcedata_getadditionalauthenticationdata, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedata_getadditionalauthenticationdata") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedata_getadditionalauthenticationdata: " + err.Error()) - } - - implementation.Lib3MF_resourcedatagroup_getkeyuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedatagroup_getkeyuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedatagroup_getkeyuuid: " + err.Error()) - } - - implementation.Lib3MF_resourcedatagroup_addaccessright, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedatagroup_addaccessright") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedatagroup_addaccessright: " + err.Error()) - } - - implementation.Lib3MF_resourcedatagroup_findaccessrightbyconsumer, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedatagroup_findaccessrightbyconsumer") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedatagroup_findaccessrightbyconsumer: " + err.Error()) - } - - implementation.Lib3MF_resourcedatagroup_removeaccessright, err = syscall.GetProcAddress(dllHandle, "lib3mf_resourcedatagroup_removeaccessright") - if (err != nil) { - return errors.New("Could not get function lib3mf_resourcedatagroup_removeaccessright: " + err.Error()) - } - - implementation.Lib3MF_keystore_addconsumer, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_addconsumer") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_addconsumer: " + err.Error()) - } - - implementation.Lib3MF_keystore_getconsumercount, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_getconsumercount") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_getconsumercount: " + err.Error()) - } - - implementation.Lib3MF_keystore_getconsumer, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_getconsumer") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_getconsumer: " + err.Error()) - } - - implementation.Lib3MF_keystore_removeconsumer, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_removeconsumer") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_removeconsumer: " + err.Error()) - } - - implementation.Lib3MF_keystore_findconsumer, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_findconsumer") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_findconsumer: " + err.Error()) - } - - implementation.Lib3MF_keystore_getresourcedatagroupcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_getresourcedatagroupcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_getresourcedatagroupcount: " + err.Error()) - } - - implementation.Lib3MF_keystore_addresourcedatagroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_addresourcedatagroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_addresourcedatagroup: " + err.Error()) - } - - implementation.Lib3MF_keystore_getresourcedatagroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_getresourcedatagroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_getresourcedatagroup: " + err.Error()) - } - - implementation.Lib3MF_keystore_removeresourcedatagroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_removeresourcedatagroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_removeresourcedatagroup: " + err.Error()) - } - - implementation.Lib3MF_keystore_findresourcedatagroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_findresourcedatagroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_findresourcedatagroup: " + err.Error()) - } - - implementation.Lib3MF_keystore_addresourcedata, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_addresourcedata") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_addresourcedata: " + err.Error()) - } - - implementation.Lib3MF_keystore_removeresourcedata, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_removeresourcedata") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_removeresourcedata: " + err.Error()) - } - - implementation.Lib3MF_keystore_findresourcedata, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_findresourcedata") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_findresourcedata: " + err.Error()) - } - - implementation.Lib3MF_keystore_getresourcedatacount, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_getresourcedatacount") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_getresourcedatacount: " + err.Error()) - } - - implementation.Lib3MF_keystore_getresourcedata, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_getresourcedata") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_getresourcedata: " + err.Error()) - } - - implementation.Lib3MF_keystore_getuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_getuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_getuuid: " + err.Error()) - } - - implementation.Lib3MF_keystore_setuuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_keystore_setuuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_keystore_setuuid: " + err.Error()) - } - - implementation.Lib3MF_model_rootmodelpart, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_rootmodelpart") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_rootmodelpart: " + err.Error()) - } - - implementation.Lib3MF_model_findorcreatepackagepart, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_findorcreatepackagepart") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_findorcreatepackagepart: " + err.Error()) - } - - implementation.Lib3MF_model_setunit, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_setunit") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_setunit: " + err.Error()) - } - - implementation.Lib3MF_model_getunit, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getunit") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getunit: " + err.Error()) - } - - implementation.Lib3MF_model_getlanguage, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getlanguage") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getlanguage: " + err.Error()) - } - - implementation.Lib3MF_model_setlanguage, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_setlanguage") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_setlanguage: " + err.Error()) - } - - implementation.Lib3MF_model_querywriter, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_querywriter") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_querywriter: " + err.Error()) - } - - implementation.Lib3MF_model_queryreader, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_queryreader") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_queryreader: " + err.Error()) - } - - implementation.Lib3MF_model_gettexture2dbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_gettexture2dbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_gettexture2dbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getpropertytypebyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getpropertytypebyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getpropertytypebyid: " + err.Error()) - } - - implementation.Lib3MF_model_getbasematerialgroupbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getbasematerialgroupbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getbasematerialgroupbyid: " + err.Error()) - } - - implementation.Lib3MF_model_gettexture2dgroupbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_gettexture2dgroupbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_gettexture2dgroupbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getcompositematerialsbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getcompositematerialsbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getcompositematerialsbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getmultipropertygroupbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getmultipropertygroupbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getmultipropertygroupbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getmeshobjectbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getmeshobjectbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getmeshobjectbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getcomponentsobjectbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getcomponentsobjectbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getcomponentsobjectbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getcolorgroupbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getcolorgroupbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getcolorgroupbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getslicestackbyid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getslicestackbyid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getslicestackbyid: " + err.Error()) - } - - implementation.Lib3MF_model_getbuilduuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getbuilduuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getbuilduuid: " + err.Error()) - } - - implementation.Lib3MF_model_setbuilduuid, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_setbuilduuid") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_setbuilduuid: " + err.Error()) - } - - implementation.Lib3MF_model_getbuilditems, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getbuilditems") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getbuilditems: " + err.Error()) - } - - implementation.Lib3MF_model_getoutbox, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getoutbox") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getoutbox: " + err.Error()) - } - - implementation.Lib3MF_model_getresources, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getresources") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getresources: " + err.Error()) - } - - implementation.Lib3MF_model_getobjects, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getobjects") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getobjects: " + err.Error()) - } - - implementation.Lib3MF_model_getmeshobjects, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getmeshobjects") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getmeshobjects: " + err.Error()) - } - - implementation.Lib3MF_model_getcomponentsobjects, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getcomponentsobjects") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getcomponentsobjects: " + err.Error()) - } - - implementation.Lib3MF_model_gettexture2ds, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_gettexture2ds") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_gettexture2ds: " + err.Error()) - } - - implementation.Lib3MF_model_getbasematerialgroups, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getbasematerialgroups") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getbasematerialgroups: " + err.Error()) - } - - implementation.Lib3MF_model_getcolorgroups, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getcolorgroups") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getcolorgroups: " + err.Error()) - } - - implementation.Lib3MF_model_gettexture2dgroups, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_gettexture2dgroups") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_gettexture2dgroups: " + err.Error()) - } - - implementation.Lib3MF_model_getcompositematerials, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getcompositematerials") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getcompositematerials: " + err.Error()) - } - - implementation.Lib3MF_model_getmultipropertygroups, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getmultipropertygroups") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getmultipropertygroups: " + err.Error()) - } - - implementation.Lib3MF_model_getslicestacks, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getslicestacks") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getslicestacks: " + err.Error()) - } - - implementation.Lib3MF_model_mergetomodel, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_mergetomodel") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_mergetomodel: " + err.Error()) - } - - implementation.Lib3MF_model_addmeshobject, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addmeshobject") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addmeshobject: " + err.Error()) - } - - implementation.Lib3MF_model_addcomponentsobject, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addcomponentsobject") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addcomponentsobject: " + err.Error()) - } - - implementation.Lib3MF_model_addslicestack, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addslicestack") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addslicestack: " + err.Error()) - } - - implementation.Lib3MF_model_addtexture2dfromattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addtexture2dfromattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addtexture2dfromattachment: " + err.Error()) - } - - implementation.Lib3MF_model_addbasematerialgroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addbasematerialgroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addbasematerialgroup: " + err.Error()) - } - - implementation.Lib3MF_model_addcolorgroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addcolorgroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addcolorgroup: " + err.Error()) - } - - implementation.Lib3MF_model_addtexture2dgroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addtexture2dgroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addtexture2dgroup: " + err.Error()) - } - - implementation.Lib3MF_model_addcompositematerials, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addcompositematerials") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addcompositematerials: " + err.Error()) - } - - implementation.Lib3MF_model_addmultipropertygroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addmultipropertygroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addmultipropertygroup: " + err.Error()) - } - - implementation.Lib3MF_model_addbuilditem, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addbuilditem") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addbuilditem: " + err.Error()) - } - - implementation.Lib3MF_model_removebuilditem, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_removebuilditem") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_removebuilditem: " + err.Error()) - } - - implementation.Lib3MF_model_getmetadatagroup, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getmetadatagroup") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getmetadatagroup: " + err.Error()) - } - - implementation.Lib3MF_model_addattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addattachment: " + err.Error()) - } - - implementation.Lib3MF_model_removeattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_removeattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_removeattachment: " + err.Error()) - } - - implementation.Lib3MF_model_getattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getattachment: " + err.Error()) - } - - implementation.Lib3MF_model_findattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_findattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_findattachment: " + err.Error()) - } - - implementation.Lib3MF_model_getattachmentcount, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getattachmentcount") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getattachmentcount: " + err.Error()) - } - - implementation.Lib3MF_model_haspackagethumbnailattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_haspackagethumbnailattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_haspackagethumbnailattachment: " + err.Error()) - } - - implementation.Lib3MF_model_createpackagethumbnailattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_createpackagethumbnailattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_createpackagethumbnailattachment: " + err.Error()) - } - - implementation.Lib3MF_model_getpackagethumbnailattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getpackagethumbnailattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getpackagethumbnailattachment: " + err.Error()) - } - - implementation.Lib3MF_model_removepackagethumbnailattachment, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_removepackagethumbnailattachment") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_removepackagethumbnailattachment: " + err.Error()) - } - - implementation.Lib3MF_model_addcustomcontenttype, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_addcustomcontenttype") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_addcustomcontenttype: " + err.Error()) - } - - implementation.Lib3MF_model_removecustomcontenttype, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_removecustomcontenttype") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_removecustomcontenttype: " + err.Error()) - } - - implementation.Lib3MF_model_setrandomnumbercallback, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_setrandomnumbercallback") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_setrandomnumbercallback: " + err.Error()) - } - - implementation.Lib3MF_model_getkeystore, err = syscall.GetProcAddress(dllHandle, "lib3mf_model_getkeystore") - if (err != nil) { - return errors.New("Could not get function lib3mf_model_getkeystore: " + err.Error()) - } - - implementation.Lib3MF_getlibraryversion, err = syscall.GetProcAddress(dllHandle, "lib3mf_getlibraryversion") - if (err != nil) { - return errors.New("Could not get function lib3mf_getlibraryversion: " + err.Error()) - } - - implementation.Lib3MF_getprereleaseinformation, err = syscall.GetProcAddress(dllHandle, "lib3mf_getprereleaseinformation") - if (err != nil) { - return errors.New("Could not get function lib3mf_getprereleaseinformation: " + err.Error()) - } - - implementation.Lib3MF_getbuildinformation, err = syscall.GetProcAddress(dllHandle, "lib3mf_getbuildinformation") - if (err != nil) { - return errors.New("Could not get function lib3mf_getbuildinformation: " + err.Error()) - } - - implementation.Lib3MF_getspecificationversion, err = syscall.GetProcAddress(dllHandle, "lib3mf_getspecificationversion") - if (err != nil) { - return errors.New("Could not get function lib3mf_getspecificationversion: " + err.Error()) - } - - implementation.Lib3MF_createmodel, err = syscall.GetProcAddress(dllHandle, "lib3mf_createmodel") - if (err != nil) { - return errors.New("Could not get function lib3mf_createmodel: " + err.Error()) - } - - implementation.Lib3MF_release, err = syscall.GetProcAddress(dllHandle, "lib3mf_release") - if (err != nil) { - return errors.New("Could not get function lib3mf_release: " + err.Error()) - } - - implementation.Lib3MF_acquire, err = syscall.GetProcAddress(dllHandle, "lib3mf_acquire") - if (err != nil) { - return errors.New("Could not get function lib3mf_acquire: " + err.Error()) - } - - implementation.Lib3MF_setjournal, err = syscall.GetProcAddress(dllHandle, "lib3mf_setjournal") - if (err != nil) { - return errors.New("Could not get function lib3mf_setjournal: " + err.Error()) - } - - implementation.Lib3MF_getlasterror, err = syscall.GetProcAddress(dllHandle, "lib3mf_getlasterror") - if (err != nil) { - return errors.New("Could not get function lib3mf_getlasterror: " + err.Error()) - } - - implementation.Lib3MF_getsymbollookupmethod, err = syscall.GetProcAddress(dllHandle, "lib3mf_getsymbollookupmethod") - if (err != nil) { - return errors.New("Could not get function lib3mf_getsymbollookupmethod: " + err.Error()) - } - - implementation.Lib3MF_retrieveprogressmessage, err = syscall.GetProcAddress(dllHandle, "lib3mf_retrieveprogressmessage") - if (err != nil) { - return errors.New("Could not get function lib3mf_retrieveprogressmessage: " + err.Error()) - } - - implementation.Lib3MF_rgbatocolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_rgbatocolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_rgbatocolor: " + err.Error()) - } - - implementation.Lib3MF_floatrgbatocolor, err = syscall.GetProcAddress(dllHandle, "lib3mf_floatrgbatocolor") - if (err != nil) { - return errors.New("Could not get function lib3mf_floatrgbatocolor: " + err.Error()) - } - - implementation.Lib3MF_colortorgba, err = syscall.GetProcAddress(dllHandle, "lib3mf_colortorgba") - if (err != nil) { - return errors.New("Could not get function lib3mf_colortorgba: " + err.Error()) - } - - implementation.Lib3MF_colortofloatrgba, err = syscall.GetProcAddress(dllHandle, "lib3mf_colortofloatrgba") - if (err != nil) { - return errors.New("Could not get function lib3mf_colortofloatrgba: " + err.Error()) - } - - implementation.Lib3MF_getidentitytransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_getidentitytransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_getidentitytransform: " + err.Error()) - } - - implementation.Lib3MF_getuniformscaletransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_getuniformscaletransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_getuniformscaletransform: " + err.Error()) - } - - implementation.Lib3MF_getscaletransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_getscaletransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_getscaletransform: " + err.Error()) - } - - implementation.Lib3MF_gettranslationtransform, err = syscall.GetProcAddress(dllHandle, "lib3mf_gettranslationtransform") - if (err != nil) { - return errors.New("Could not get function lib3mf_gettranslationtransform: " + err.Error()) - } - - implementation.DLLHandle = dllHandle - implementation.Initialized = true - return nil -} - -func (implementation *Lib3MFImplementation) NewHandle() (Lib3MFImplementationHandle) { - handle := new (Lib3MFImplementationHandleStruct) - handle.Implementation = implementation - handle.DLLhandle = 0 - return handle -} - -func (implementation *Lib3MFImplementation) CallFunction(funcptr uintptr, parameters ... uintptr) (error) { - var ret uintptr; - if (!implementation.Initialized) { - return errors.New("Lib3MF Implementation has not been initialized!") - } - - switch len(parameters) { - case 0: ret, _, _ = syscall.Syscall(funcptr, 0, 0, 0, 0) - case 1: ret, _, _ = syscall.Syscall(funcptr, 1, uintptr(parameters[0]), 0, 0) - case 2: ret, _, _ = syscall.Syscall(funcptr, 2, uintptr(parameters[0]), uintptr(parameters[1]), 0) - case 3: ret, _, _ = syscall.Syscall(funcptr, 3, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2])) - case 4: ret, _, _ = syscall.Syscall6(funcptr, 4, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), 0, 0) - case 5: ret, _, _ = syscall.Syscall6(funcptr, 5, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), 0) - case 6: ret, _, _ = syscall.Syscall6(funcptr, 6, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), uintptr(parameters[5])) - case 7: ret, _, _ = syscall.Syscall9(funcptr, 7, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), uintptr(parameters[5]), uintptr(parameters[6]), 0, 0) - case 8: ret, _, _ = syscall.Syscall9(funcptr, 8, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), uintptr(parameters[5]), uintptr(parameters[6]), uintptr(parameters[7]), 0) - case 9: ret, _, _ = syscall.Syscall9(funcptr, 9, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), uintptr(parameters[5]), uintptr(parameters[6]), uintptr(parameters[7]), uintptr(parameters[8])) - case 10: ret, _, _ = syscall.Syscall12(funcptr, 10, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), uintptr(parameters[5]), uintptr(parameters[6]), uintptr(parameters[7]), uintptr(parameters[8]), uintptr(parameters[9]), 0, 0) - case 11: ret, _, _ = syscall.Syscall12(funcptr, 11, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), uintptr(parameters[5]), uintptr(parameters[6]), uintptr(parameters[7]), uintptr(parameters[8]), uintptr(parameters[9]), uintptr(parameters[10]), 0) - case 12: ret, _, _ = syscall.Syscall12(funcptr, 12, uintptr(parameters[0]), uintptr(parameters[1]), uintptr(parameters[2]), uintptr(parameters[3]), uintptr(parameters[4]), uintptr(parameters[5]), uintptr(parameters[6]), uintptr(parameters[7]), uintptr(parameters[8]), uintptr(parameters[9]), uintptr(parameters[10]), uintptr(parameters[11])) - default: - return errors.New("Invalid DLL function parameter count!"); - } - - if (int(ret) != 0) { - return errors.New(fmt.Sprintf("Lib3MF Error: %.04x (%s)", int(ret), GetLib3MFErrorMessage(uint32(ret)))) - } - - return nil -} - - -func (implementation *Lib3MFImplementation) Writer_WriteToFile(Writer Lib3MFHandle, sFilename string) (error) { - var err error = nil - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_writetofile, implementation_writer.GetDLLInHandle(), StringInValue(sFilename)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Writer_GetStreamSize(Writer Lib3MFHandle) (uint64, error) { - var err error = nil - var nStreamSize uint64 = 0 - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_getstreamsize, implementation_writer.GetDLLInHandle(), UInt64OutValue(&nStreamSize)) - if (err != nil) { - return 0, err - } - - return uint64(nStreamSize), err -} - -func (implementation *Lib3MFImplementation) Writer_WriteToBuffer(Writer Lib3MFHandle) ([]uint8, error) { - var err error = nil - var neededforBuffer int64 = 0 - var filledinBuffer int64 = 0 - bufferBuffer := make([]uint8, 0) - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return make([]uint8, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_writetobuffer, implementation_writer.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforBuffer), Int64InValue(0)) - if (err != nil) { - return make([]uint8, 0), err - } - bufferSizeBuffer := neededforBuffer - bufferBuffer = make([]uint8, bufferSizeBuffer) - err = implementation.CallFunction(implementation.Lib3MF_writer_writetobuffer, implementation_writer.GetDLLInHandle(), Int64InValue(bufferSizeBuffer), Int64OutValue(&filledinBuffer), uintptr(unsafe.Pointer(&bufferBuffer[0]))) - if (err != nil) { - return make([]uint8, 0), err - } - - return bufferBuffer, err -} - -func (implementation *Lib3MFImplementation) Writer_WriteToCallback(Writer Lib3MFHandle, pTheWriteCallback int64, pTheSeekCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_writetocallback, implementation_writer.GetDLLInHandle(), 0, 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Writer_SetProgressCallback(Writer Lib3MFHandle, pProgressCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_setprogresscallback, implementation_writer.GetDLLInHandle(), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Writer_GetDecimalPrecision(Writer Lib3MFHandle) (uint32, error) { - var err error = nil - var nDecimalPrecision uint32 = 0 - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_getdecimalprecision, implementation_writer.GetDLLInHandle(), UInt32OutValue(&nDecimalPrecision)) - if (err != nil) { - return 0, err - } - - return uint32(nDecimalPrecision), err -} - -func (implementation *Lib3MFImplementation) Writer_SetDecimalPrecision(Writer Lib3MFHandle, nDecimalPrecision uint32) (error) { - var err error = nil - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_setdecimalprecision, implementation_writer.GetDLLInHandle(), UInt32InValue(nDecimalPrecision)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Writer_SetStrictModeActive(Writer Lib3MFHandle, bStrictModeActive bool) (error) { - var err error = nil - var nStrictModeActive uint8 = 0 - if (bStrictModeActive) { - nStrictModeActive = 1 - } - - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_setstrictmodeactive, implementation_writer.GetDLLInHandle(), UInt8InValue(nStrictModeActive)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Writer_GetStrictModeActive(Writer Lib3MFHandle) (bool, error) { - var err error = nil - var bStrictModeActive int64 = 0 - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_getstrictmodeactive, implementation_writer.GetDLLInHandle(), Int64OutValue(&bStrictModeActive)) - if (err != nil) { - return false, err - } - - return (bStrictModeActive != 0), err -} - -func (implementation *Lib3MFImplementation) Writer_GetWarning(Writer Lib3MFHandle, nIndex uint32) (uint32, string, error) { - var err error = nil - var nErrorCode uint32 = 0 - var neededforWarning int64 = 0 - var filledinWarning int64 = 0 - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return 0, "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_getwarning, implementation_writer.GetDLLInHandle(), UInt32InValue(nIndex), UInt32OutValue(&nErrorCode), Int64InValue(0), Int64OutValue(&neededforWarning), Int64InValue(0)) - if (err != nil) { - return 0, "", err - } - bufferSizeWarning := neededforWarning - bufferWarning := make([]byte, bufferSizeWarning) - err = implementation.CallFunction(implementation.Lib3MF_writer_getwarning, implementation_writer.GetDLLInHandle(), UInt32InValue(nIndex), UInt32OutValue(&nErrorCode), Int64InValue(bufferSizeWarning), Int64OutValue(&filledinWarning), uintptr(unsafe.Pointer(&bufferWarning[0]))) - if (err != nil) { - return 0, "", err - } - - return uint32(nErrorCode), string(bufferWarning[:(filledinWarning-1)]), err -} - -func (implementation *Lib3MFImplementation) Writer_GetWarningCount(Writer Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_getwarningcount, implementation_writer.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) Writer_AddKeyWrappingCallback(Writer Lib3MFHandle, sConsumerID string, pTheCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_addkeywrappingcallback, implementation_writer.GetDLLInHandle(), StringInValue(sConsumerID), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Writer_SetContentEncryptionCallback(Writer Lib3MFHandle, pTheCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_writer, err := implementation.GetWrapperHandle(Writer) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_writer_setcontentencryptioncallback, implementation_writer.GetDLLInHandle(), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_ReadFromFile(Reader Lib3MFHandle, sFilename string) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_readfromfile, implementation_reader.GetDLLInHandle(), StringInValue(sFilename)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_ReadFromBuffer(Reader Lib3MFHandle, Buffer []uint8) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_readfrombuffer, implementation_reader.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_ReadFromCallback(Reader Lib3MFHandle, pTheReadCallback int64, nStreamSize uint64, pTheSeekCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_readfromcallback, implementation_reader.GetDLLInHandle(), 0, UInt64InValue(nStreamSize), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_SetProgressCallback(Reader Lib3MFHandle, pProgressCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_setprogresscallback, implementation_reader.GetDLLInHandle(), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_AddRelationToRead(Reader Lib3MFHandle, sRelationShipType string) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_addrelationtoread, implementation_reader.GetDLLInHandle(), StringInValue(sRelationShipType)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_RemoveRelationToRead(Reader Lib3MFHandle, sRelationShipType string) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_removerelationtoread, implementation_reader.GetDLLInHandle(), StringInValue(sRelationShipType)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_SetStrictModeActive(Reader Lib3MFHandle, bStrictModeActive bool) (error) { - var err error = nil - var nStrictModeActive uint8 = 0 - if (bStrictModeActive) { - nStrictModeActive = 1 - } - - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_setstrictmodeactive, implementation_reader.GetDLLInHandle(), UInt8InValue(nStrictModeActive)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_GetStrictModeActive(Reader Lib3MFHandle) (bool, error) { - var err error = nil - var bStrictModeActive int64 = 0 - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_getstrictmodeactive, implementation_reader.GetDLLInHandle(), Int64OutValue(&bStrictModeActive)) - if (err != nil) { - return false, err - } - - return (bStrictModeActive != 0), err -} - -func (implementation *Lib3MFImplementation) Reader_GetWarning(Reader Lib3MFHandle, nIndex uint32) (uint32, string, error) { - var err error = nil - var nErrorCode uint32 = 0 - var neededforWarning int64 = 0 - var filledinWarning int64 = 0 - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return 0, "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_getwarning, implementation_reader.GetDLLInHandle(), UInt32InValue(nIndex), UInt32OutValue(&nErrorCode), Int64InValue(0), Int64OutValue(&neededforWarning), Int64InValue(0)) - if (err != nil) { - return 0, "", err - } - bufferSizeWarning := neededforWarning - bufferWarning := make([]byte, bufferSizeWarning) - err = implementation.CallFunction(implementation.Lib3MF_reader_getwarning, implementation_reader.GetDLLInHandle(), UInt32InValue(nIndex), UInt32OutValue(&nErrorCode), Int64InValue(bufferSizeWarning), Int64OutValue(&filledinWarning), uintptr(unsafe.Pointer(&bufferWarning[0]))) - if (err != nil) { - return 0, "", err - } - - return uint32(nErrorCode), string(bufferWarning[:(filledinWarning-1)]), err -} - -func (implementation *Lib3MFImplementation) Reader_GetWarningCount(Reader Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_getwarningcount, implementation_reader.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) Reader_AddKeyWrappingCallback(Reader Lib3MFHandle, sConsumerID string, pTheCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_addkeywrappingcallback, implementation_reader.GetDLLInHandle(), StringInValue(sConsumerID), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Reader_SetContentEncryptionCallback(Reader Lib3MFHandle, pTheCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_reader, err := implementation.GetWrapperHandle(Reader) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_reader_setcontentencryptioncallback, implementation_reader.GetDLLInHandle(), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) PackagePart_GetPath(PackagePart Lib3MFHandle) (string, error) { - var err error = nil - var neededforPath int64 = 0 - var filledinPath int64 = 0 - - implementation_packagepart, err := implementation.GetWrapperHandle(PackagePart) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_packagepart_getpath, implementation_packagepart.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPath), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizePath := neededforPath - bufferPath := make([]byte, bufferSizePath) - err = implementation.CallFunction(implementation.Lib3MF_packagepart_getpath, implementation_packagepart.GetDLLInHandle(), Int64InValue(bufferSizePath), Int64OutValue(&filledinPath), uintptr(unsafe.Pointer(&bufferPath[0]))) - if (err != nil) { - return "", err - } - - return string(bufferPath[:(filledinPath-1)]), err -} - -func (implementation *Lib3MFImplementation) PackagePart_SetPath(PackagePart Lib3MFHandle, sPath string) (error) { - var err error = nil - - implementation_packagepart, err := implementation.GetWrapperHandle(PackagePart) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_packagepart_setpath, implementation_packagepart.GetDLLInHandle(), StringInValue(sPath)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Resource_GetResourceID(Resource Lib3MFHandle) (uint32, error) { - var err error = nil - var nUniqueResourceID uint32 = 0 - - implementation_resource, err := implementation.GetWrapperHandle(Resource) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resource_getresourceid, implementation_resource.GetDLLInHandle(), UInt32OutValue(&nUniqueResourceID)) - if (err != nil) { - return 0, err - } - - return uint32(nUniqueResourceID), err -} - -func (implementation *Lib3MFImplementation) Resource_GetUniqueResourceID(Resource Lib3MFHandle) (uint32, error) { - var err error = nil - var nUniqueResourceID uint32 = 0 - - implementation_resource, err := implementation.GetWrapperHandle(Resource) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resource_getuniqueresourceid, implementation_resource.GetDLLInHandle(), UInt32OutValue(&nUniqueResourceID)) - if (err != nil) { - return 0, err - } - - return uint32(nUniqueResourceID), err -} - -func (implementation *Lib3MFImplementation) Resource_PackagePart(Resource Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hPackagePart := implementation.NewHandle() - - implementation_resource, err := implementation.GetWrapperHandle(Resource) - if (err != nil) { - return hPackagePart, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resource_packagepart, implementation_resource.GetDLLInHandle(), hPackagePart.GetDLLOutHandle()) - if (err != nil) { - return hPackagePart, err - } - - return hPackagePart, err -} - -func (implementation *Lib3MFImplementation) Resource_SetPackagePart(Resource Lib3MFHandle, PackagePart Lib3MFHandle) (error) { - var err error = nil - - implementation_resource, err := implementation.GetWrapperHandle(Resource) - if (err != nil) { - return err - } - implementation_packagepart, err := implementation.GetWrapperHandle(PackagePart) - if (err != nil) { - return err - } - - PackagePartDLLHandle := implementation_packagepart.GetDLLInHandle() - if (PackagePartDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_resource_setpackagepart, implementation_resource.GetDLLInHandle(), PackagePartDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Resource_GetModelResourceID(Resource Lib3MFHandle) (uint32, error) { - var err error = nil - var nModelResourceId uint32 = 0 - - implementation_resource, err := implementation.GetWrapperHandle(Resource) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resource_getmodelresourceid, implementation_resource.GetDLLInHandle(), UInt32OutValue(&nModelResourceId)) - if (err != nil) { - return 0, err - } - - return uint32(nModelResourceId), err -} - -func (implementation *Lib3MFImplementation) ResourceIterator_MoveNext(ResourceIterator Lib3MFHandle) (bool, error) { - var err error = nil - var bHasNext int64 = 0 - - implementation_resourceiterator, err := implementation.GetWrapperHandle(ResourceIterator) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourceiterator_movenext, implementation_resourceiterator.GetDLLInHandle(), Int64OutValue(&bHasNext)) - if (err != nil) { - return false, err - } - - return (bHasNext != 0), err -} - -func (implementation *Lib3MFImplementation) ResourceIterator_MovePrevious(ResourceIterator Lib3MFHandle) (bool, error) { - var err error = nil - var bHasPrevious int64 = 0 - - implementation_resourceiterator, err := implementation.GetWrapperHandle(ResourceIterator) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourceiterator_moveprevious, implementation_resourceiterator.GetDLLInHandle(), Int64OutValue(&bHasPrevious)) - if (err != nil) { - return false, err - } - - return (bHasPrevious != 0), err -} - -func (implementation *Lib3MFImplementation) ResourceIterator_GetCurrent(ResourceIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_resourceiterator, err := implementation.GetWrapperHandle(ResourceIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourceiterator_getcurrent, implementation_resourceiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) ResourceIterator_Clone(ResourceIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hOutResourceIterator := implementation.NewHandle() - - implementation_resourceiterator, err := implementation.GetWrapperHandle(ResourceIterator) - if (err != nil) { - return hOutResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourceiterator_clone, implementation_resourceiterator.GetDLLInHandle(), hOutResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hOutResourceIterator, err - } - - return hOutResourceIterator, err -} - -func (implementation *Lib3MFImplementation) ResourceIterator_Count(ResourceIterator Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_resourceiterator, err := implementation.GetWrapperHandle(ResourceIterator) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourceiterator_count, implementation_resourceiterator.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) SliceStackIterator_GetCurrentSliceStack(SliceStackIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_slicestackiterator, err := implementation.GetWrapperHandle(SliceStackIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestackiterator_getcurrentslicestack, implementation_slicestackiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) ObjectIterator_GetCurrentObject(ObjectIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_objectiterator, err := implementation.GetWrapperHandle(ObjectIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_objectiterator_getcurrentobject, implementation_objectiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) MeshObjectIterator_GetCurrentMeshObject(MeshObjectIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_meshobjectiterator, err := implementation.GetWrapperHandle(MeshObjectIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobjectiterator_getcurrentmeshobject, implementation_meshobjectiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) ComponentsObjectIterator_GetCurrentComponentsObject(ComponentsObjectIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_componentsobjectiterator, err := implementation.GetWrapperHandle(ComponentsObjectIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_componentsobjectiterator_getcurrentcomponentsobject, implementation_componentsobjectiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) Texture2DIterator_GetCurrentTexture2D(Texture2DIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_texture2diterator, err := implementation.GetWrapperHandle(Texture2DIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2diterator_getcurrenttexture2d, implementation_texture2diterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroupIterator_GetCurrentBaseMaterialGroup(BaseMaterialGroupIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_basematerialgroupiterator, err := implementation.GetWrapperHandle(BaseMaterialGroupIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroupiterator_getcurrentbasematerialgroup, implementation_basematerialgroupiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) ColorGroupIterator_GetCurrentColorGroup(ColorGroupIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_colorgroupiterator, err := implementation.GetWrapperHandle(ColorGroupIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_colorgroupiterator_getcurrentcolorgroup, implementation_colorgroupiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) Texture2DGroupIterator_GetCurrentTexture2DGroup(Texture2DGroupIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_texture2dgroupiterator, err := implementation.GetWrapperHandle(Texture2DGroupIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroupiterator_getcurrenttexture2dgroup, implementation_texture2dgroupiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) CompositeMaterialsIterator_GetCurrentCompositeMaterials(CompositeMaterialsIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_compositematerialsiterator, err := implementation.GetWrapperHandle(CompositeMaterialsIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_compositematerialsiterator_getcurrentcompositematerials, implementation_compositematerialsiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroupIterator_GetCurrentMultiPropertyGroup(MultiPropertyGroupIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResource := implementation.NewHandle() - - implementation_multipropertygroupiterator, err := implementation.GetWrapperHandle(MultiPropertyGroupIterator) - if (err != nil) { - return hResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroupiterator_getcurrentmultipropertygroup, implementation_multipropertygroupiterator.GetDLLInHandle(), hResource.GetDLLOutHandle()) - if (err != nil) { - return hResource, err - } - - return hResource, err -} - -func (implementation *Lib3MFImplementation) MetaData_GetNameSpace(MetaData Lib3MFHandle) (string, error) { - var err error = nil - var neededforNameSpace int64 = 0 - var filledinNameSpace int64 = 0 - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_getnamespace, implementation_metadata.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforNameSpace), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeNameSpace := neededforNameSpace - bufferNameSpace := make([]byte, bufferSizeNameSpace) - err = implementation.CallFunction(implementation.Lib3MF_metadata_getnamespace, implementation_metadata.GetDLLInHandle(), Int64InValue(bufferSizeNameSpace), Int64OutValue(&filledinNameSpace), uintptr(unsafe.Pointer(&bufferNameSpace[0]))) - if (err != nil) { - return "", err - } - - return string(bufferNameSpace[:(filledinNameSpace-1)]), err -} - -func (implementation *Lib3MFImplementation) MetaData_SetNameSpace(MetaData Lib3MFHandle, sNameSpace string) (error) { - var err error = nil - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_setnamespace, implementation_metadata.GetDLLInHandle(), StringInValue(sNameSpace)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MetaData_GetName(MetaData Lib3MFHandle) (string, error) { - var err error = nil - var neededforName int64 = 0 - var filledinName int64 = 0 - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_getname, implementation_metadata.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforName), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeName := neededforName - bufferName := make([]byte, bufferSizeName) - err = implementation.CallFunction(implementation.Lib3MF_metadata_getname, implementation_metadata.GetDLLInHandle(), Int64InValue(bufferSizeName), Int64OutValue(&filledinName), uintptr(unsafe.Pointer(&bufferName[0]))) - if (err != nil) { - return "", err - } - - return string(bufferName[:(filledinName-1)]), err -} - -func (implementation *Lib3MFImplementation) MetaData_SetName(MetaData Lib3MFHandle, sName string) (error) { - var err error = nil - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_setname, implementation_metadata.GetDLLInHandle(), StringInValue(sName)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MetaData_GetKey(MetaData Lib3MFHandle) (string, error) { - var err error = nil - var neededforKey int64 = 0 - var filledinKey int64 = 0 - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_getkey, implementation_metadata.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforKey), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeKey := neededforKey - bufferKey := make([]byte, bufferSizeKey) - err = implementation.CallFunction(implementation.Lib3MF_metadata_getkey, implementation_metadata.GetDLLInHandle(), Int64InValue(bufferSizeKey), Int64OutValue(&filledinKey), uintptr(unsafe.Pointer(&bufferKey[0]))) - if (err != nil) { - return "", err - } - - return string(bufferKey[:(filledinKey-1)]), err -} - -func (implementation *Lib3MFImplementation) MetaData_GetMustPreserve(MetaData Lib3MFHandle) (bool, error) { - var err error = nil - var bMustPreserve int64 = 0 - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_getmustpreserve, implementation_metadata.GetDLLInHandle(), Int64OutValue(&bMustPreserve)) - if (err != nil) { - return false, err - } - - return (bMustPreserve != 0), err -} - -func (implementation *Lib3MFImplementation) MetaData_SetMustPreserve(MetaData Lib3MFHandle, bMustPreserve bool) (error) { - var err error = nil - var nMustPreserve uint8 = 0 - if (bMustPreserve) { - nMustPreserve = 1 - } - - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_setmustpreserve, implementation_metadata.GetDLLInHandle(), UInt8InValue(nMustPreserve)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MetaData_GetType(MetaData Lib3MFHandle) (string, error) { - var err error = nil - var neededforType int64 = 0 - var filledinType int64 = 0 - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_gettype, implementation_metadata.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforType), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeType := neededforType - bufferType := make([]byte, bufferSizeType) - err = implementation.CallFunction(implementation.Lib3MF_metadata_gettype, implementation_metadata.GetDLLInHandle(), Int64InValue(bufferSizeType), Int64OutValue(&filledinType), uintptr(unsafe.Pointer(&bufferType[0]))) - if (err != nil) { - return "", err - } - - return string(bufferType[:(filledinType-1)]), err -} - -func (implementation *Lib3MFImplementation) MetaData_SetType(MetaData Lib3MFHandle, sType string) (error) { - var err error = nil - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_settype, implementation_metadata.GetDLLInHandle(), StringInValue(sType)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MetaData_GetValue(MetaData Lib3MFHandle) (string, error) { - var err error = nil - var neededforValue int64 = 0 - var filledinValue int64 = 0 - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_getvalue, implementation_metadata.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforValue), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeValue := neededforValue - bufferValue := make([]byte, bufferSizeValue) - err = implementation.CallFunction(implementation.Lib3MF_metadata_getvalue, implementation_metadata.GetDLLInHandle(), Int64InValue(bufferSizeValue), Int64OutValue(&filledinValue), uintptr(unsafe.Pointer(&bufferValue[0]))) - if (err != nil) { - return "", err - } - - return string(bufferValue[:(filledinValue-1)]), err -} - -func (implementation *Lib3MFImplementation) MetaData_SetValue(MetaData Lib3MFHandle, sValue string) (error) { - var err error = nil - - implementation_metadata, err := implementation.GetWrapperHandle(MetaData) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadata_setvalue, implementation_metadata.GetDLLInHandle(), StringInValue(sValue)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MetaDataGroup_GetMetaDataCount(MetaDataGroup Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_metadatagroup, err := implementation.GetWrapperHandle(MetaDataGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadatagroup_getmetadatacount, implementation_metadatagroup.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) MetaDataGroup_GetMetaData(MetaDataGroup Lib3MFHandle, nIndex uint32) (Lib3MFHandle, error) { - var err error = nil - hMetaData := implementation.NewHandle() - - implementation_metadatagroup, err := implementation.GetWrapperHandle(MetaDataGroup) - if (err != nil) { - return hMetaData, err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadatagroup_getmetadata, implementation_metadatagroup.GetDLLInHandle(), UInt32InValue(nIndex), hMetaData.GetDLLOutHandle()) - if (err != nil) { - return hMetaData, err - } - - return hMetaData, err -} - -func (implementation *Lib3MFImplementation) MetaDataGroup_GetMetaDataByKey(MetaDataGroup Lib3MFHandle, sNameSpace string, sName string) (Lib3MFHandle, error) { - var err error = nil - hMetaData := implementation.NewHandle() - - implementation_metadatagroup, err := implementation.GetWrapperHandle(MetaDataGroup) - if (err != nil) { - return hMetaData, err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadatagroup_getmetadatabykey, implementation_metadatagroup.GetDLLInHandle(), StringInValue(sNameSpace), StringInValue(sName), hMetaData.GetDLLOutHandle()) - if (err != nil) { - return hMetaData, err - } - - return hMetaData, err -} - -func (implementation *Lib3MFImplementation) MetaDataGroup_RemoveMetaDataByIndex(MetaDataGroup Lib3MFHandle, nIndex uint32) (error) { - var err error = nil - - implementation_metadatagroup, err := implementation.GetWrapperHandle(MetaDataGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadatagroup_removemetadatabyindex, implementation_metadatagroup.GetDLLInHandle(), UInt32InValue(nIndex)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MetaDataGroup_RemoveMetaData(MetaDataGroup Lib3MFHandle, TheMetaData Lib3MFHandle) (error) { - var err error = nil - - implementation_metadatagroup, err := implementation.GetWrapperHandle(MetaDataGroup) - if (err != nil) { - return err - } - implementation_themetadata, err := implementation.GetWrapperHandle(TheMetaData) - if (err != nil) { - return err - } - - TheMetaDataDLLHandle := implementation_themetadata.GetDLLInHandle() - if (TheMetaDataDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadatagroup_removemetadata, implementation_metadatagroup.GetDLLInHandle(), TheMetaDataDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MetaDataGroup_AddMetaData(MetaDataGroup Lib3MFHandle, sNameSpace string, sName string, sValue string, sType string, bMustPreserve bool) (Lib3MFHandle, error) { - var err error = nil - var nMustPreserve uint8 = 0 - if (bMustPreserve) { - nMustPreserve = 1 - } - - hMetaData := implementation.NewHandle() - - implementation_metadatagroup, err := implementation.GetWrapperHandle(MetaDataGroup) - if (err != nil) { - return hMetaData, err - } - - err = implementation.CallFunction(implementation.Lib3MF_metadatagroup_addmetadata, implementation_metadatagroup.GetDLLInHandle(), StringInValue(sNameSpace), StringInValue(sName), StringInValue(sValue), StringInValue(sType), UInt8InValue(nMustPreserve), hMetaData.GetDLLOutHandle()) - if (err != nil) { - return hMetaData, err - } - - return hMetaData, err -} - -func (implementation *Lib3MFImplementation) Object_GetType(Object Lib3MFHandle) (ELib3MFObjectType, error) { - var err error = nil - var eObjectType uint64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_gettype, implementation_object.GetDLLInHandle(), UInt64OutValue(&eObjectType)) - if (err != nil) { - return 0, err - } - - return ELib3MFObjectType (eObjectType), err -} - -func (implementation *Lib3MFImplementation) Object_SetType(Object Lib3MFHandle, eObjectType ELib3MFObjectType) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_settype, implementation_object.GetDLLInHandle(), uintptr(eObjectType)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_GetName(Object Lib3MFHandle) (string, error) { - var err error = nil - var neededforName int64 = 0 - var filledinName int64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getname, implementation_object.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforName), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeName := neededforName - bufferName := make([]byte, bufferSizeName) - err = implementation.CallFunction(implementation.Lib3MF_object_getname, implementation_object.GetDLLInHandle(), Int64InValue(bufferSizeName), Int64OutValue(&filledinName), uintptr(unsafe.Pointer(&bufferName[0]))) - if (err != nil) { - return "", err - } - - return string(bufferName[:(filledinName-1)]), err -} - -func (implementation *Lib3MFImplementation) Object_SetName(Object Lib3MFHandle, sName string) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_setname, implementation_object.GetDLLInHandle(), StringInValue(sName)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_GetPartNumber(Object Lib3MFHandle) (string, error) { - var err error = nil - var neededforPartNumber int64 = 0 - var filledinPartNumber int64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getpartnumber, implementation_object.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPartNumber), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizePartNumber := neededforPartNumber - bufferPartNumber := make([]byte, bufferSizePartNumber) - err = implementation.CallFunction(implementation.Lib3MF_object_getpartnumber, implementation_object.GetDLLInHandle(), Int64InValue(bufferSizePartNumber), Int64OutValue(&filledinPartNumber), uintptr(unsafe.Pointer(&bufferPartNumber[0]))) - if (err != nil) { - return "", err - } - - return string(bufferPartNumber[:(filledinPartNumber-1)]), err -} - -func (implementation *Lib3MFImplementation) Object_SetPartNumber(Object Lib3MFHandle, sPartNumber string) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_setpartnumber, implementation_object.GetDLLInHandle(), StringInValue(sPartNumber)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_IsMeshObject(Object Lib3MFHandle) (bool, error) { - var err error = nil - var bIsMeshObject int64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_ismeshobject, implementation_object.GetDLLInHandle(), Int64OutValue(&bIsMeshObject)) - if (err != nil) { - return false, err - } - - return (bIsMeshObject != 0), err -} - -func (implementation *Lib3MFImplementation) Object_IsComponentsObject(Object Lib3MFHandle) (bool, error) { - var err error = nil - var bIsComponentsObject int64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_iscomponentsobject, implementation_object.GetDLLInHandle(), Int64OutValue(&bIsComponentsObject)) - if (err != nil) { - return false, err - } - - return (bIsComponentsObject != 0), err -} - -func (implementation *Lib3MFImplementation) Object_IsValid(Object Lib3MFHandle) (bool, error) { - var err error = nil - var bIsValid int64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_isvalid, implementation_object.GetDLLInHandle(), Int64OutValue(&bIsValid)) - if (err != nil) { - return false, err - } - - return (bIsValid != 0), err -} - -func (implementation *Lib3MFImplementation) Object_SetAttachmentAsThumbnail(Object Lib3MFHandle, Attachment Lib3MFHandle) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - AttachmentDLLHandle := implementation_attachment.GetDLLInHandle() - if (AttachmentDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_setattachmentasthumbnail, implementation_object.GetDLLInHandle(), AttachmentDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_GetThumbnailAttachment(Object Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hAttachment := implementation.NewHandle() - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return hAttachment, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getthumbnailattachment, implementation_object.GetDLLInHandle(), hAttachment.GetDLLOutHandle()) - if (err != nil) { - return hAttachment, err - } - - return hAttachment, err -} - -func (implementation *Lib3MFImplementation) Object_ClearThumbnailAttachment(Object Lib3MFHandle) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_clearthumbnailattachment, implementation_object.GetDLLInHandle()) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_GetOutbox(Object Lib3MFHandle) (sLib3MFBox, error) { - var err error = nil - var sOutbox sLib3MFBox - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return sOutbox, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getoutbox, implementation_object.GetDLLInHandle(), 0) - if (err != nil) { - return sOutbox, err - } - - return sOutbox, err -} - -func (implementation *Lib3MFImplementation) Object_GetUUID(Object Lib3MFHandle) (bool, string, error) { - var err error = nil - var bHasUUID int64 = 0 - var neededforUUID int64 = 0 - var filledinUUID int64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return false, "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getuuid, implementation_object.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(0), Int64OutValue(&neededforUUID), Int64InValue(0)) - if (err != nil) { - return false, "", err - } - bufferSizeUUID := neededforUUID - bufferUUID := make([]byte, bufferSizeUUID) - err = implementation.CallFunction(implementation.Lib3MF_object_getuuid, implementation_object.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(bufferSizeUUID), Int64OutValue(&filledinUUID), uintptr(unsafe.Pointer(&bufferUUID[0]))) - if (err != nil) { - return false, "", err - } - - return (bHasUUID != 0), string(bufferUUID[:(filledinUUID-1)]), err -} - -func (implementation *Lib3MFImplementation) Object_SetUUID(Object Lib3MFHandle, sUUID string) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_setuuid, implementation_object.GetDLLInHandle(), StringInValue(sUUID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_GetMetaDataGroup(Object Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hMetaDataGroup := implementation.NewHandle() - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return hMetaDataGroup, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getmetadatagroup, implementation_object.GetDLLInHandle(), hMetaDataGroup.GetDLLOutHandle()) - if (err != nil) { - return hMetaDataGroup, err - } - - return hMetaDataGroup, err -} - -func (implementation *Lib3MFImplementation) Object_SetSlicesMeshResolution(Object Lib3MFHandle, eMeshResolution ELib3MFSlicesMeshResolution) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_setslicesmeshresolution, implementation_object.GetDLLInHandle(), uintptr(eMeshResolution)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_GetSlicesMeshResolution(Object Lib3MFHandle) (ELib3MFSlicesMeshResolution, error) { - var err error = nil - var eMeshResolution uint64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getslicesmeshresolution, implementation_object.GetDLLInHandle(), UInt64OutValue(&eMeshResolution)) - if (err != nil) { - return 0, err - } - - return ELib3MFSlicesMeshResolution (eMeshResolution), err -} - -func (implementation *Lib3MFImplementation) Object_HasSlices(Object Lib3MFHandle, bRecursive bool) (bool, error) { - var err error = nil - var nRecursive uint8 = 0 - if (bRecursive) { - nRecursive = 1 - } - - var bHasSlices int64 = 0 - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_hasslices, implementation_object.GetDLLInHandle(), UInt8InValue(nRecursive), Int64OutValue(&bHasSlices)) - if (err != nil) { - return false, err - } - - return (bHasSlices != 0), err -} - -func (implementation *Lib3MFImplementation) Object_ClearSliceStack(Object Lib3MFHandle) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_clearslicestack, implementation_object.GetDLLInHandle()) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Object_GetSliceStack(Object Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hSliceStackInstance := implementation.NewHandle() - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return hSliceStackInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_getslicestack, implementation_object.GetDLLInHandle(), hSliceStackInstance.GetDLLOutHandle()) - if (err != nil) { - return hSliceStackInstance, err - } - - return hSliceStackInstance, err -} - -func (implementation *Lib3MFImplementation) Object_AssignSliceStack(Object Lib3MFHandle, SliceStackInstance Lib3MFHandle) (error) { - var err error = nil - - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return err - } - implementation_slicestackinstance, err := implementation.GetWrapperHandle(SliceStackInstance) - if (err != nil) { - return err - } - - SliceStackInstanceDLLHandle := implementation_slicestackinstance.GetDLLInHandle() - if (SliceStackInstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_object_assignslicestack, implementation_object.GetDLLInHandle(), SliceStackInstanceDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetVertexCount(MeshObject Lib3MFHandle) (uint32, error) { - var err error = nil - var nVertexCount uint32 = 0 - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_getvertexcount, implementation_meshobject.GetDLLInHandle(), UInt32OutValue(&nVertexCount)) - if (err != nil) { - return 0, err - } - - return uint32(nVertexCount), err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetTriangleCount(MeshObject Lib3MFHandle) (uint32, error) { - var err error = nil - var nVertexCount uint32 = 0 - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_gettrianglecount, implementation_meshobject.GetDLLInHandle(), UInt32OutValue(&nVertexCount)) - if (err != nil) { - return 0, err - } - - return uint32(nVertexCount), err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetVertex(MeshObject Lib3MFHandle, nIndex uint32) (sLib3MFPosition, error) { - var err error = nil - var sCoordinates sLib3MFPosition - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return sCoordinates, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_getvertex, implementation_meshobject.GetDLLInHandle(), UInt32InValue(nIndex), 0) - if (err != nil) { - return sCoordinates, err - } - - return sCoordinates, err -} - -func (implementation *Lib3MFImplementation) MeshObject_SetVertex(MeshObject Lib3MFHandle, nIndex uint32, sCoordinates sLib3MFPosition) (error) { - var err error = nil - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_setvertex, implementation_meshobject.GetDLLInHandle(), UInt32InValue(nIndex), uintptr(unsafe.Pointer(&sCoordinates))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_AddVertex(MeshObject Lib3MFHandle, sCoordinates sLib3MFPosition) (uint32, error) { - var err error = nil - var nNewIndex uint32 = 0 - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_addvertex, implementation_meshobject.GetDLLInHandle(), uintptr(unsafe.Pointer(&sCoordinates)), UInt32OutValue(&nNewIndex)) - if (err != nil) { - return 0, err - } - - return uint32(nNewIndex), err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetVertices(MeshObject Lib3MFHandle) ([]sLib3MFPosition, error) { - var err error = nil - arrayVertices := make([]sLib3MFPosition, 0) - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return make([]sLib3MFPosition, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_getvertices, implementation_meshobject.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFPosition, 0), err - } - err = implementation.CallFunction(implementation.Lib3MF_meshobject_getvertices, implementation_meshobject.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFPosition, 0), err - } - - return arrayVertices, err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetTriangle(MeshObject Lib3MFHandle, nIndex uint32) (sLib3MFTriangle, error) { - var err error = nil - var sIndices sLib3MFTriangle - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return sIndices, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_gettriangle, implementation_meshobject.GetDLLInHandle(), UInt32InValue(nIndex), 0) - if (err != nil) { - return sIndices, err - } - - return sIndices, err -} - -func (implementation *Lib3MFImplementation) MeshObject_SetTriangle(MeshObject Lib3MFHandle, nIndex uint32, sIndices sLib3MFTriangle) (error) { - var err error = nil - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_settriangle, implementation_meshobject.GetDLLInHandle(), UInt32InValue(nIndex), uintptr(unsafe.Pointer(&sIndices))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_AddTriangle(MeshObject Lib3MFHandle, sIndices sLib3MFTriangle) (uint32, error) { - var err error = nil - var nNewIndex uint32 = 0 - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_addtriangle, implementation_meshobject.GetDLLInHandle(), uintptr(unsafe.Pointer(&sIndices)), UInt32OutValue(&nNewIndex)) - if (err != nil) { - return 0, err - } - - return uint32(nNewIndex), err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetTriangleIndices(MeshObject Lib3MFHandle) ([]sLib3MFTriangle, error) { - var err error = nil - arrayIndices := make([]sLib3MFTriangle, 0) - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return make([]sLib3MFTriangle, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_gettriangleindices, implementation_meshobject.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFTriangle, 0), err - } - err = implementation.CallFunction(implementation.Lib3MF_meshobject_gettriangleindices, implementation_meshobject.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFTriangle, 0), err - } - - return arrayIndices, err -} - -func (implementation *Lib3MFImplementation) MeshObject_SetObjectLevelProperty(MeshObject Lib3MFHandle, nUniqueResourceID uint32, nPropertyID uint32) (error) { - var err error = nil - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_setobjectlevelproperty, implementation_meshobject.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), UInt32InValue(nPropertyID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetObjectLevelProperty(MeshObject Lib3MFHandle) (uint32, uint32, bool, error) { - var err error = nil - var nUniqueResourceID uint32 = 0 - var nPropertyID uint32 = 0 - var bHasObjectLevelProperty int64 = 0 - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return 0, 0, false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_getobjectlevelproperty, implementation_meshobject.GetDLLInHandle(), UInt32OutValue(&nUniqueResourceID), UInt32OutValue(&nPropertyID), Int64OutValue(&bHasObjectLevelProperty)) - if (err != nil) { - return 0, 0, false, err - } - - return uint32(nUniqueResourceID), uint32(nPropertyID), (bHasObjectLevelProperty != 0), err -} - -func (implementation *Lib3MFImplementation) MeshObject_SetTriangleProperties(MeshObject Lib3MFHandle, nIndex uint32, sProperties sLib3MFTriangleProperties) (error) { - var err error = nil - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_settriangleproperties, implementation_meshobject.GetDLLInHandle(), UInt32InValue(nIndex), uintptr(unsafe.Pointer(&sProperties))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetTriangleProperties(MeshObject Lib3MFHandle, nIndex uint32) (sLib3MFTriangleProperties, error) { - var err error = nil - var sProperty sLib3MFTriangleProperties - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return sProperty, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_gettriangleproperties, implementation_meshobject.GetDLLInHandle(), UInt32InValue(nIndex), 0) - if (err != nil) { - return sProperty, err - } - - return sProperty, err -} - -func (implementation *Lib3MFImplementation) MeshObject_SetAllTriangleProperties(MeshObject Lib3MFHandle, PropertiesArray []sLib3MFTriangleProperties) (error) { - var err error = nil - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_setalltriangleproperties, implementation_meshobject.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_GetAllTriangleProperties(MeshObject Lib3MFHandle) ([]sLib3MFTriangleProperties, error) { - var err error = nil - arrayPropertiesArray := make([]sLib3MFTriangleProperties, 0) - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return make([]sLib3MFTriangleProperties, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_getalltriangleproperties, implementation_meshobject.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFTriangleProperties, 0), err - } - err = implementation.CallFunction(implementation.Lib3MF_meshobject_getalltriangleproperties, implementation_meshobject.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFTriangleProperties, 0), err - } - - return arrayPropertiesArray, err -} - -func (implementation *Lib3MFImplementation) MeshObject_ClearAllProperties(MeshObject Lib3MFHandle) (error) { - var err error = nil - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_clearallproperties, implementation_meshobject.GetDLLInHandle()) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_SetGeometry(MeshObject Lib3MFHandle, Vertices []sLib3MFPosition, Indices []sLib3MFTriangle) (error) { - var err error = nil - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_setgeometry, implementation_meshobject.GetDLLInHandle(), 0, 0, 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MeshObject_IsManifoldAndOriented(MeshObject Lib3MFHandle) (bool, error) { - var err error = nil - var bIsManifoldAndOriented int64 = 0 - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_ismanifoldandoriented, implementation_meshobject.GetDLLInHandle(), Int64OutValue(&bIsManifoldAndOriented)) - if (err != nil) { - return false, err - } - - return (bIsManifoldAndOriented != 0), err -} - -func (implementation *Lib3MFImplementation) MeshObject_BeamLattice(MeshObject Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hTheBeamLattice := implementation.NewHandle() - - implementation_meshobject, err := implementation.GetWrapperHandle(MeshObject) - if (err != nil) { - return hTheBeamLattice, err - } - - err = implementation.CallFunction(implementation.Lib3MF_meshobject_beamlattice, implementation_meshobject.GetDLLInHandle(), hTheBeamLattice.GetDLLOutHandle()) - if (err != nil) { - return hTheBeamLattice, err - } - - return hTheBeamLattice, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetMinLength(BeamLattice Lib3MFHandle) (float64, error) { - var err error = nil - var dMinLength float64 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getminlength, implementation_beamlattice.GetDLLInHandle(), Float64OutValue(&dMinLength)) - if (err != nil) { - return 0, err - } - - return dMinLength, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetMinLength(BeamLattice Lib3MFHandle, dMinLength float64) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setminlength, implementation_beamlattice.GetDLLInHandle(), Float64InValue(dMinLength)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetClipping(BeamLattice Lib3MFHandle) (ELib3MFBeamLatticeClipMode, uint32, error) { - var err error = nil - var eClipMode uint64 = 0 - var nUniqueResourceID uint32 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getclipping, implementation_beamlattice.GetDLLInHandle(), UInt64OutValue(&eClipMode), UInt32OutValue(&nUniqueResourceID)) - if (err != nil) { - return 0, 0, err - } - - return ELib3MFBeamLatticeClipMode (eClipMode), uint32(nUniqueResourceID), err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetClipping(BeamLattice Lib3MFHandle, eClipMode ELib3MFBeamLatticeClipMode, nUniqueResourceID uint32) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setclipping, implementation_beamlattice.GetDLLInHandle(), uintptr(eClipMode), UInt32InValue(nUniqueResourceID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetRepresentation(BeamLattice Lib3MFHandle) (bool, uint32, error) { - var err error = nil - var bHasRepresentation int64 = 0 - var nUniqueResourceID uint32 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return false, 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getrepresentation, implementation_beamlattice.GetDLLInHandle(), Int64OutValue(&bHasRepresentation), UInt32OutValue(&nUniqueResourceID)) - if (err != nil) { - return false, 0, err - } - - return (bHasRepresentation != 0), uint32(nUniqueResourceID), err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetRepresentation(BeamLattice Lib3MFHandle, nUniqueResourceID uint32) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setrepresentation, implementation_beamlattice.GetDLLInHandle(), UInt32InValue(nUniqueResourceID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBallOptions(BeamLattice Lib3MFHandle) (ELib3MFBeamLatticeBallMode, float64, error) { - var err error = nil - var eBallMode uint64 = 0 - var dBallRadius float64 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getballoptions, implementation_beamlattice.GetDLLInHandle(), UInt64OutValue(&eBallMode), Float64OutValue(&dBallRadius)) - if (err != nil) { - return 0, 0, err - } - - return ELib3MFBeamLatticeBallMode (eBallMode), dBallRadius, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetBallOptions(BeamLattice Lib3MFHandle, eBallMode ELib3MFBeamLatticeBallMode, dBallRadius float64) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setballoptions, implementation_beamlattice.GetDLLInHandle(), uintptr(eBallMode), Float64InValue(dBallRadius)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBeamCount(BeamLattice Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getbeamcount, implementation_beamlattice.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBeam(BeamLattice Lib3MFHandle, nIndex uint32) (sLib3MFBeam, error) { - var err error = nil - var sBeamInfo sLib3MFBeam - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return sBeamInfo, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getbeam, implementation_beamlattice.GetDLLInHandle(), UInt32InValue(nIndex), 0) - if (err != nil) { - return sBeamInfo, err - } - - return sBeamInfo, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_AddBeam(BeamLattice Lib3MFHandle, sBeamInfo sLib3MFBeam) (uint32, error) { - var err error = nil - var nIndex uint32 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_addbeam, implementation_beamlattice.GetDLLInHandle(), uintptr(unsafe.Pointer(&sBeamInfo)), UInt32OutValue(&nIndex)) - if (err != nil) { - return 0, err - } - - return uint32(nIndex), err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetBeam(BeamLattice Lib3MFHandle, nIndex uint32, sBeamInfo sLib3MFBeam) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setbeam, implementation_beamlattice.GetDLLInHandle(), UInt32InValue(nIndex), uintptr(unsafe.Pointer(&sBeamInfo))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetBeams(BeamLattice Lib3MFHandle, BeamInfo []sLib3MFBeam) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setbeams, implementation_beamlattice.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBeams(BeamLattice Lib3MFHandle) ([]sLib3MFBeam, error) { - var err error = nil - arrayBeamInfo := make([]sLib3MFBeam, 0) - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return make([]sLib3MFBeam, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getbeams, implementation_beamlattice.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFBeam, 0), err - } - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getbeams, implementation_beamlattice.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFBeam, 0), err - } - - return arrayBeamInfo, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBallCount(BeamLattice Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getballcount, implementation_beamlattice.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBall(BeamLattice Lib3MFHandle, nIndex uint32) (sLib3MFBall, error) { - var err error = nil - var sBallInfo sLib3MFBall - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return sBallInfo, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getball, implementation_beamlattice.GetDLLInHandle(), UInt32InValue(nIndex), 0) - if (err != nil) { - return sBallInfo, err - } - - return sBallInfo, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_AddBall(BeamLattice Lib3MFHandle, sBallInfo sLib3MFBall) (uint32, error) { - var err error = nil - var nIndex uint32 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_addball, implementation_beamlattice.GetDLLInHandle(), uintptr(unsafe.Pointer(&sBallInfo)), UInt32OutValue(&nIndex)) - if (err != nil) { - return 0, err - } - - return uint32(nIndex), err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetBall(BeamLattice Lib3MFHandle, nIndex uint32, sBallInfo sLib3MFBall) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setball, implementation_beamlattice.GetDLLInHandle(), UInt32InValue(nIndex), uintptr(unsafe.Pointer(&sBallInfo))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_SetBalls(BeamLattice Lib3MFHandle, BallInfo []sLib3MFBall) (error) { - var err error = nil - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_setballs, implementation_beamlattice.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBalls(BeamLattice Lib3MFHandle) ([]sLib3MFBall, error) { - var err error = nil - arrayBallInfo := make([]sLib3MFBall, 0) - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return make([]sLib3MFBall, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getballs, implementation_beamlattice.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFBall, 0), err - } - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getballs, implementation_beamlattice.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFBall, 0), err - } - - return arrayBallInfo, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBeamSetCount(BeamLattice Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getbeamsetcount, implementation_beamlattice.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) BeamLattice_AddBeamSet(BeamLattice Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hBeamSet := implementation.NewHandle() - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return hBeamSet, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_addbeamset, implementation_beamlattice.GetDLLInHandle(), hBeamSet.GetDLLOutHandle()) - if (err != nil) { - return hBeamSet, err - } - - return hBeamSet, err -} - -func (implementation *Lib3MFImplementation) BeamLattice_GetBeamSet(BeamLattice Lib3MFHandle, nIndex uint32) (Lib3MFHandle, error) { - var err error = nil - hBeamSet := implementation.NewHandle() - - implementation_beamlattice, err := implementation.GetWrapperHandle(BeamLattice) - if (err != nil) { - return hBeamSet, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamlattice_getbeamset, implementation_beamlattice.GetDLLInHandle(), UInt32InValue(nIndex), hBeamSet.GetDLLOutHandle()) - if (err != nil) { - return hBeamSet, err - } - - return hBeamSet, err -} - -func (implementation *Lib3MFImplementation) Component_GetObjectResource(Component Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hObjectResource := implementation.NewHandle() - - implementation_component, err := implementation.GetWrapperHandle(Component) - if (err != nil) { - return hObjectResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_component_getobjectresource, implementation_component.GetDLLInHandle(), hObjectResource.GetDLLOutHandle()) - if (err != nil) { - return hObjectResource, err - } - - return hObjectResource, err -} - -func (implementation *Lib3MFImplementation) Component_GetObjectResourceID(Component Lib3MFHandle) (uint32, error) { - var err error = nil - var nUniqueResourceID uint32 = 0 - - implementation_component, err := implementation.GetWrapperHandle(Component) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_component_getobjectresourceid, implementation_component.GetDLLInHandle(), UInt32OutValue(&nUniqueResourceID)) - if (err != nil) { - return 0, err - } - - return uint32(nUniqueResourceID), err -} - -func (implementation *Lib3MFImplementation) Component_GetUUID(Component Lib3MFHandle) (bool, string, error) { - var err error = nil - var bHasUUID int64 = 0 - var neededforUUID int64 = 0 - var filledinUUID int64 = 0 - - implementation_component, err := implementation.GetWrapperHandle(Component) - if (err != nil) { - return false, "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_component_getuuid, implementation_component.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(0), Int64OutValue(&neededforUUID), Int64InValue(0)) - if (err != nil) { - return false, "", err - } - bufferSizeUUID := neededforUUID - bufferUUID := make([]byte, bufferSizeUUID) - err = implementation.CallFunction(implementation.Lib3MF_component_getuuid, implementation_component.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(bufferSizeUUID), Int64OutValue(&filledinUUID), uintptr(unsafe.Pointer(&bufferUUID[0]))) - if (err != nil) { - return false, "", err - } - - return (bHasUUID != 0), string(bufferUUID[:(filledinUUID-1)]), err -} - -func (implementation *Lib3MFImplementation) Component_SetUUID(Component Lib3MFHandle, sUUID string) (error) { - var err error = nil - - implementation_component, err := implementation.GetWrapperHandle(Component) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_component_setuuid, implementation_component.GetDLLInHandle(), StringInValue(sUUID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Component_HasTransform(Component Lib3MFHandle) (bool, error) { - var err error = nil - var bHasTransform int64 = 0 - - implementation_component, err := implementation.GetWrapperHandle(Component) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_component_hastransform, implementation_component.GetDLLInHandle(), Int64OutValue(&bHasTransform)) - if (err != nil) { - return false, err - } - - return (bHasTransform != 0), err -} - -func (implementation *Lib3MFImplementation) Component_GetTransform(Component Lib3MFHandle) (sLib3MFTransform, error) { - var err error = nil - var sTransform sLib3MFTransform - - implementation_component, err := implementation.GetWrapperHandle(Component) - if (err != nil) { - return sTransform, err - } - - err = implementation.CallFunction(implementation.Lib3MF_component_gettransform, implementation_component.GetDLLInHandle(), 0) - if (err != nil) { - return sTransform, err - } - - return sTransform, err -} - -func (implementation *Lib3MFImplementation) Component_SetTransform(Component Lib3MFHandle, sTransform sLib3MFTransform) (error) { - var err error = nil - - implementation_component, err := implementation.GetWrapperHandle(Component) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_component_settransform, implementation_component.GetDLLInHandle(), uintptr(unsafe.Pointer(&sTransform))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) ComponentsObject_AddComponent(ComponentsObject Lib3MFHandle, ObjectResource Lib3MFHandle, sTransform sLib3MFTransform) (Lib3MFHandle, error) { - var err error = nil - hComponentInstance := implementation.NewHandle() - - implementation_componentsobject, err := implementation.GetWrapperHandle(ComponentsObject) - if (err != nil) { - return hComponentInstance, err - } - implementation_objectresource, err := implementation.GetWrapperHandle(ObjectResource) - if (err != nil) { - return hComponentInstance, err - } - - ObjectResourceDLLHandle := implementation_objectresource.GetDLLInHandle() - if (ObjectResourceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hComponentInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_componentsobject_addcomponent, implementation_componentsobject.GetDLLInHandle(), ObjectResourceDLLHandle, uintptr(unsafe.Pointer(&sTransform)), hComponentInstance.GetDLLOutHandle()) - if (err != nil) { - return hComponentInstance, err - } - - return hComponentInstance, err -} - -func (implementation *Lib3MFImplementation) ComponentsObject_GetComponent(ComponentsObject Lib3MFHandle, nIndex uint32) (Lib3MFHandle, error) { - var err error = nil - hComponentInstance := implementation.NewHandle() - - implementation_componentsobject, err := implementation.GetWrapperHandle(ComponentsObject) - if (err != nil) { - return hComponentInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_componentsobject_getcomponent, implementation_componentsobject.GetDLLInHandle(), UInt32InValue(nIndex), hComponentInstance.GetDLLOutHandle()) - if (err != nil) { - return hComponentInstance, err - } - - return hComponentInstance, err -} - -func (implementation *Lib3MFImplementation) ComponentsObject_GetComponentCount(ComponentsObject Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_componentsobject, err := implementation.GetWrapperHandle(ComponentsObject) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_componentsobject_getcomponentcount, implementation_componentsobject.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) BeamSet_SetName(BeamSet Lib3MFHandle, sName string) (error) { - var err error = nil - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_setname, implementation_beamset.GetDLLInHandle(), StringInValue(sName)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamSet_GetName(BeamSet Lib3MFHandle) (string, error) { - var err error = nil - var neededforName int64 = 0 - var filledinName int64 = 0 - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_getname, implementation_beamset.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforName), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeName := neededforName - bufferName := make([]byte, bufferSizeName) - err = implementation.CallFunction(implementation.Lib3MF_beamset_getname, implementation_beamset.GetDLLInHandle(), Int64InValue(bufferSizeName), Int64OutValue(&filledinName), uintptr(unsafe.Pointer(&bufferName[0]))) - if (err != nil) { - return "", err - } - - return string(bufferName[:(filledinName-1)]), err -} - -func (implementation *Lib3MFImplementation) BeamSet_SetIdentifier(BeamSet Lib3MFHandle, sIdentifier string) (error) { - var err error = nil - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_setidentifier, implementation_beamset.GetDLLInHandle(), StringInValue(sIdentifier)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamSet_GetIdentifier(BeamSet Lib3MFHandle) (string, error) { - var err error = nil - var neededforIdentifier int64 = 0 - var filledinIdentifier int64 = 0 - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_getidentifier, implementation_beamset.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforIdentifier), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeIdentifier := neededforIdentifier - bufferIdentifier := make([]byte, bufferSizeIdentifier) - err = implementation.CallFunction(implementation.Lib3MF_beamset_getidentifier, implementation_beamset.GetDLLInHandle(), Int64InValue(bufferSizeIdentifier), Int64OutValue(&filledinIdentifier), uintptr(unsafe.Pointer(&bufferIdentifier[0]))) - if (err != nil) { - return "", err - } - - return string(bufferIdentifier[:(filledinIdentifier-1)]), err -} - -func (implementation *Lib3MFImplementation) BeamSet_GetReferenceCount(BeamSet Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_getreferencecount, implementation_beamset.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) BeamSet_SetReferences(BeamSet Lib3MFHandle, References []uint32) (error) { - var err error = nil - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_setreferences, implementation_beamset.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamSet_GetReferences(BeamSet Lib3MFHandle) ([]uint32, error) { - var err error = nil - var neededforReferences int64 = 0 - var filledinReferences int64 = 0 - bufferReferences := make([]uint32, 0) - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_getreferences, implementation_beamset.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforReferences), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizeReferences := neededforReferences - bufferReferences = make([]uint32, bufferSizeReferences) - err = implementation.CallFunction(implementation.Lib3MF_beamset_getreferences, implementation_beamset.GetDLLInHandle(), Int64InValue(bufferSizeReferences), Int64OutValue(&filledinReferences), uintptr(unsafe.Pointer(&bufferReferences[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferReferences, err -} - -func (implementation *Lib3MFImplementation) BeamSet_GetBallReferenceCount(BeamSet Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_getballreferencecount, implementation_beamset.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) BeamSet_SetBallReferences(BeamSet Lib3MFHandle, BallReferences []uint32) (error) { - var err error = nil - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_setballreferences, implementation_beamset.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BeamSet_GetBallReferences(BeamSet Lib3MFHandle) ([]uint32, error) { - var err error = nil - var neededforBallReferences int64 = 0 - var filledinBallReferences int64 = 0 - bufferBallReferences := make([]uint32, 0) - - implementation_beamset, err := implementation.GetWrapperHandle(BeamSet) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_beamset_getballreferences, implementation_beamset.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforBallReferences), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizeBallReferences := neededforBallReferences - bufferBallReferences = make([]uint32, bufferSizeBallReferences) - err = implementation.CallFunction(implementation.Lib3MF_beamset_getballreferences, implementation_beamset.GetDLLInHandle(), Int64InValue(bufferSizeBallReferences), Int64OutValue(&filledinBallReferences), uintptr(unsafe.Pointer(&bufferBallReferences[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferBallReferences, err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_GetCount(BaseMaterialGroup Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_getcount, implementation_basematerialgroup.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_GetAllPropertyIDs(BaseMaterialGroup Lib3MFHandle) ([]uint32, error) { - var err error = nil - var neededforPropertyIDs int64 = 0 - var filledinPropertyIDs int64 = 0 - bufferPropertyIDs := make([]uint32, 0) - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_getallpropertyids, implementation_basematerialgroup.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPropertyIDs), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizePropertyIDs := neededforPropertyIDs - bufferPropertyIDs = make([]uint32, bufferSizePropertyIDs) - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_getallpropertyids, implementation_basematerialgroup.GetDLLInHandle(), Int64InValue(bufferSizePropertyIDs), Int64OutValue(&filledinPropertyIDs), uintptr(unsafe.Pointer(&bufferPropertyIDs[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferPropertyIDs, err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_AddMaterial(BaseMaterialGroup Lib3MFHandle, sName string, sDisplayColor sLib3MFColor) (uint32, error) { - var err error = nil - var nPropertyID uint32 = 0 - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_addmaterial, implementation_basematerialgroup.GetDLLInHandle(), StringInValue(sName), uintptr(unsafe.Pointer(&sDisplayColor)), UInt32OutValue(&nPropertyID)) - if (err != nil) { - return 0, err - } - - return uint32(nPropertyID), err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_RemoveMaterial(BaseMaterialGroup Lib3MFHandle, nPropertyID uint32) (error) { - var err error = nil - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_removematerial, implementation_basematerialgroup.GetDLLInHandle(), UInt32InValue(nPropertyID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_GetName(BaseMaterialGroup Lib3MFHandle, nPropertyID uint32) (string, error) { - var err error = nil - var neededforName int64 = 0 - var filledinName int64 = 0 - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_getname, implementation_basematerialgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), Int64InValue(0), Int64OutValue(&neededforName), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeName := neededforName - bufferName := make([]byte, bufferSizeName) - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_getname, implementation_basematerialgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), Int64InValue(bufferSizeName), Int64OutValue(&filledinName), uintptr(unsafe.Pointer(&bufferName[0]))) - if (err != nil) { - return "", err - } - - return string(bufferName[:(filledinName-1)]), err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_SetName(BaseMaterialGroup Lib3MFHandle, nPropertyID uint32, sName string) (error) { - var err error = nil - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_setname, implementation_basematerialgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), StringInValue(sName)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_SetDisplayColor(BaseMaterialGroup Lib3MFHandle, nPropertyID uint32, sTheColor sLib3MFColor) (error) { - var err error = nil - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_setdisplaycolor, implementation_basematerialgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), uintptr(unsafe.Pointer(&sTheColor))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BaseMaterialGroup_GetDisplayColor(BaseMaterialGroup Lib3MFHandle, nPropertyID uint32) (sLib3MFColor, error) { - var err error = nil - var sTheColor sLib3MFColor - - implementation_basematerialgroup, err := implementation.GetWrapperHandle(BaseMaterialGroup) - if (err != nil) { - return sTheColor, err - } - - err = implementation.CallFunction(implementation.Lib3MF_basematerialgroup_getdisplaycolor, implementation_basematerialgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), 0) - if (err != nil) { - return sTheColor, err - } - - return sTheColor, err -} - -func (implementation *Lib3MFImplementation) ColorGroup_GetCount(ColorGroup Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_colorgroup, err := implementation.GetWrapperHandle(ColorGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_colorgroup_getcount, implementation_colorgroup.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) ColorGroup_GetAllPropertyIDs(ColorGroup Lib3MFHandle) ([]uint32, error) { - var err error = nil - var neededforPropertyIDs int64 = 0 - var filledinPropertyIDs int64 = 0 - bufferPropertyIDs := make([]uint32, 0) - - implementation_colorgroup, err := implementation.GetWrapperHandle(ColorGroup) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_colorgroup_getallpropertyids, implementation_colorgroup.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPropertyIDs), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizePropertyIDs := neededforPropertyIDs - bufferPropertyIDs = make([]uint32, bufferSizePropertyIDs) - err = implementation.CallFunction(implementation.Lib3MF_colorgroup_getallpropertyids, implementation_colorgroup.GetDLLInHandle(), Int64InValue(bufferSizePropertyIDs), Int64OutValue(&filledinPropertyIDs), uintptr(unsafe.Pointer(&bufferPropertyIDs[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferPropertyIDs, err -} - -func (implementation *Lib3MFImplementation) ColorGroup_AddColor(ColorGroup Lib3MFHandle, sTheColor sLib3MFColor) (uint32, error) { - var err error = nil - var nPropertyID uint32 = 0 - - implementation_colorgroup, err := implementation.GetWrapperHandle(ColorGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_colorgroup_addcolor, implementation_colorgroup.GetDLLInHandle(), uintptr(unsafe.Pointer(&sTheColor)), UInt32OutValue(&nPropertyID)) - if (err != nil) { - return 0, err - } - - return uint32(nPropertyID), err -} - -func (implementation *Lib3MFImplementation) ColorGroup_RemoveColor(ColorGroup Lib3MFHandle, nPropertyID uint32) (error) { - var err error = nil - - implementation_colorgroup, err := implementation.GetWrapperHandle(ColorGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_colorgroup_removecolor, implementation_colorgroup.GetDLLInHandle(), UInt32InValue(nPropertyID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) ColorGroup_SetColor(ColorGroup Lib3MFHandle, nPropertyID uint32, sTheColor sLib3MFColor) (error) { - var err error = nil - - implementation_colorgroup, err := implementation.GetWrapperHandle(ColorGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_colorgroup_setcolor, implementation_colorgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), uintptr(unsafe.Pointer(&sTheColor))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) ColorGroup_GetColor(ColorGroup Lib3MFHandle, nPropertyID uint32) (sLib3MFColor, error) { - var err error = nil - var sTheColor sLib3MFColor - - implementation_colorgroup, err := implementation.GetWrapperHandle(ColorGroup) - if (err != nil) { - return sTheColor, err - } - - err = implementation.CallFunction(implementation.Lib3MF_colorgroup_getcolor, implementation_colorgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), 0) - if (err != nil) { - return sTheColor, err - } - - return sTheColor, err -} - -func (implementation *Lib3MFImplementation) Texture2DGroup_GetCount(Texture2DGroup Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_texture2dgroup, err := implementation.GetWrapperHandle(Texture2DGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroup_getcount, implementation_texture2dgroup.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) Texture2DGroup_GetAllPropertyIDs(Texture2DGroup Lib3MFHandle) ([]uint32, error) { - var err error = nil - var neededforPropertyIDs int64 = 0 - var filledinPropertyIDs int64 = 0 - bufferPropertyIDs := make([]uint32, 0) - - implementation_texture2dgroup, err := implementation.GetWrapperHandle(Texture2DGroup) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroup_getallpropertyids, implementation_texture2dgroup.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPropertyIDs), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizePropertyIDs := neededforPropertyIDs - bufferPropertyIDs = make([]uint32, bufferSizePropertyIDs) - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroup_getallpropertyids, implementation_texture2dgroup.GetDLLInHandle(), Int64InValue(bufferSizePropertyIDs), Int64OutValue(&filledinPropertyIDs), uintptr(unsafe.Pointer(&bufferPropertyIDs[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferPropertyIDs, err -} - -func (implementation *Lib3MFImplementation) Texture2DGroup_AddTex2Coord(Texture2DGroup Lib3MFHandle, sUVCoordinate sLib3MFTex2Coord) (uint32, error) { - var err error = nil - var nPropertyID uint32 = 0 - - implementation_texture2dgroup, err := implementation.GetWrapperHandle(Texture2DGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroup_addtex2coord, implementation_texture2dgroup.GetDLLInHandle(), uintptr(unsafe.Pointer(&sUVCoordinate)), UInt32OutValue(&nPropertyID)) - if (err != nil) { - return 0, err - } - - return uint32(nPropertyID), err -} - -func (implementation *Lib3MFImplementation) Texture2DGroup_GetTex2Coord(Texture2DGroup Lib3MFHandle, nPropertyID uint32) (sLib3MFTex2Coord, error) { - var err error = nil - var sUVCoordinate sLib3MFTex2Coord - - implementation_texture2dgroup, err := implementation.GetWrapperHandle(Texture2DGroup) - if (err != nil) { - return sUVCoordinate, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroup_gettex2coord, implementation_texture2dgroup.GetDLLInHandle(), UInt32InValue(nPropertyID), 0) - if (err != nil) { - return sUVCoordinate, err - } - - return sUVCoordinate, err -} - -func (implementation *Lib3MFImplementation) Texture2DGroup_RemoveTex2Coord(Texture2DGroup Lib3MFHandle, nPropertyID uint32) (error) { - var err error = nil - - implementation_texture2dgroup, err := implementation.GetWrapperHandle(Texture2DGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroup_removetex2coord, implementation_texture2dgroup.GetDLLInHandle(), UInt32InValue(nPropertyID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Texture2DGroup_GetTexture2D(Texture2DGroup Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hTexture2DInstance := implementation.NewHandle() - - implementation_texture2dgroup, err := implementation.GetWrapperHandle(Texture2DGroup) - if (err != nil) { - return hTexture2DInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2dgroup_gettexture2d, implementation_texture2dgroup.GetDLLInHandle(), hTexture2DInstance.GetDLLOutHandle()) - if (err != nil) { - return hTexture2DInstance, err - } - - return hTexture2DInstance, err -} - -func (implementation *Lib3MFImplementation) CompositeMaterials_GetCount(CompositeMaterials Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_compositematerials, err := implementation.GetWrapperHandle(CompositeMaterials) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_getcount, implementation_compositematerials.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) CompositeMaterials_GetAllPropertyIDs(CompositeMaterials Lib3MFHandle) ([]uint32, error) { - var err error = nil - var neededforPropertyIDs int64 = 0 - var filledinPropertyIDs int64 = 0 - bufferPropertyIDs := make([]uint32, 0) - - implementation_compositematerials, err := implementation.GetWrapperHandle(CompositeMaterials) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_getallpropertyids, implementation_compositematerials.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPropertyIDs), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizePropertyIDs := neededforPropertyIDs - bufferPropertyIDs = make([]uint32, bufferSizePropertyIDs) - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_getallpropertyids, implementation_compositematerials.GetDLLInHandle(), Int64InValue(bufferSizePropertyIDs), Int64OutValue(&filledinPropertyIDs), uintptr(unsafe.Pointer(&bufferPropertyIDs[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferPropertyIDs, err -} - -func (implementation *Lib3MFImplementation) CompositeMaterials_GetBaseMaterialGroup(CompositeMaterials Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hBaseMaterialGroupInstance := implementation.NewHandle() - - implementation_compositematerials, err := implementation.GetWrapperHandle(CompositeMaterials) - if (err != nil) { - return hBaseMaterialGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_getbasematerialgroup, implementation_compositematerials.GetDLLInHandle(), hBaseMaterialGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hBaseMaterialGroupInstance, err - } - - return hBaseMaterialGroupInstance, err -} - -func (implementation *Lib3MFImplementation) CompositeMaterials_AddComposite(CompositeMaterials Lib3MFHandle, Composite []sLib3MFCompositeConstituent) (uint32, error) { - var err error = nil - var nPropertyID uint32 = 0 - - implementation_compositematerials, err := implementation.GetWrapperHandle(CompositeMaterials) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_addcomposite, implementation_compositematerials.GetDLLInHandle(), 0, 0, UInt32OutValue(&nPropertyID)) - if (err != nil) { - return 0, err - } - - return uint32(nPropertyID), err -} - -func (implementation *Lib3MFImplementation) CompositeMaterials_RemoveComposite(CompositeMaterials Lib3MFHandle, nPropertyID uint32) (error) { - var err error = nil - - implementation_compositematerials, err := implementation.GetWrapperHandle(CompositeMaterials) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_removecomposite, implementation_compositematerials.GetDLLInHandle(), UInt32InValue(nPropertyID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) CompositeMaterials_GetComposite(CompositeMaterials Lib3MFHandle, nPropertyID uint32) ([]sLib3MFCompositeConstituent, error) { - var err error = nil - arrayComposite := make([]sLib3MFCompositeConstituent, 0) - - implementation_compositematerials, err := implementation.GetWrapperHandle(CompositeMaterials) - if (err != nil) { - return make([]sLib3MFCompositeConstituent, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_getcomposite, implementation_compositematerials.GetDLLInHandle(), UInt32InValue(nPropertyID), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFCompositeConstituent, 0), err - } - err = implementation.CallFunction(implementation.Lib3MF_compositematerials_getcomposite, implementation_compositematerials.GetDLLInHandle(), UInt32InValue(nPropertyID), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFCompositeConstituent, 0), err - } - - return arrayComposite, err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_GetCount(MultiPropertyGroup Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_getcount, implementation_multipropertygroup.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_GetAllPropertyIDs(MultiPropertyGroup Lib3MFHandle) ([]uint32, error) { - var err error = nil - var neededforPropertyIDs int64 = 0 - var filledinPropertyIDs int64 = 0 - bufferPropertyIDs := make([]uint32, 0) - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_getallpropertyids, implementation_multipropertygroup.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPropertyIDs), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizePropertyIDs := neededforPropertyIDs - bufferPropertyIDs = make([]uint32, bufferSizePropertyIDs) - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_getallpropertyids, implementation_multipropertygroup.GetDLLInHandle(), Int64InValue(bufferSizePropertyIDs), Int64OutValue(&filledinPropertyIDs), uintptr(unsafe.Pointer(&bufferPropertyIDs[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferPropertyIDs, err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_AddMultiProperty(MultiPropertyGroup Lib3MFHandle, PropertyIDs []uint32) (uint32, error) { - var err error = nil - var nPropertyID uint32 = 0 - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_addmultiproperty, implementation_multipropertygroup.GetDLLInHandle(), 0, 0, UInt32OutValue(&nPropertyID)) - if (err != nil) { - return 0, err - } - - return uint32(nPropertyID), err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_SetMultiProperty(MultiPropertyGroup Lib3MFHandle, nPropertyID uint32, PropertyIDs []uint32) (error) { - var err error = nil - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_setmultiproperty, implementation_multipropertygroup.GetDLLInHandle(), UInt32InValue(nPropertyID), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_GetMultiProperty(MultiPropertyGroup Lib3MFHandle, nPropertyID uint32) ([]uint32, error) { - var err error = nil - var neededforPropertyIDs int64 = 0 - var filledinPropertyIDs int64 = 0 - bufferPropertyIDs := make([]uint32, 0) - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_getmultiproperty, implementation_multipropertygroup.GetDLLInHandle(), UInt32InValue(nPropertyID), Int64InValue(0), Int64OutValue(&neededforPropertyIDs), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizePropertyIDs := neededforPropertyIDs - bufferPropertyIDs = make([]uint32, bufferSizePropertyIDs) - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_getmultiproperty, implementation_multipropertygroup.GetDLLInHandle(), UInt32InValue(nPropertyID), Int64InValue(bufferSizePropertyIDs), Int64OutValue(&filledinPropertyIDs), uintptr(unsafe.Pointer(&bufferPropertyIDs[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferPropertyIDs, err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_RemoveMultiProperty(MultiPropertyGroup Lib3MFHandle, nPropertyID uint32) (error) { - var err error = nil - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_removemultiproperty, implementation_multipropertygroup.GetDLLInHandle(), UInt32InValue(nPropertyID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_GetLayerCount(MultiPropertyGroup Lib3MFHandle) (uint32, error) { - var err error = nil - var nCount uint32 = 0 - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_getlayercount, implementation_multipropertygroup.GetDLLInHandle(), UInt32OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint32(nCount), err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_AddLayer(MultiPropertyGroup Lib3MFHandle, sTheLayer sLib3MFMultiPropertyLayer) (uint32, error) { - var err error = nil - var nLayerIndex uint32 = 0 - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_addlayer, implementation_multipropertygroup.GetDLLInHandle(), uintptr(unsafe.Pointer(&sTheLayer)), UInt32OutValue(&nLayerIndex)) - if (err != nil) { - return 0, err - } - - return uint32(nLayerIndex), err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_GetLayer(MultiPropertyGroup Lib3MFHandle, nLayerIndex uint32) (sLib3MFMultiPropertyLayer, error) { - var err error = nil - var sTheLayer sLib3MFMultiPropertyLayer - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return sTheLayer, err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_getlayer, implementation_multipropertygroup.GetDLLInHandle(), UInt32InValue(nLayerIndex), 0) - if (err != nil) { - return sTheLayer, err - } - - return sTheLayer, err -} - -func (implementation *Lib3MFImplementation) MultiPropertyGroup_RemoveLayer(MultiPropertyGroup Lib3MFHandle, nLayerIndex uint32) (error) { - var err error = nil - - implementation_multipropertygroup, err := implementation.GetWrapperHandle(MultiPropertyGroup) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_multipropertygroup_removelayer, implementation_multipropertygroup.GetDLLInHandle(), UInt32InValue(nLayerIndex)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Attachment_GetPath(Attachment Lib3MFHandle) (string, error) { - var err error = nil - var neededforPath int64 = 0 - var filledinPath int64 = 0 - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_getpath, implementation_attachment.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPath), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizePath := neededforPath - bufferPath := make([]byte, bufferSizePath) - err = implementation.CallFunction(implementation.Lib3MF_attachment_getpath, implementation_attachment.GetDLLInHandle(), Int64InValue(bufferSizePath), Int64OutValue(&filledinPath), uintptr(unsafe.Pointer(&bufferPath[0]))) - if (err != nil) { - return "", err - } - - return string(bufferPath[:(filledinPath-1)]), err -} - -func (implementation *Lib3MFImplementation) Attachment_SetPath(Attachment Lib3MFHandle, sPath string) (error) { - var err error = nil - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_setpath, implementation_attachment.GetDLLInHandle(), StringInValue(sPath)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Attachment_PackagePart(Attachment Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hPackagePart := implementation.NewHandle() - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return hPackagePart, err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_packagepart, implementation_attachment.GetDLLInHandle(), hPackagePart.GetDLLOutHandle()) - if (err != nil) { - return hPackagePart, err - } - - return hPackagePart, err -} - -func (implementation *Lib3MFImplementation) Attachment_GetRelationShipType(Attachment Lib3MFHandle) (string, error) { - var err error = nil - var neededforPath int64 = 0 - var filledinPath int64 = 0 - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_getrelationshiptype, implementation_attachment.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPath), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizePath := neededforPath - bufferPath := make([]byte, bufferSizePath) - err = implementation.CallFunction(implementation.Lib3MF_attachment_getrelationshiptype, implementation_attachment.GetDLLInHandle(), Int64InValue(bufferSizePath), Int64OutValue(&filledinPath), uintptr(unsafe.Pointer(&bufferPath[0]))) - if (err != nil) { - return "", err - } - - return string(bufferPath[:(filledinPath-1)]), err -} - -func (implementation *Lib3MFImplementation) Attachment_SetRelationShipType(Attachment Lib3MFHandle, sPath string) (error) { - var err error = nil - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_setrelationshiptype, implementation_attachment.GetDLLInHandle(), StringInValue(sPath)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Attachment_WriteToFile(Attachment Lib3MFHandle, sFileName string) (error) { - var err error = nil - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_writetofile, implementation_attachment.GetDLLInHandle(), StringInValue(sFileName)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Attachment_ReadFromFile(Attachment Lib3MFHandle, sFileName string) (error) { - var err error = nil - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_readfromfile, implementation_attachment.GetDLLInHandle(), StringInValue(sFileName)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Attachment_ReadFromCallback(Attachment Lib3MFHandle, pTheReadCallback int64, nStreamSize uint64, pTheSeekCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_readfromcallback, implementation_attachment.GetDLLInHandle(), 0, UInt64InValue(nStreamSize), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Attachment_GetStreamSize(Attachment Lib3MFHandle) (uint64, error) { - var err error = nil - var nStreamSize uint64 = 0 - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_getstreamsize, implementation_attachment.GetDLLInHandle(), UInt64OutValue(&nStreamSize)) - if (err != nil) { - return 0, err - } - - return uint64(nStreamSize), err -} - -func (implementation *Lib3MFImplementation) Attachment_WriteToBuffer(Attachment Lib3MFHandle) ([]uint8, error) { - var err error = nil - var neededforBuffer int64 = 0 - var filledinBuffer int64 = 0 - bufferBuffer := make([]uint8, 0) - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return make([]uint8, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_writetobuffer, implementation_attachment.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforBuffer), Int64InValue(0)) - if (err != nil) { - return make([]uint8, 0), err - } - bufferSizeBuffer := neededforBuffer - bufferBuffer = make([]uint8, bufferSizeBuffer) - err = implementation.CallFunction(implementation.Lib3MF_attachment_writetobuffer, implementation_attachment.GetDLLInHandle(), Int64InValue(bufferSizeBuffer), Int64OutValue(&filledinBuffer), uintptr(unsafe.Pointer(&bufferBuffer[0]))) - if (err != nil) { - return make([]uint8, 0), err - } - - return bufferBuffer, err -} - -func (implementation *Lib3MFImplementation) Attachment_ReadFromBuffer(Attachment Lib3MFHandle, Buffer []uint8) (error) { - var err error = nil - - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_attachment_readfrombuffer, implementation_attachment.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Texture2D_GetAttachment(Texture2D Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hAttachment := implementation.NewHandle() - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return hAttachment, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_getattachment, implementation_texture2d.GetDLLInHandle(), hAttachment.GetDLLOutHandle()) - if (err != nil) { - return hAttachment, err - } - - return hAttachment, err -} - -func (implementation *Lib3MFImplementation) Texture2D_SetAttachment(Texture2D Lib3MFHandle, Attachment Lib3MFHandle) (error) { - var err error = nil - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return err - } - implementation_attachment, err := implementation.GetWrapperHandle(Attachment) - if (err != nil) { - return err - } - - AttachmentDLLHandle := implementation_attachment.GetDLLInHandle() - if (AttachmentDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_setattachment, implementation_texture2d.GetDLLInHandle(), AttachmentDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Texture2D_GetContentType(Texture2D Lib3MFHandle) (ELib3MFTextureType, error) { - var err error = nil - var eContentType uint64 = 0 - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_getcontenttype, implementation_texture2d.GetDLLInHandle(), UInt64OutValue(&eContentType)) - if (err != nil) { - return 0, err - } - - return ELib3MFTextureType (eContentType), err -} - -func (implementation *Lib3MFImplementation) Texture2D_SetContentType(Texture2D Lib3MFHandle, eContentType ELib3MFTextureType) (error) { - var err error = nil - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_setcontenttype, implementation_texture2d.GetDLLInHandle(), uintptr(eContentType)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Texture2D_GetTileStyleUV(Texture2D Lib3MFHandle) (ELib3MFTextureTileStyle, ELib3MFTextureTileStyle, error) { - var err error = nil - var eTileStyleU uint64 = 0 - var eTileStyleV uint64 = 0 - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return 0, 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_gettilestyleuv, implementation_texture2d.GetDLLInHandle(), UInt64OutValue(&eTileStyleU), UInt64OutValue(&eTileStyleV)) - if (err != nil) { - return 0, 0, err - } - - return ELib3MFTextureTileStyle (eTileStyleU), ELib3MFTextureTileStyle (eTileStyleV), err -} - -func (implementation *Lib3MFImplementation) Texture2D_SetTileStyleUV(Texture2D Lib3MFHandle, eTileStyleU ELib3MFTextureTileStyle, eTileStyleV ELib3MFTextureTileStyle) (error) { - var err error = nil - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_settilestyleuv, implementation_texture2d.GetDLLInHandle(), uintptr(eTileStyleU), uintptr(eTileStyleV)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Texture2D_GetFilter(Texture2D Lib3MFHandle) (ELib3MFTextureFilter, error) { - var err error = nil - var eFilter uint64 = 0 - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_getfilter, implementation_texture2d.GetDLLInHandle(), UInt64OutValue(&eFilter)) - if (err != nil) { - return 0, err - } - - return ELib3MFTextureFilter (eFilter), err -} - -func (implementation *Lib3MFImplementation) Texture2D_SetFilter(Texture2D Lib3MFHandle, eFilter ELib3MFTextureFilter) (error) { - var err error = nil - - implementation_texture2d, err := implementation.GetWrapperHandle(Texture2D) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_texture2d_setfilter, implementation_texture2d.GetDLLInHandle(), uintptr(eFilter)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BuildItem_GetObjectResource(BuildItem Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hObjectResource := implementation.NewHandle() - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return hObjectResource, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_getobjectresource, implementation_builditem.GetDLLInHandle(), hObjectResource.GetDLLOutHandle()) - if (err != nil) { - return hObjectResource, err - } - - return hObjectResource, err -} - -func (implementation *Lib3MFImplementation) BuildItem_GetUUID(BuildItem Lib3MFHandle) (bool, string, error) { - var err error = nil - var bHasUUID int64 = 0 - var neededforUUID int64 = 0 - var filledinUUID int64 = 0 - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return false, "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_getuuid, implementation_builditem.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(0), Int64OutValue(&neededforUUID), Int64InValue(0)) - if (err != nil) { - return false, "", err - } - bufferSizeUUID := neededforUUID - bufferUUID := make([]byte, bufferSizeUUID) - err = implementation.CallFunction(implementation.Lib3MF_builditem_getuuid, implementation_builditem.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(bufferSizeUUID), Int64OutValue(&filledinUUID), uintptr(unsafe.Pointer(&bufferUUID[0]))) - if (err != nil) { - return false, "", err - } - - return (bHasUUID != 0), string(bufferUUID[:(filledinUUID-1)]), err -} - -func (implementation *Lib3MFImplementation) BuildItem_SetUUID(BuildItem Lib3MFHandle, sUUID string) (error) { - var err error = nil - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_setuuid, implementation_builditem.GetDLLInHandle(), StringInValue(sUUID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BuildItem_GetObjectResourceID(BuildItem Lib3MFHandle) (uint32, error) { - var err error = nil - var nUniqueResourceID uint32 = 0 - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_getobjectresourceid, implementation_builditem.GetDLLInHandle(), UInt32OutValue(&nUniqueResourceID)) - if (err != nil) { - return 0, err - } - - return uint32(nUniqueResourceID), err -} - -func (implementation *Lib3MFImplementation) BuildItem_HasObjectTransform(BuildItem Lib3MFHandle) (bool, error) { - var err error = nil - var bHasTransform int64 = 0 - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_hasobjecttransform, implementation_builditem.GetDLLInHandle(), Int64OutValue(&bHasTransform)) - if (err != nil) { - return false, err - } - - return (bHasTransform != 0), err -} - -func (implementation *Lib3MFImplementation) BuildItem_GetObjectTransform(BuildItem Lib3MFHandle) (sLib3MFTransform, error) { - var err error = nil - var sTransform sLib3MFTransform - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return sTransform, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_getobjecttransform, implementation_builditem.GetDLLInHandle(), 0) - if (err != nil) { - return sTransform, err - } - - return sTransform, err -} - -func (implementation *Lib3MFImplementation) BuildItem_SetObjectTransform(BuildItem Lib3MFHandle, sTransform sLib3MFTransform) (error) { - var err error = nil - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_setobjecttransform, implementation_builditem.GetDLLInHandle(), uintptr(unsafe.Pointer(&sTransform))) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BuildItem_GetPartNumber(BuildItem Lib3MFHandle) (string, error) { - var err error = nil - var neededforPartNumber int64 = 0 - var filledinPartNumber int64 = 0 - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_getpartnumber, implementation_builditem.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPartNumber), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizePartNumber := neededforPartNumber - bufferPartNumber := make([]byte, bufferSizePartNumber) - err = implementation.CallFunction(implementation.Lib3MF_builditem_getpartnumber, implementation_builditem.GetDLLInHandle(), Int64InValue(bufferSizePartNumber), Int64OutValue(&filledinPartNumber), uintptr(unsafe.Pointer(&bufferPartNumber[0]))) - if (err != nil) { - return "", err - } - - return string(bufferPartNumber[:(filledinPartNumber-1)]), err -} - -func (implementation *Lib3MFImplementation) BuildItem_SetPartNumber(BuildItem Lib3MFHandle, sSetPartnumber string) (error) { - var err error = nil - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_setpartnumber, implementation_builditem.GetDLLInHandle(), StringInValue(sSetPartnumber)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) BuildItem_GetMetaDataGroup(BuildItem Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hMetaDataGroup := implementation.NewHandle() - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return hMetaDataGroup, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_getmetadatagroup, implementation_builditem.GetDLLInHandle(), hMetaDataGroup.GetDLLOutHandle()) - if (err != nil) { - return hMetaDataGroup, err - } - - return hMetaDataGroup, err -} - -func (implementation *Lib3MFImplementation) BuildItem_GetOutbox(BuildItem Lib3MFHandle) (sLib3MFBox, error) { - var err error = nil - var sOutbox sLib3MFBox - - implementation_builditem, err := implementation.GetWrapperHandle(BuildItem) - if (err != nil) { - return sOutbox, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditem_getoutbox, implementation_builditem.GetDLLInHandle(), 0) - if (err != nil) { - return sOutbox, err - } - - return sOutbox, err -} - -func (implementation *Lib3MFImplementation) BuildItemIterator_MoveNext(BuildItemIterator Lib3MFHandle) (bool, error) { - var err error = nil - var bHasNext int64 = 0 - - implementation_builditemiterator, err := implementation.GetWrapperHandle(BuildItemIterator) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditemiterator_movenext, implementation_builditemiterator.GetDLLInHandle(), Int64OutValue(&bHasNext)) - if (err != nil) { - return false, err - } - - return (bHasNext != 0), err -} - -func (implementation *Lib3MFImplementation) BuildItemIterator_MovePrevious(BuildItemIterator Lib3MFHandle) (bool, error) { - var err error = nil - var bHasPrevious int64 = 0 - - implementation_builditemiterator, err := implementation.GetWrapperHandle(BuildItemIterator) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditemiterator_moveprevious, implementation_builditemiterator.GetDLLInHandle(), Int64OutValue(&bHasPrevious)) - if (err != nil) { - return false, err - } - - return (bHasPrevious != 0), err -} - -func (implementation *Lib3MFImplementation) BuildItemIterator_GetCurrent(BuildItemIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hBuildItem := implementation.NewHandle() - - implementation_builditemiterator, err := implementation.GetWrapperHandle(BuildItemIterator) - if (err != nil) { - return hBuildItem, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditemiterator_getcurrent, implementation_builditemiterator.GetDLLInHandle(), hBuildItem.GetDLLOutHandle()) - if (err != nil) { - return hBuildItem, err - } - - return hBuildItem, err -} - -func (implementation *Lib3MFImplementation) BuildItemIterator_Clone(BuildItemIterator Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hOutBuildItemIterator := implementation.NewHandle() - - implementation_builditemiterator, err := implementation.GetWrapperHandle(BuildItemIterator) - if (err != nil) { - return hOutBuildItemIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditemiterator_clone, implementation_builditemiterator.GetDLLInHandle(), hOutBuildItemIterator.GetDLLOutHandle()) - if (err != nil) { - return hOutBuildItemIterator, err - } - - return hOutBuildItemIterator, err -} - -func (implementation *Lib3MFImplementation) BuildItemIterator_Count(BuildItemIterator Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_builditemiterator, err := implementation.GetWrapperHandle(BuildItemIterator) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_builditemiterator_count, implementation_builditemiterator.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) Slice_SetVertices(Slice Lib3MFHandle, Vertices []sLib3MFPosition2D) (error) { - var err error = nil - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_setvertices, implementation_slice.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Slice_GetVertices(Slice Lib3MFHandle) ([]sLib3MFPosition2D, error) { - var err error = nil - arrayVertices := make([]sLib3MFPosition2D, 0) - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return make([]sLib3MFPosition2D, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_getvertices, implementation_slice.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFPosition2D, 0), err - } - err = implementation.CallFunction(implementation.Lib3MF_slice_getvertices, implementation_slice.GetDLLInHandle(), 0, 0, 0) - if (err != nil) { - return make([]sLib3MFPosition2D, 0), err - } - - return arrayVertices, err -} - -func (implementation *Lib3MFImplementation) Slice_GetVertexCount(Slice Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_getvertexcount, implementation_slice.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) Slice_AddPolygon(Slice Lib3MFHandle, Indices []uint32) (uint64, error) { - var err error = nil - var nIndex uint64 = 0 - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_addpolygon, implementation_slice.GetDLLInHandle(), 0, 0, UInt64OutValue(&nIndex)) - if (err != nil) { - return 0, err - } - - return uint64(nIndex), err -} - -func (implementation *Lib3MFImplementation) Slice_GetPolygonCount(Slice Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_getpolygoncount, implementation_slice.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) Slice_SetPolygonIndices(Slice Lib3MFHandle, nIndex uint64, Indices []uint32) (error) { - var err error = nil - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_setpolygonindices, implementation_slice.GetDLLInHandle(), UInt64InValue(nIndex), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Slice_GetPolygonIndices(Slice Lib3MFHandle, nIndex uint64) ([]uint32, error) { - var err error = nil - var neededforIndices int64 = 0 - var filledinIndices int64 = 0 - bufferIndices := make([]uint32, 0) - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return make([]uint32, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_getpolygonindices, implementation_slice.GetDLLInHandle(), UInt64InValue(nIndex), Int64InValue(0), Int64OutValue(&neededforIndices), Int64InValue(0)) - if (err != nil) { - return make([]uint32, 0), err - } - bufferSizeIndices := neededforIndices - bufferIndices = make([]uint32, bufferSizeIndices) - err = implementation.CallFunction(implementation.Lib3MF_slice_getpolygonindices, implementation_slice.GetDLLInHandle(), UInt64InValue(nIndex), Int64InValue(bufferSizeIndices), Int64OutValue(&filledinIndices), uintptr(unsafe.Pointer(&bufferIndices[0]))) - if (err != nil) { - return make([]uint32, 0), err - } - - return bufferIndices, err -} - -func (implementation *Lib3MFImplementation) Slice_GetPolygonIndexCount(Slice Lib3MFHandle, nIndex uint64) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_getpolygonindexcount, implementation_slice.GetDLLInHandle(), UInt64InValue(nIndex), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) Slice_GetZTop(Slice Lib3MFHandle) (float64, error) { - var err error = nil - var dZTop float64 = 0 - - implementation_slice, err := implementation.GetWrapperHandle(Slice) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slice_getztop, implementation_slice.GetDLLInHandle(), Float64OutValue(&dZTop)) - if (err != nil) { - return 0, err - } - - return dZTop, err -} - -func (implementation *Lib3MFImplementation) SliceStack_GetBottomZ(SliceStack Lib3MFHandle) (float64, error) { - var err error = nil - var dZBottom float64 = 0 - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_getbottomz, implementation_slicestack.GetDLLInHandle(), Float64OutValue(&dZBottom)) - if (err != nil) { - return 0, err - } - - return dZBottom, err -} - -func (implementation *Lib3MFImplementation) SliceStack_GetSliceCount(SliceStack Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_getslicecount, implementation_slicestack.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) SliceStack_GetSlice(SliceStack Lib3MFHandle, nSliceIndex uint64) (Lib3MFHandle, error) { - var err error = nil - hTheSlice := implementation.NewHandle() - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return hTheSlice, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_getslice, implementation_slicestack.GetDLLInHandle(), UInt64InValue(nSliceIndex), hTheSlice.GetDLLOutHandle()) - if (err != nil) { - return hTheSlice, err - } - - return hTheSlice, err -} - -func (implementation *Lib3MFImplementation) SliceStack_AddSlice(SliceStack Lib3MFHandle, dZTop float64) (Lib3MFHandle, error) { - var err error = nil - hTheSlice := implementation.NewHandle() - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return hTheSlice, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_addslice, implementation_slicestack.GetDLLInHandle(), Float64InValue(dZTop), hTheSlice.GetDLLOutHandle()) - if (err != nil) { - return hTheSlice, err - } - - return hTheSlice, err -} - -func (implementation *Lib3MFImplementation) SliceStack_GetSliceRefCount(SliceStack Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_getslicerefcount, implementation_slicestack.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) SliceStack_AddSliceStackReference(SliceStack Lib3MFHandle, TheSliceStack Lib3MFHandle) (error) { - var err error = nil - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return err - } - implementation_theslicestack, err := implementation.GetWrapperHandle(TheSliceStack) - if (err != nil) { - return err - } - - TheSliceStackDLLHandle := implementation_theslicestack.GetDLLInHandle() - if (TheSliceStackDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_addslicestackreference, implementation_slicestack.GetDLLInHandle(), TheSliceStackDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) SliceStack_GetSliceStackReference(SliceStack Lib3MFHandle, nSliceRefIndex uint64) (Lib3MFHandle, error) { - var err error = nil - hTheSliceStack := implementation.NewHandle() - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return hTheSliceStack, err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_getslicestackreference, implementation_slicestack.GetDLLInHandle(), UInt64InValue(nSliceRefIndex), hTheSliceStack.GetDLLOutHandle()) - if (err != nil) { - return hTheSliceStack, err - } - - return hTheSliceStack, err -} - -func (implementation *Lib3MFImplementation) SliceStack_CollapseSliceReferences(SliceStack Lib3MFHandle) (error) { - var err error = nil - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_collapseslicereferences, implementation_slicestack.GetDLLInHandle()) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) SliceStack_SetOwnPath(SliceStack Lib3MFHandle, sPath string) (error) { - var err error = nil - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_setownpath, implementation_slicestack.GetDLLInHandle(), StringInValue(sPath)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) SliceStack_GetOwnPath(SliceStack Lib3MFHandle) (string, error) { - var err error = nil - var neededforPath int64 = 0 - var filledinPath int64 = 0 - - implementation_slicestack, err := implementation.GetWrapperHandle(SliceStack) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_slicestack_getownpath, implementation_slicestack.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforPath), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizePath := neededforPath - bufferPath := make([]byte, bufferSizePath) - err = implementation.CallFunction(implementation.Lib3MF_slicestack_getownpath, implementation_slicestack.GetDLLInHandle(), Int64InValue(bufferSizePath), Int64OutValue(&filledinPath), uintptr(unsafe.Pointer(&bufferPath[0]))) - if (err != nil) { - return "", err - } - - return string(bufferPath[:(filledinPath-1)]), err -} - -func (implementation *Lib3MFImplementation) Consumer_GetConsumerID(Consumer Lib3MFHandle) (string, error) { - var err error = nil - var neededforConsumerID int64 = 0 - var filledinConsumerID int64 = 0 - - implementation_consumer, err := implementation.GetWrapperHandle(Consumer) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_consumer_getconsumerid, implementation_consumer.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforConsumerID), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeConsumerID := neededforConsumerID - bufferConsumerID := make([]byte, bufferSizeConsumerID) - err = implementation.CallFunction(implementation.Lib3MF_consumer_getconsumerid, implementation_consumer.GetDLLInHandle(), Int64InValue(bufferSizeConsumerID), Int64OutValue(&filledinConsumerID), uintptr(unsafe.Pointer(&bufferConsumerID[0]))) - if (err != nil) { - return "", err - } - - return string(bufferConsumerID[:(filledinConsumerID-1)]), err -} - -func (implementation *Lib3MFImplementation) Consumer_GetKeyID(Consumer Lib3MFHandle) (string, error) { - var err error = nil - var neededforKeyID int64 = 0 - var filledinKeyID int64 = 0 - - implementation_consumer, err := implementation.GetWrapperHandle(Consumer) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_consumer_getkeyid, implementation_consumer.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforKeyID), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeKeyID := neededforKeyID - bufferKeyID := make([]byte, bufferSizeKeyID) - err = implementation.CallFunction(implementation.Lib3MF_consumer_getkeyid, implementation_consumer.GetDLLInHandle(), Int64InValue(bufferSizeKeyID), Int64OutValue(&filledinKeyID), uintptr(unsafe.Pointer(&bufferKeyID[0]))) - if (err != nil) { - return "", err - } - - return string(bufferKeyID[:(filledinKeyID-1)]), err -} - -func (implementation *Lib3MFImplementation) Consumer_GetKeyValue(Consumer Lib3MFHandle) (string, error) { - var err error = nil - var neededforKeyValue int64 = 0 - var filledinKeyValue int64 = 0 - - implementation_consumer, err := implementation.GetWrapperHandle(Consumer) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_consumer_getkeyvalue, implementation_consumer.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforKeyValue), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeKeyValue := neededforKeyValue - bufferKeyValue := make([]byte, bufferSizeKeyValue) - err = implementation.CallFunction(implementation.Lib3MF_consumer_getkeyvalue, implementation_consumer.GetDLLInHandle(), Int64InValue(bufferSizeKeyValue), Int64OutValue(&filledinKeyValue), uintptr(unsafe.Pointer(&bufferKeyValue[0]))) - if (err != nil) { - return "", err - } - - return string(bufferKeyValue[:(filledinKeyValue-1)]), err -} - -func (implementation *Lib3MFImplementation) AccessRight_GetConsumer(AccessRight Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hConsumer := implementation.NewHandle() - - implementation_accessright, err := implementation.GetWrapperHandle(AccessRight) - if (err != nil) { - return hConsumer, err - } - - err = implementation.CallFunction(implementation.Lib3MF_accessright_getconsumer, implementation_accessright.GetDLLInHandle(), hConsumer.GetDLLOutHandle()) - if (err != nil) { - return hConsumer, err - } - - return hConsumer, err -} - -func (implementation *Lib3MFImplementation) AccessRight_GetWrappingAlgorithm(AccessRight Lib3MFHandle) (ELib3MFWrappingAlgorithm, error) { - var err error = nil - var eAlgorithm uint64 = 0 - - implementation_accessright, err := implementation.GetWrapperHandle(AccessRight) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_accessright_getwrappingalgorithm, implementation_accessright.GetDLLInHandle(), UInt64OutValue(&eAlgorithm)) - if (err != nil) { - return 0, err - } - - return ELib3MFWrappingAlgorithm (eAlgorithm), err -} - -func (implementation *Lib3MFImplementation) AccessRight_GetMgfAlgorithm(AccessRight Lib3MFHandle) (ELib3MFMgfAlgorithm, error) { - var err error = nil - var eAlgorithm uint64 = 0 - - implementation_accessright, err := implementation.GetWrapperHandle(AccessRight) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_accessright_getmgfalgorithm, implementation_accessright.GetDLLInHandle(), UInt64OutValue(&eAlgorithm)) - if (err != nil) { - return 0, err - } - - return ELib3MFMgfAlgorithm (eAlgorithm), err -} - -func (implementation *Lib3MFImplementation) AccessRight_GetDigestMethod(AccessRight Lib3MFHandle) (ELib3MFDigestMethod, error) { - var err error = nil - var eAlgorithm uint64 = 0 - - implementation_accessright, err := implementation.GetWrapperHandle(AccessRight) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_accessright_getdigestmethod, implementation_accessright.GetDLLInHandle(), UInt64OutValue(&eAlgorithm)) - if (err != nil) { - return 0, err - } - - return ELib3MFDigestMethod (eAlgorithm), err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_GetEncryptionAlgorithm(ContentEncryptionParams Lib3MFHandle) (ELib3MFEncryptionAlgorithm, error) { - var err error = nil - var eAlgorithm uint64 = 0 - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getencryptionalgorithm, implementation_contentencryptionparams.GetDLLInHandle(), UInt64OutValue(&eAlgorithm)) - if (err != nil) { - return 0, err - } - - return ELib3MFEncryptionAlgorithm (eAlgorithm), err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_GetKey(ContentEncryptionParams Lib3MFHandle) ([]uint8, error) { - var err error = nil - var neededforByteData int64 = 0 - var filledinByteData int64 = 0 - bufferByteData := make([]uint8, 0) - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return make([]uint8, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getkey, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforByteData), Int64InValue(0)) - if (err != nil) { - return make([]uint8, 0), err - } - bufferSizeByteData := neededforByteData - bufferByteData = make([]uint8, bufferSizeByteData) - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getkey, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(bufferSizeByteData), Int64OutValue(&filledinByteData), uintptr(unsafe.Pointer(&bufferByteData[0]))) - if (err != nil) { - return make([]uint8, 0), err - } - - return bufferByteData, err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_GetInitializationVector(ContentEncryptionParams Lib3MFHandle) ([]uint8, error) { - var err error = nil - var neededforByteData int64 = 0 - var filledinByteData int64 = 0 - bufferByteData := make([]uint8, 0) - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return make([]uint8, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getinitializationvector, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforByteData), Int64InValue(0)) - if (err != nil) { - return make([]uint8, 0), err - } - bufferSizeByteData := neededforByteData - bufferByteData = make([]uint8, bufferSizeByteData) - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getinitializationvector, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(bufferSizeByteData), Int64OutValue(&filledinByteData), uintptr(unsafe.Pointer(&bufferByteData[0]))) - if (err != nil) { - return make([]uint8, 0), err - } - - return bufferByteData, err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_GetAuthenticationTag(ContentEncryptionParams Lib3MFHandle) ([]uint8, error) { - var err error = nil - var neededforByteData int64 = 0 - var filledinByteData int64 = 0 - bufferByteData := make([]uint8, 0) - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return make([]uint8, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getauthenticationtag, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforByteData), Int64InValue(0)) - if (err != nil) { - return make([]uint8, 0), err - } - bufferSizeByteData := neededforByteData - bufferByteData = make([]uint8, bufferSizeByteData) - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getauthenticationtag, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(bufferSizeByteData), Int64OutValue(&filledinByteData), uintptr(unsafe.Pointer(&bufferByteData[0]))) - if (err != nil) { - return make([]uint8, 0), err - } - - return bufferByteData, err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_SetAuthenticationTag(ContentEncryptionParams Lib3MFHandle, ByteData []uint8) (error) { - var err error = nil - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_setauthenticationtag, implementation_contentencryptionparams.GetDLLInHandle(), 0, 0) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_GetAdditionalAuthenticationData(ContentEncryptionParams Lib3MFHandle) ([]uint8, error) { - var err error = nil - var neededforByteData int64 = 0 - var filledinByteData int64 = 0 - bufferByteData := make([]uint8, 0) - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return make([]uint8, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getadditionalauthenticationdata, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforByteData), Int64InValue(0)) - if (err != nil) { - return make([]uint8, 0), err - } - bufferSizeByteData := neededforByteData - bufferByteData = make([]uint8, bufferSizeByteData) - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getadditionalauthenticationdata, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(bufferSizeByteData), Int64OutValue(&filledinByteData), uintptr(unsafe.Pointer(&bufferByteData[0]))) - if (err != nil) { - return make([]uint8, 0), err - } - - return bufferByteData, err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_GetDescriptor(ContentEncryptionParams Lib3MFHandle) (uint64, error) { - var err error = nil - var nDescriptor uint64 = 0 - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getdescriptor, implementation_contentencryptionparams.GetDLLInHandle(), UInt64OutValue(&nDescriptor)) - if (err != nil) { - return 0, err - } - - return uint64(nDescriptor), err -} - -func (implementation *Lib3MFImplementation) ContentEncryptionParams_GetKeyUUID(ContentEncryptionParams Lib3MFHandle) (string, error) { - var err error = nil - var neededforUUID int64 = 0 - var filledinUUID int64 = 0 - - implementation_contentencryptionparams, err := implementation.GetWrapperHandle(ContentEncryptionParams) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getkeyuuid, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforUUID), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeUUID := neededforUUID - bufferUUID := make([]byte, bufferSizeUUID) - err = implementation.CallFunction(implementation.Lib3MF_contentencryptionparams_getkeyuuid, implementation_contentencryptionparams.GetDLLInHandle(), Int64InValue(bufferSizeUUID), Int64OutValue(&filledinUUID), uintptr(unsafe.Pointer(&bufferUUID[0]))) - if (err != nil) { - return "", err - } - - return string(bufferUUID[:(filledinUUID-1)]), err -} - -func (implementation *Lib3MFImplementation) ResourceData_GetPath(ResourceData Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hPath := implementation.NewHandle() - - implementation_resourcedata, err := implementation.GetWrapperHandle(ResourceData) - if (err != nil) { - return hPath, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedata_getpath, implementation_resourcedata.GetDLLInHandle(), hPath.GetDLLOutHandle()) - if (err != nil) { - return hPath, err - } - - return hPath, err -} - -func (implementation *Lib3MFImplementation) ResourceData_GetEncryptionAlgorithm(ResourceData Lib3MFHandle) (ELib3MFEncryptionAlgorithm, error) { - var err error = nil - var eEncryptionAlgorithm uint64 = 0 - - implementation_resourcedata, err := implementation.GetWrapperHandle(ResourceData) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedata_getencryptionalgorithm, implementation_resourcedata.GetDLLInHandle(), UInt64OutValue(&eEncryptionAlgorithm)) - if (err != nil) { - return 0, err - } - - return ELib3MFEncryptionAlgorithm (eEncryptionAlgorithm), err -} - -func (implementation *Lib3MFImplementation) ResourceData_GetCompression(ResourceData Lib3MFHandle) (ELib3MFCompression, error) { - var err error = nil - var eCompression uint64 = 0 - - implementation_resourcedata, err := implementation.GetWrapperHandle(ResourceData) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedata_getcompression, implementation_resourcedata.GetDLLInHandle(), UInt64OutValue(&eCompression)) - if (err != nil) { - return 0, err - } - - return ELib3MFCompression (eCompression), err -} - -func (implementation *Lib3MFImplementation) ResourceData_GetAdditionalAuthenticationData(ResourceData Lib3MFHandle) ([]uint8, error) { - var err error = nil - var neededforByteData int64 = 0 - var filledinByteData int64 = 0 - bufferByteData := make([]uint8, 0) - - implementation_resourcedata, err := implementation.GetWrapperHandle(ResourceData) - if (err != nil) { - return make([]uint8, 0), err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedata_getadditionalauthenticationdata, implementation_resourcedata.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforByteData), Int64InValue(0)) - if (err != nil) { - return make([]uint8, 0), err - } - bufferSizeByteData := neededforByteData - bufferByteData = make([]uint8, bufferSizeByteData) - err = implementation.CallFunction(implementation.Lib3MF_resourcedata_getadditionalauthenticationdata, implementation_resourcedata.GetDLLInHandle(), Int64InValue(bufferSizeByteData), Int64OutValue(&filledinByteData), uintptr(unsafe.Pointer(&bufferByteData[0]))) - if (err != nil) { - return make([]uint8, 0), err - } - - return bufferByteData, err -} - -func (implementation *Lib3MFImplementation) ResourceDataGroup_GetKeyUUID(ResourceDataGroup Lib3MFHandle) (string, error) { - var err error = nil - var neededforUUID int64 = 0 - var filledinUUID int64 = 0 - - implementation_resourcedatagroup, err := implementation.GetWrapperHandle(ResourceDataGroup) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedatagroup_getkeyuuid, implementation_resourcedatagroup.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforUUID), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeUUID := neededforUUID - bufferUUID := make([]byte, bufferSizeUUID) - err = implementation.CallFunction(implementation.Lib3MF_resourcedatagroup_getkeyuuid, implementation_resourcedatagroup.GetDLLInHandle(), Int64InValue(bufferSizeUUID), Int64OutValue(&filledinUUID), uintptr(unsafe.Pointer(&bufferUUID[0]))) - if (err != nil) { - return "", err - } - - return string(bufferUUID[:(filledinUUID-1)]), err -} - -func (implementation *Lib3MFImplementation) ResourceDataGroup_AddAccessRight(ResourceDataGroup Lib3MFHandle, Consumer Lib3MFHandle, eWrappingAlgorithm ELib3MFWrappingAlgorithm, eMgfAlgorithm ELib3MFMgfAlgorithm, eDigestMethod ELib3MFDigestMethod) (Lib3MFHandle, error) { - var err error = nil - hTheAccessRight := implementation.NewHandle() - - implementation_resourcedatagroup, err := implementation.GetWrapperHandle(ResourceDataGroup) - if (err != nil) { - return hTheAccessRight, err - } - implementation_consumer, err := implementation.GetWrapperHandle(Consumer) - if (err != nil) { - return hTheAccessRight, err - } - - ConsumerDLLHandle := implementation_consumer.GetDLLInHandle() - if (ConsumerDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hTheAccessRight, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedatagroup_addaccessright, implementation_resourcedatagroup.GetDLLInHandle(), ConsumerDLLHandle, uintptr(eWrappingAlgorithm), uintptr(eMgfAlgorithm), uintptr(eDigestMethod), hTheAccessRight.GetDLLOutHandle()) - if (err != nil) { - return hTheAccessRight, err - } - - return hTheAccessRight, err -} - -func (implementation *Lib3MFImplementation) ResourceDataGroup_FindAccessRightByConsumer(ResourceDataGroup Lib3MFHandle, Consumer Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hTheAccessRight := implementation.NewHandle() - - implementation_resourcedatagroup, err := implementation.GetWrapperHandle(ResourceDataGroup) - if (err != nil) { - return hTheAccessRight, err - } - implementation_consumer, err := implementation.GetWrapperHandle(Consumer) - if (err != nil) { - return hTheAccessRight, err - } - - ConsumerDLLHandle := implementation_consumer.GetDLLInHandle() - if (ConsumerDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hTheAccessRight, err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedatagroup_findaccessrightbyconsumer, implementation_resourcedatagroup.GetDLLInHandle(), ConsumerDLLHandle, hTheAccessRight.GetDLLOutHandle()) - if (err != nil) { - return hTheAccessRight, err - } - - return hTheAccessRight, err -} - -func (implementation *Lib3MFImplementation) ResourceDataGroup_RemoveAccessRight(ResourceDataGroup Lib3MFHandle, Consumer Lib3MFHandle) (error) { - var err error = nil - - implementation_resourcedatagroup, err := implementation.GetWrapperHandle(ResourceDataGroup) - if (err != nil) { - return err - } - implementation_consumer, err := implementation.GetWrapperHandle(Consumer) - if (err != nil) { - return err - } - - ConsumerDLLHandle := implementation_consumer.GetDLLInHandle() - if (ConsumerDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_resourcedatagroup_removeaccessright, implementation_resourcedatagroup.GetDLLInHandle(), ConsumerDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) KeyStore_AddConsumer(KeyStore Lib3MFHandle, sConsumerID string, sKeyID string, sKeyValue string) (Lib3MFHandle, error) { - var err error = nil - hConsumer := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hConsumer, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_addconsumer, implementation_keystore.GetDLLInHandle(), StringInValue(sConsumerID), StringInValue(sKeyID), StringInValue(sKeyValue), hConsumer.GetDLLOutHandle()) - if (err != nil) { - return hConsumer, err - } - - return hConsumer, err -} - -func (implementation *Lib3MFImplementation) KeyStore_GetConsumerCount(KeyStore Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_getconsumercount, implementation_keystore.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) KeyStore_GetConsumer(KeyStore Lib3MFHandle, nConsumerIndex uint64) (Lib3MFHandle, error) { - var err error = nil - hConsumer := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hConsumer, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_getconsumer, implementation_keystore.GetDLLInHandle(), UInt64InValue(nConsumerIndex), hConsumer.GetDLLOutHandle()) - if (err != nil) { - return hConsumer, err - } - - return hConsumer, err -} - -func (implementation *Lib3MFImplementation) KeyStore_RemoveConsumer(KeyStore Lib3MFHandle, Consumer Lib3MFHandle) (error) { - var err error = nil - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return err - } - implementation_consumer, err := implementation.GetWrapperHandle(Consumer) - if (err != nil) { - return err - } - - ConsumerDLLHandle := implementation_consumer.GetDLLInHandle() - if (ConsumerDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_removeconsumer, implementation_keystore.GetDLLInHandle(), ConsumerDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) KeyStore_FindConsumer(KeyStore Lib3MFHandle, sConsumerID string) (Lib3MFHandle, error) { - var err error = nil - hConsumer := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hConsumer, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_findconsumer, implementation_keystore.GetDLLInHandle(), StringInValue(sConsumerID), hConsumer.GetDLLOutHandle()) - if (err != nil) { - return hConsumer, err - } - - return hConsumer, err -} - -func (implementation *Lib3MFImplementation) KeyStore_GetResourceDataGroupCount(KeyStore Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_getresourcedatagroupcount, implementation_keystore.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) KeyStore_AddResourceDataGroup(KeyStore Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceDataGroup := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hResourceDataGroup, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_addresourcedatagroup, implementation_keystore.GetDLLInHandle(), hResourceDataGroup.GetDLLOutHandle()) - if (err != nil) { - return hResourceDataGroup, err - } - - return hResourceDataGroup, err -} - -func (implementation *Lib3MFImplementation) KeyStore_GetResourceDataGroup(KeyStore Lib3MFHandle, nResourceDataIndex uint64) (Lib3MFHandle, error) { - var err error = nil - hResourceDataGroup := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hResourceDataGroup, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_getresourcedatagroup, implementation_keystore.GetDLLInHandle(), UInt64InValue(nResourceDataIndex), hResourceDataGroup.GetDLLOutHandle()) - if (err != nil) { - return hResourceDataGroup, err - } - - return hResourceDataGroup, err -} - -func (implementation *Lib3MFImplementation) KeyStore_RemoveResourceDataGroup(KeyStore Lib3MFHandle, ResourceDataGroup Lib3MFHandle) (error) { - var err error = nil - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return err - } - implementation_resourcedatagroup, err := implementation.GetWrapperHandle(ResourceDataGroup) - if (err != nil) { - return err - } - - ResourceDataGroupDLLHandle := implementation_resourcedatagroup.GetDLLInHandle() - if (ResourceDataGroupDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_removeresourcedatagroup, implementation_keystore.GetDLLInHandle(), ResourceDataGroupDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) KeyStore_FindResourceDataGroup(KeyStore Lib3MFHandle, PartPath Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceDataGroup := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hResourceDataGroup, err - } - implementation_partpath, err := implementation.GetWrapperHandle(PartPath) - if (err != nil) { - return hResourceDataGroup, err - } - - PartPathDLLHandle := implementation_partpath.GetDLLInHandle() - if (PartPathDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hResourceDataGroup, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_findresourcedatagroup, implementation_keystore.GetDLLInHandle(), PartPathDLLHandle, hResourceDataGroup.GetDLLOutHandle()) - if (err != nil) { - return hResourceDataGroup, err - } - - return hResourceDataGroup, err -} - -func (implementation *Lib3MFImplementation) KeyStore_AddResourceData(KeyStore Lib3MFHandle, ResourceDataGroup Lib3MFHandle, PartPath Lib3MFHandle, eAlgorithm ELib3MFEncryptionAlgorithm, eCompression ELib3MFCompression, AdditionalAuthenticationData []uint8) (Lib3MFHandle, error) { - var err error = nil - hResourceData := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hResourceData, err - } - implementation_resourcedatagroup, err := implementation.GetWrapperHandle(ResourceDataGroup) - if (err != nil) { - return hResourceData, err - } - - ResourceDataGroupDLLHandle := implementation_resourcedatagroup.GetDLLInHandle() - if (ResourceDataGroupDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hResourceData, err - } - implementation_partpath, err := implementation.GetWrapperHandle(PartPath) - if (err != nil) { - return hResourceData, err - } - - PartPathDLLHandle := implementation_partpath.GetDLLInHandle() - if (PartPathDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hResourceData, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_addresourcedata, implementation_keystore.GetDLLInHandle(), ResourceDataGroupDLLHandle, PartPathDLLHandle, uintptr(eAlgorithm), uintptr(eCompression), 0, 0, hResourceData.GetDLLOutHandle()) - if (err != nil) { - return hResourceData, err - } - - return hResourceData, err -} - -func (implementation *Lib3MFImplementation) KeyStore_RemoveResourceData(KeyStore Lib3MFHandle, ResourceData Lib3MFHandle) (error) { - var err error = nil - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return err - } - implementation_resourcedata, err := implementation.GetWrapperHandle(ResourceData) - if (err != nil) { - return err - } - - ResourceDataDLLHandle := implementation_resourcedata.GetDLLInHandle() - if (ResourceDataDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_removeresourcedata, implementation_keystore.GetDLLInHandle(), ResourceDataDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) KeyStore_FindResourceData(KeyStore Lib3MFHandle, ResourcePath Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceData := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hResourceData, err - } - implementation_resourcepath, err := implementation.GetWrapperHandle(ResourcePath) - if (err != nil) { - return hResourceData, err - } - - ResourcePathDLLHandle := implementation_resourcepath.GetDLLInHandle() - if (ResourcePathDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hResourceData, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_findresourcedata, implementation_keystore.GetDLLInHandle(), ResourcePathDLLHandle, hResourceData.GetDLLOutHandle()) - if (err != nil) { - return hResourceData, err - } - - return hResourceData, err -} - -func (implementation *Lib3MFImplementation) KeyStore_GetResourceDataCount(KeyStore Lib3MFHandle) (uint64, error) { - var err error = nil - var nCount uint64 = 0 - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_getresourcedatacount, implementation_keystore.GetDLLInHandle(), UInt64OutValue(&nCount)) - if (err != nil) { - return 0, err - } - - return uint64(nCount), err -} - -func (implementation *Lib3MFImplementation) KeyStore_GetResourceData(KeyStore Lib3MFHandle, nResourceDataIndex uint64) (Lib3MFHandle, error) { - var err error = nil - hResourceData := implementation.NewHandle() - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return hResourceData, err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_getresourcedata, implementation_keystore.GetDLLInHandle(), UInt64InValue(nResourceDataIndex), hResourceData.GetDLLOutHandle()) - if (err != nil) { - return hResourceData, err - } - - return hResourceData, err -} - -func (implementation *Lib3MFImplementation) KeyStore_GetUUID(KeyStore Lib3MFHandle) (bool, string, error) { - var err error = nil - var bHasUUID int64 = 0 - var neededforUUID int64 = 0 - var filledinUUID int64 = 0 - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return false, "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_getuuid, implementation_keystore.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(0), Int64OutValue(&neededforUUID), Int64InValue(0)) - if (err != nil) { - return false, "", err - } - bufferSizeUUID := neededforUUID - bufferUUID := make([]byte, bufferSizeUUID) - err = implementation.CallFunction(implementation.Lib3MF_keystore_getuuid, implementation_keystore.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(bufferSizeUUID), Int64OutValue(&filledinUUID), uintptr(unsafe.Pointer(&bufferUUID[0]))) - if (err != nil) { - return false, "", err - } - - return (bHasUUID != 0), string(bufferUUID[:(filledinUUID-1)]), err -} - -func (implementation *Lib3MFImplementation) KeyStore_SetUUID(KeyStore Lib3MFHandle, sUUID string) (error) { - var err error = nil - - implementation_keystore, err := implementation.GetWrapperHandle(KeyStore) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_keystore_setuuid, implementation_keystore.GetDLLInHandle(), StringInValue(sUUID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_RootModelPart(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hRootModelPart := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hRootModelPart, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_rootmodelpart, implementation_model.GetDLLInHandle(), hRootModelPart.GetDLLOutHandle()) - if (err != nil) { - return hRootModelPart, err - } - - return hRootModelPart, err -} - -func (implementation *Lib3MFImplementation) Model_FindOrCreatePackagePart(Model Lib3MFHandle, sAbsolutePath string) (Lib3MFHandle, error) { - var err error = nil - hModelPart := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hModelPart, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_findorcreatepackagepart, implementation_model.GetDLLInHandle(), StringInValue(sAbsolutePath), hModelPart.GetDLLOutHandle()) - if (err != nil) { - return hModelPart, err - } - - return hModelPart, err -} - -func (implementation *Lib3MFImplementation) Model_SetUnit(Model Lib3MFHandle, eUnit ELib3MFModelUnit) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_setunit, implementation_model.GetDLLInHandle(), uintptr(eUnit)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_GetUnit(Model Lib3MFHandle) (ELib3MFModelUnit, error) { - var err error = nil - var eUnit uint64 = 0 - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getunit, implementation_model.GetDLLInHandle(), UInt64OutValue(&eUnit)) - if (err != nil) { - return 0, err - } - - return ELib3MFModelUnit (eUnit), err -} - -func (implementation *Lib3MFImplementation) Model_GetLanguage(Model Lib3MFHandle) (string, error) { - var err error = nil - var neededforLanguage int64 = 0 - var filledinLanguage int64 = 0 - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getlanguage, implementation_model.GetDLLInHandle(), Int64InValue(0), Int64OutValue(&neededforLanguage), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeLanguage := neededforLanguage - bufferLanguage := make([]byte, bufferSizeLanguage) - err = implementation.CallFunction(implementation.Lib3MF_model_getlanguage, implementation_model.GetDLLInHandle(), Int64InValue(bufferSizeLanguage), Int64OutValue(&filledinLanguage), uintptr(unsafe.Pointer(&bufferLanguage[0]))) - if (err != nil) { - return "", err - } - - return string(bufferLanguage[:(filledinLanguage-1)]), err -} - -func (implementation *Lib3MFImplementation) Model_SetLanguage(Model Lib3MFHandle, sLanguage string) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_setlanguage, implementation_model.GetDLLInHandle(), StringInValue(sLanguage)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_QueryWriter(Model Lib3MFHandle, sWriterClass string) (Lib3MFHandle, error) { - var err error = nil - hWriterInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hWriterInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_querywriter, implementation_model.GetDLLInHandle(), StringInValue(sWriterClass), hWriterInstance.GetDLLOutHandle()) - if (err != nil) { - return hWriterInstance, err - } - - return hWriterInstance, err -} - -func (implementation *Lib3MFImplementation) Model_QueryReader(Model Lib3MFHandle, sReaderClass string) (Lib3MFHandle, error) { - var err error = nil - hReaderInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hReaderInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_queryreader, implementation_model.GetDLLInHandle(), StringInValue(sReaderClass), hReaderInstance.GetDLLOutHandle()) - if (err != nil) { - return hReaderInstance, err - } - - return hReaderInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetTexture2DByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hTextureInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hTextureInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_gettexture2dbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hTextureInstance.GetDLLOutHandle()) - if (err != nil) { - return hTextureInstance, err - } - - return hTextureInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetPropertyTypeByID(Model Lib3MFHandle, nUniqueResourceID uint32) (ELib3MFPropertyType, error) { - var err error = nil - var eThePropertyType uint64 = 0 - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getpropertytypebyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), UInt64OutValue(&eThePropertyType)) - if (err != nil) { - return 0, err - } - - return ELib3MFPropertyType (eThePropertyType), err -} - -func (implementation *Lib3MFImplementation) Model_GetBaseMaterialGroupByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hBaseMaterialGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hBaseMaterialGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getbasematerialgroupbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hBaseMaterialGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hBaseMaterialGroupInstance, err - } - - return hBaseMaterialGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetTexture2DGroupByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hTexture2DGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hTexture2DGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_gettexture2dgroupbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hTexture2DGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hTexture2DGroupInstance, err - } - - return hTexture2DGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetCompositeMaterialsByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hCompositeMaterialsInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hCompositeMaterialsInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getcompositematerialsbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hCompositeMaterialsInstance.GetDLLOutHandle()) - if (err != nil) { - return hCompositeMaterialsInstance, err - } - - return hCompositeMaterialsInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetMultiPropertyGroupByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hMultiPropertyGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hMultiPropertyGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getmultipropertygroupbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hMultiPropertyGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hMultiPropertyGroupInstance, err - } - - return hMultiPropertyGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetMeshObjectByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hMeshObjectInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hMeshObjectInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getmeshobjectbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hMeshObjectInstance.GetDLLOutHandle()) - if (err != nil) { - return hMeshObjectInstance, err - } - - return hMeshObjectInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetComponentsObjectByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hComponentsObjectInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hComponentsObjectInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getcomponentsobjectbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hComponentsObjectInstance.GetDLLOutHandle()) - if (err != nil) { - return hComponentsObjectInstance, err - } - - return hComponentsObjectInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetColorGroupByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hColorGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hColorGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getcolorgroupbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hColorGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hColorGroupInstance, err - } - - return hColorGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetSliceStackByID(Model Lib3MFHandle, nUniqueResourceID uint32) (Lib3MFHandle, error) { - var err error = nil - hSliceStacInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hSliceStacInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getslicestackbyid, implementation_model.GetDLLInHandle(), UInt32InValue(nUniqueResourceID), hSliceStacInstance.GetDLLOutHandle()) - if (err != nil) { - return hSliceStacInstance, err - } - - return hSliceStacInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetBuildUUID(Model Lib3MFHandle) (bool, string, error) { - var err error = nil - var bHasUUID int64 = 0 - var neededforUUID int64 = 0 - var filledinUUID int64 = 0 - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return false, "", err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getbuilduuid, implementation_model.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(0), Int64OutValue(&neededforUUID), Int64InValue(0)) - if (err != nil) { - return false, "", err - } - bufferSizeUUID := neededforUUID - bufferUUID := make([]byte, bufferSizeUUID) - err = implementation.CallFunction(implementation.Lib3MF_model_getbuilduuid, implementation_model.GetDLLInHandle(), Int64OutValue(&bHasUUID), Int64InValue(bufferSizeUUID), Int64OutValue(&filledinUUID), uintptr(unsafe.Pointer(&bufferUUID[0]))) - if (err != nil) { - return false, "", err - } - - return (bHasUUID != 0), string(bufferUUID[:(filledinUUID-1)]), err -} - -func (implementation *Lib3MFImplementation) Model_SetBuildUUID(Model Lib3MFHandle, sUUID string) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_setbuilduuid, implementation_model.GetDLLInHandle(), StringInValue(sUUID)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_GetBuildItems(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hBuildItemIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hBuildItemIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getbuilditems, implementation_model.GetDLLInHandle(), hBuildItemIterator.GetDLLOutHandle()) - if (err != nil) { - return hBuildItemIterator, err - } - - return hBuildItemIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetOutbox(Model Lib3MFHandle) (sLib3MFBox, error) { - var err error = nil - var sOutbox sLib3MFBox - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return sOutbox, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getoutbox, implementation_model.GetDLLInHandle(), 0) - if (err != nil) { - return sOutbox, err - } - - return sOutbox, err -} - -func (implementation *Lib3MFImplementation) Model_GetResources(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getresources, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetObjects(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getobjects, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetMeshObjects(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getmeshobjects, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetComponentsObjects(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getcomponentsobjects, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetTexture2Ds(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_gettexture2ds, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetBaseMaterialGroups(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getbasematerialgroups, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetColorGroups(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getcolorgroups, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetTexture2DGroups(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_gettexture2dgroups, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetCompositeMaterials(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getcompositematerials, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetMultiPropertyGroups(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getmultipropertygroups, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_GetSliceStacks(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hResourceIterator := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hResourceIterator, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getslicestacks, implementation_model.GetDLLInHandle(), hResourceIterator.GetDLLOutHandle()) - if (err != nil) { - return hResourceIterator, err - } - - return hResourceIterator, err -} - -func (implementation *Lib3MFImplementation) Model_MergeToModel(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hMergedModelInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hMergedModelInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_mergetomodel, implementation_model.GetDLLInHandle(), hMergedModelInstance.GetDLLOutHandle()) - if (err != nil) { - return hMergedModelInstance, err - } - - return hMergedModelInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddMeshObject(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hMeshObjectInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hMeshObjectInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addmeshobject, implementation_model.GetDLLInHandle(), hMeshObjectInstance.GetDLLOutHandle()) - if (err != nil) { - return hMeshObjectInstance, err - } - - return hMeshObjectInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddComponentsObject(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hComponentsObjectInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hComponentsObjectInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addcomponentsobject, implementation_model.GetDLLInHandle(), hComponentsObjectInstance.GetDLLOutHandle()) - if (err != nil) { - return hComponentsObjectInstance, err - } - - return hComponentsObjectInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddSliceStack(Model Lib3MFHandle, dZBottom float64) (Lib3MFHandle, error) { - var err error = nil - hSliceStackInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hSliceStackInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addslicestack, implementation_model.GetDLLInHandle(), Float64InValue(dZBottom), hSliceStackInstance.GetDLLOutHandle()) - if (err != nil) { - return hSliceStackInstance, err - } - - return hSliceStackInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddTexture2DFromAttachment(Model Lib3MFHandle, TextureAttachment Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hTexture2DInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hTexture2DInstance, err - } - implementation_textureattachment, err := implementation.GetWrapperHandle(TextureAttachment) - if (err != nil) { - return hTexture2DInstance, err - } - - TextureAttachmentDLLHandle := implementation_textureattachment.GetDLLInHandle() - if (TextureAttachmentDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hTexture2DInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addtexture2dfromattachment, implementation_model.GetDLLInHandle(), TextureAttachmentDLLHandle, hTexture2DInstance.GetDLLOutHandle()) - if (err != nil) { - return hTexture2DInstance, err - } - - return hTexture2DInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddBaseMaterialGroup(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hBaseMaterialGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hBaseMaterialGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addbasematerialgroup, implementation_model.GetDLLInHandle(), hBaseMaterialGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hBaseMaterialGroupInstance, err - } - - return hBaseMaterialGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddColorGroup(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hColorGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hColorGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addcolorgroup, implementation_model.GetDLLInHandle(), hColorGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hColorGroupInstance, err - } - - return hColorGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddTexture2DGroup(Model Lib3MFHandle, Texture2DInstance Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hTexture2DGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hTexture2DGroupInstance, err - } - implementation_texture2dinstance, err := implementation.GetWrapperHandle(Texture2DInstance) - if (err != nil) { - return hTexture2DGroupInstance, err - } - - Texture2DInstanceDLLHandle := implementation_texture2dinstance.GetDLLInHandle() - if (Texture2DInstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hTexture2DGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addtexture2dgroup, implementation_model.GetDLLInHandle(), Texture2DInstanceDLLHandle, hTexture2DGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hTexture2DGroupInstance, err - } - - return hTexture2DGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddCompositeMaterials(Model Lib3MFHandle, BaseMaterialGroupInstance Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hCompositeMaterialsInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hCompositeMaterialsInstance, err - } - implementation_basematerialgroupinstance, err := implementation.GetWrapperHandle(BaseMaterialGroupInstance) - if (err != nil) { - return hCompositeMaterialsInstance, err - } - - BaseMaterialGroupInstanceDLLHandle := implementation_basematerialgroupinstance.GetDLLInHandle() - if (BaseMaterialGroupInstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hCompositeMaterialsInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addcompositematerials, implementation_model.GetDLLInHandle(), BaseMaterialGroupInstanceDLLHandle, hCompositeMaterialsInstance.GetDLLOutHandle()) - if (err != nil) { - return hCompositeMaterialsInstance, err - } - - return hCompositeMaterialsInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddMultiPropertyGroup(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hMultiPropertyGroupInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hMultiPropertyGroupInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addmultipropertygroup, implementation_model.GetDLLInHandle(), hMultiPropertyGroupInstance.GetDLLOutHandle()) - if (err != nil) { - return hMultiPropertyGroupInstance, err - } - - return hMultiPropertyGroupInstance, err -} - -func (implementation *Lib3MFImplementation) Model_AddBuildItem(Model Lib3MFHandle, Object Lib3MFHandle, sTransform sLib3MFTransform) (Lib3MFHandle, error) { - var err error = nil - hBuildItemInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hBuildItemInstance, err - } - implementation_object, err := implementation.GetWrapperHandle(Object) - if (err != nil) { - return hBuildItemInstance, err - } - - ObjectDLLHandle := implementation_object.GetDLLInHandle() - if (ObjectDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return hBuildItemInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addbuilditem, implementation_model.GetDLLInHandle(), ObjectDLLHandle, uintptr(unsafe.Pointer(&sTransform)), hBuildItemInstance.GetDLLOutHandle()) - if (err != nil) { - return hBuildItemInstance, err - } - - return hBuildItemInstance, err -} - -func (implementation *Lib3MFImplementation) Model_RemoveBuildItem(Model Lib3MFHandle, BuildItemInstance Lib3MFHandle) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - implementation_builditeminstance, err := implementation.GetWrapperHandle(BuildItemInstance) - if (err != nil) { - return err - } - - BuildItemInstanceDLLHandle := implementation_builditeminstance.GetDLLInHandle() - if (BuildItemInstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_removebuilditem, implementation_model.GetDLLInHandle(), BuildItemInstanceDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_GetMetaDataGroup(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hTheMetaDataGroup := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hTheMetaDataGroup, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getmetadatagroup, implementation_model.GetDLLInHandle(), hTheMetaDataGroup.GetDLLOutHandle()) - if (err != nil) { - return hTheMetaDataGroup, err - } - - return hTheMetaDataGroup, err -} - -func (implementation *Lib3MFImplementation) Model_AddAttachment(Model Lib3MFHandle, sURI string, sRelationShipType string) (Lib3MFHandle, error) { - var err error = nil - hAttachmentInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hAttachmentInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addattachment, implementation_model.GetDLLInHandle(), StringInValue(sURI), StringInValue(sRelationShipType), hAttachmentInstance.GetDLLOutHandle()) - if (err != nil) { - return hAttachmentInstance, err - } - - return hAttachmentInstance, err -} - -func (implementation *Lib3MFImplementation) Model_RemoveAttachment(Model Lib3MFHandle, AttachmentInstance Lib3MFHandle) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - implementation_attachmentinstance, err := implementation.GetWrapperHandle(AttachmentInstance) - if (err != nil) { - return err - } - - AttachmentInstanceDLLHandle := implementation_attachmentinstance.GetDLLInHandle() - if (AttachmentInstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_removeattachment, implementation_model.GetDLLInHandle(), AttachmentInstanceDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_GetAttachment(Model Lib3MFHandle, nIndex uint32) (Lib3MFHandle, error) { - var err error = nil - hAttachmentInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hAttachmentInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getattachment, implementation_model.GetDLLInHandle(), UInt32InValue(nIndex), hAttachmentInstance.GetDLLOutHandle()) - if (err != nil) { - return hAttachmentInstance, err - } - - return hAttachmentInstance, err -} - -func (implementation *Lib3MFImplementation) Model_FindAttachment(Model Lib3MFHandle, sURI string) (Lib3MFHandle, error) { - var err error = nil - hAttachmentInstance := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hAttachmentInstance, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_findattachment, implementation_model.GetDLLInHandle(), StringInValue(sURI), hAttachmentInstance.GetDLLOutHandle()) - if (err != nil) { - return hAttachmentInstance, err - } - - return hAttachmentInstance, err -} - -func (implementation *Lib3MFImplementation) Model_GetAttachmentCount(Model Lib3MFHandle) (uint32, error) { - var err error = nil - var nAttachmentCount uint32 = 0 - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return 0, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getattachmentcount, implementation_model.GetDLLInHandle(), UInt32OutValue(&nAttachmentCount)) - if (err != nil) { - return 0, err - } - - return uint32(nAttachmentCount), err -} - -func (implementation *Lib3MFImplementation) Model_HasPackageThumbnailAttachment(Model Lib3MFHandle) (bool, error) { - var err error = nil - var bHasThumbnail int64 = 0 - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_haspackagethumbnailattachment, implementation_model.GetDLLInHandle(), Int64OutValue(&bHasThumbnail)) - if (err != nil) { - return false, err - } - - return (bHasThumbnail != 0), err -} - -func (implementation *Lib3MFImplementation) Model_CreatePackageThumbnailAttachment(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hAttachment := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hAttachment, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_createpackagethumbnailattachment, implementation_model.GetDLLInHandle(), hAttachment.GetDLLOutHandle()) - if (err != nil) { - return hAttachment, err - } - - return hAttachment, err -} - -func (implementation *Lib3MFImplementation) Model_GetPackageThumbnailAttachment(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hAttachment := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hAttachment, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getpackagethumbnailattachment, implementation_model.GetDLLInHandle(), hAttachment.GetDLLOutHandle()) - if (err != nil) { - return hAttachment, err - } - - return hAttachment, err -} - -func (implementation *Lib3MFImplementation) Model_RemovePackageThumbnailAttachment(Model Lib3MFHandle) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_removepackagethumbnailattachment, implementation_model.GetDLLInHandle()) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_AddCustomContentType(Model Lib3MFHandle, sExtension string, sContentType string) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_addcustomcontenttype, implementation_model.GetDLLInHandle(), StringInValue(sExtension), StringInValue(sContentType)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_RemoveCustomContentType(Model Lib3MFHandle, sExtension string) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_removecustomcontenttype, implementation_model.GetDLLInHandle(), StringInValue(sExtension)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_SetRandomNumberCallback(Model Lib3MFHandle, pTheCallback int64, nUserData uint64) (error) { - var err error = nil - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_setrandomnumbercallback, implementation_model.GetDLLInHandle(), 0, UInt64InValue(nUserData)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Model_GetKeyStore(Model Lib3MFHandle) (Lib3MFHandle, error) { - var err error = nil - hKeyStore := implementation.NewHandle() - - implementation_model, err := implementation.GetWrapperHandle(Model) - if (err != nil) { - return hKeyStore, err - } - - err = implementation.CallFunction(implementation.Lib3MF_model_getkeystore, implementation_model.GetDLLInHandle(), hKeyStore.GetDLLOutHandle()) - if (err != nil) { - return hKeyStore, err - } - - return hKeyStore, err -} - - -/************************************************************************************************************************* - Class definition Lib3MFWrapper -**************************************************************************************************************************/ -type Lib3MFWrapper struct { - Interface Lib3MFGoInterface -} -func (implementation *Lib3MFImplementation) GetLibraryVersion() (uint32, uint32, uint32, error) { - var err error = nil - var nMajor uint32 = 0 - var nMinor uint32 = 0 - var nMicro uint32 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_getlibraryversion, UInt32OutValue(&nMajor), UInt32OutValue(&nMinor), UInt32OutValue(&nMicro)) - if (err != nil) { - return 0, 0, 0, err - } - - return uint32(nMajor), uint32(nMinor), uint32(nMicro), err -} - -func (implementation *Lib3MFImplementation) GetPrereleaseInformation() (bool, string, error) { - var err error = nil - var bHasPrereleaseInfo int64 = 0 - var neededforPrereleaseInfo int64 = 0 - var filledinPrereleaseInfo int64 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_getprereleaseinformation, Int64OutValue(&bHasPrereleaseInfo), Int64InValue(0), Int64OutValue(&neededforPrereleaseInfo), Int64InValue(0)) - if (err != nil) { - return false, "", err - } - bufferSizePrereleaseInfo := neededforPrereleaseInfo - bufferPrereleaseInfo := make([]byte, bufferSizePrereleaseInfo) - err = implementation.CallFunction(implementation.Lib3MF_getprereleaseinformation, Int64OutValue(&bHasPrereleaseInfo), Int64InValue(bufferSizePrereleaseInfo), Int64OutValue(&filledinPrereleaseInfo), uintptr(unsafe.Pointer(&bufferPrereleaseInfo[0]))) - if (err != nil) { - return false, "", err - } - - return (bHasPrereleaseInfo != 0), string(bufferPrereleaseInfo[:(filledinPrereleaseInfo-1)]), err -} - -func (implementation *Lib3MFImplementation) GetBuildInformation() (bool, string, error) { - var err error = nil - var bHasBuildInfo int64 = 0 - var neededforBuildInformation int64 = 0 - var filledinBuildInformation int64 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_getbuildinformation, Int64OutValue(&bHasBuildInfo), Int64InValue(0), Int64OutValue(&neededforBuildInformation), Int64InValue(0)) - if (err != nil) { - return false, "", err - } - bufferSizeBuildInformation := neededforBuildInformation - bufferBuildInformation := make([]byte, bufferSizeBuildInformation) - err = implementation.CallFunction(implementation.Lib3MF_getbuildinformation, Int64OutValue(&bHasBuildInfo), Int64InValue(bufferSizeBuildInformation), Int64OutValue(&filledinBuildInformation), uintptr(unsafe.Pointer(&bufferBuildInformation[0]))) - if (err != nil) { - return false, "", err - } - - return (bHasBuildInfo != 0), string(bufferBuildInformation[:(filledinBuildInformation-1)]), err -} - -func (implementation *Lib3MFImplementation) GetSpecificationVersion(sSpecificationURL string) (bool, uint32, uint32, uint32, error) { - var err error = nil - var bIsSupported int64 = 0 - var nMajor uint32 = 0 - var nMinor uint32 = 0 - var nMicro uint32 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_getspecificationversion, StringInValue(sSpecificationURL), Int64OutValue(&bIsSupported), UInt32OutValue(&nMajor), UInt32OutValue(&nMinor), UInt32OutValue(&nMicro)) - if (err != nil) { - return false, 0, 0, 0, err - } - - return (bIsSupported != 0), uint32(nMajor), uint32(nMinor), uint32(nMicro), err -} - -func (implementation *Lib3MFImplementation) CreateModel() (Lib3MFHandle, error) { - var err error = nil - hModel := implementation.NewHandle() - - err = implementation.CallFunction(implementation.Lib3MF_createmodel, hModel.GetDLLOutHandle()) - if (err != nil) { - return hModel, err - } - - return hModel, err -} - -func (implementation *Lib3MFImplementation) Release(Instance Lib3MFHandle) (error) { - var err error = nil - implementation_instance, err := implementation.GetWrapperHandle(Instance) - if (err != nil) { - return err - } - - InstanceDLLHandle := implementation_instance.GetDLLInHandle() - if (InstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_release, InstanceDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) Acquire(Instance Lib3MFHandle) (error) { - var err error = nil - implementation_instance, err := implementation.GetWrapperHandle(Instance) - if (err != nil) { - return err - } - - InstanceDLLHandle := implementation_instance.GetDLLInHandle() - if (InstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return err - } - - err = implementation.CallFunction(implementation.Lib3MF_acquire, InstanceDLLHandle) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) SetJournal(sJournalPath string) (error) { - var err error = nil - - err = implementation.CallFunction(implementation.Lib3MF_setjournal, StringInValue(sJournalPath)) - if (err != nil) { - return err - } - - return err -} - -func (implementation *Lib3MFImplementation) GetLastError(Instance Lib3MFHandle) (string, bool, error) { - var err error = nil - var neededforLastErrorString int64 = 0 - var filledinLastErrorString int64 = 0 - var bHasLastError int64 = 0 - implementation_instance, err := implementation.GetWrapperHandle(Instance) - if (err != nil) { - return "", false, err - } - - InstanceDLLHandle := implementation_instance.GetDLLInHandle() - if (InstanceDLLHandle == 0) { - err := fmt.Errorf("Handle must not be 0.") - return "", false, err - } - - err = implementation.CallFunction(implementation.Lib3MF_getlasterror, InstanceDLLHandle, Int64InValue(0), Int64OutValue(&neededforLastErrorString), Int64InValue(0), Int64OutValue(&bHasLastError)) - if (err != nil) { - return "", false, err - } - bufferSizeLastErrorString := neededforLastErrorString - bufferLastErrorString := make([]byte, bufferSizeLastErrorString) - err = implementation.CallFunction(implementation.Lib3MF_getlasterror, InstanceDLLHandle, Int64InValue(bufferSizeLastErrorString), Int64OutValue(&filledinLastErrorString), uintptr(unsafe.Pointer(&bufferLastErrorString[0])), Int64OutValue(&bHasLastError)) - if (err != nil) { - return "", false, err - } - - return string(bufferLastErrorString[:(filledinLastErrorString-1)]), (bHasLastError != 0), err -} - -func (implementation *Lib3MFImplementation) GetSymbolLookupMethod() (uint64, error) { - var err error = nil - var nSymbolLookupMethod uint64 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_getsymbollookupmethod, UInt64OutValue(&nSymbolLookupMethod)) - if (err != nil) { - return 0, err - } - - return nSymbolLookupMethod, err -} - -func (implementation *Lib3MFImplementation) RetrieveProgressMessage(eTheProgressIdentifier ELib3MFProgressIdentifier) (string, error) { - var err error = nil - var neededforProgressMessage int64 = 0 - var filledinProgressMessage int64 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_retrieveprogressmessage, uintptr(eTheProgressIdentifier), Int64InValue(0), Int64OutValue(&neededforProgressMessage), Int64InValue(0)) - if (err != nil) { - return "", err - } - bufferSizeProgressMessage := neededforProgressMessage - bufferProgressMessage := make([]byte, bufferSizeProgressMessage) - err = implementation.CallFunction(implementation.Lib3MF_retrieveprogressmessage, uintptr(eTheProgressIdentifier), Int64InValue(bufferSizeProgressMessage), Int64OutValue(&filledinProgressMessage), uintptr(unsafe.Pointer(&bufferProgressMessage[0]))) - if (err != nil) { - return "", err - } - - return string(bufferProgressMessage[:(filledinProgressMessage-1)]), err -} - -func (implementation *Lib3MFImplementation) RGBAToColor(nRed uint8, nGreen uint8, nBlue uint8, nAlpha uint8) (sLib3MFColor, error) { - var err error = nil - var sTheColor sLib3MFColor - - err = implementation.CallFunction(implementation.Lib3MF_rgbatocolor, UInt8InValue(nRed), UInt8InValue(nGreen), UInt8InValue(nBlue), UInt8InValue(nAlpha), 0) - if (err != nil) { - return sTheColor, err - } - - return sTheColor, err -} - -func (implementation *Lib3MFImplementation) FloatRGBAToColor(fRed float32, fGreen float32, fBlue float32, fAlpha float32) (sLib3MFColor, error) { - var err error = nil - var sTheColor sLib3MFColor - - err = implementation.CallFunction(implementation.Lib3MF_floatrgbatocolor, Float32InValue(fRed), Float32InValue(fGreen), Float32InValue(fBlue), Float32InValue(fAlpha), 0) - if (err != nil) { - return sTheColor, err - } - - return sTheColor, err -} - -func (implementation *Lib3MFImplementation) ColorToRGBA(sTheColor sLib3MFColor) (uint8, uint8, uint8, uint8, error) { - var err error = nil - var nRed uint8 = 0 - var nGreen uint8 = 0 - var nBlue uint8 = 0 - var nAlpha uint8 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_colortorgba, uintptr(unsafe.Pointer(&sTheColor)), UInt8OutValue(&nRed), UInt8OutValue(&nGreen), UInt8OutValue(&nBlue), UInt8OutValue(&nAlpha)) - if (err != nil) { - return 0, 0, 0, 0, err - } - - return uint8(nRed), uint8(nGreen), uint8(nBlue), uint8(nAlpha), err -} - -func (implementation *Lib3MFImplementation) ColorToFloatRGBA(sTheColor sLib3MFColor) (float32, float32, float32, float32, error) { - var err error = nil - var fRed float32 = 0 - var fGreen float32 = 0 - var fBlue float32 = 0 - var fAlpha float32 = 0 - - err = implementation.CallFunction(implementation.Lib3MF_colortofloatrgba, uintptr(unsafe.Pointer(&sTheColor)), Float32OutValue(&fRed), Float32OutValue(&fGreen), Float32OutValue(&fBlue), Float32OutValue(&fAlpha)) - if (err != nil) { - return 0, 0, 0, 0, err - } - - return fRed, fGreen, fBlue, fAlpha, err -} - -func (implementation *Lib3MFImplementation) GetIdentityTransform() (sLib3MFTransform, error) { - var err error = nil - var sTransform sLib3MFTransform - - err = implementation.CallFunction(implementation.Lib3MF_getidentitytransform, 0) - if (err != nil) { - return sTransform, err - } - - return sTransform, err -} - -func (implementation *Lib3MFImplementation) GetUniformScaleTransform(fFactor float32) (sLib3MFTransform, error) { - var err error = nil - var sTransform sLib3MFTransform - - err = implementation.CallFunction(implementation.Lib3MF_getuniformscaletransform, Float32InValue(fFactor), 0) - if (err != nil) { - return sTransform, err - } - - return sTransform, err -} - -func (implementation *Lib3MFImplementation) GetScaleTransform(fFactorX float32, fFactorY float32, fFactorZ float32) (sLib3MFTransform, error) { - var err error = nil - var sTransform sLib3MFTransform - - err = implementation.CallFunction(implementation.Lib3MF_getscaletransform, Float32InValue(fFactorX), Float32InValue(fFactorY), Float32InValue(fFactorZ), 0) - if (err != nil) { - return sTransform, err - } - - return sTransform, err -} - -func (implementation *Lib3MFImplementation) GetTranslationTransform(fVectorX float32, fVectorY float32, fVectorZ float32) (sLib3MFTransform, error) { - var err error = nil - var sTransform sLib3MFTransform - - err = implementation.CallFunction(implementation.Lib3MF_gettranslationtransform, Float32InValue(fVectorX), Float32InValue(fVectorY), Float32InValue(fVectorZ), 0) - if (err != nil) { - return sTransform, err - } - - return sTransform, err -} - - -func (implementation *Lib3MFImplementation) checkBinaryVersion() (error) { - var nBindingMajor uint32 = 2; - var nBindingMinor uint32 = 3; - nMajor, nMinor, _, err := implementation.GetLibraryVersion() - if (err != nil) { - return err; - } - if ( (nMajor != nBindingMajor) || (nMinor < nBindingMinor) ) { - return fmt.Errorf("Lib3MF Error: 25 (%s)", int(0), GetLib3MFErrorMessage(uint32(0))); - } - return nil -} - -func Lib3MFLoadWrapper(DllFileName string) (Lib3MFWrapper, error) { - var Wrapper Lib3MFWrapper; - var Instance Lib3MFImplementation; - - err := Instance.Initialize(DllFileName); - if (err != nil) { - return Wrapper, err; - } - err = Instance.checkBinaryVersion() - if (err != nil) { - return Wrapper, err; - } - Wrapper.Interface = &Instance; - - return Wrapper, nil; -} - diff --git a/CI/Dockerfile.ubuntu b/CI/Dockerfile.ubuntu index 94dec0242..1a4319c9d 100644 --- a/CI/Dockerfile.ubuntu +++ b/CI/Dockerfile.ubuntu @@ -1,10 +1,16 @@ # Copy this to root folder of lib3mf then build and run this image. FROM ubuntu:20.04 -RUN apt-get update && DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get -y install build-essential uuid-dev wget +RUN apt-get update && DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get -y install build-essential uuid-dev wget nano curl RUN wget -qO- "https://cmake.org/files/v3.28/cmake-3.28.1-linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C /usr/local +# Golang +RUN (cd /opt && curl -O -L https://golang.org/dl/go1.17.2.linux-amd64.tar.gz \ + && tar zxvf go1.17.2.linux-amd64.tar.gz) + +ENV PATH="${PATH}:/opt/go/bin" + ADD . lib3mf-repo WORKDIR "/lib3mf-repo" diff --git a/SDK/Examples/Go/Lib3MF_Example.go b/SDK/Examples/Go/Lib3MF_Example.go index be80ce7a0..c1082a584 100644 --- a/SDK/Examples/Go/Lib3MF_Example.go +++ b/SDK/Examples/Go/Lib3MF_Example.go @@ -3,10 +3,10 @@ package main import ( "fmt" "log" - "../../Bindings/Go" + "../Go/go_bindings" ) -func investigateModel(model* lib3mf.Lib3MFModel) { +func investigateModel(model* lib3mf.Model) { { buildItems, err := model.GetBuildItems() if (err != nil) { @@ -69,7 +69,7 @@ func investigateModel(model* lib3mf.Lib3MFModel) { } func main() { - wrapper, err := lib3mf.Lib3MFLoadWrapper("../../Bin/lib3mf.dll") + wrapper, err := lib3mf.LoadLibrary("../../../build/Debug/lib3mf.dll") if (err != nil) { log.Fatal(err) }