public static int cppSetInput_Texture(IntPtr graphHandle, string pInputName, int format, int mipCount, int width, int height, IntPtr pixels) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(-2); } cppSetInput_TextureDelegate function = DLLHelpers.GetFunction( myName, typeof(cppSetInput_TextureDelegate)) as cppSetInput_TextureDelegate; return((int)function.Invoke(graphHandle, pInputName, format, mipCount, width, height, pixels)); }
public static int cppComputeOldFileID(string pCharArray, int pTypeConstant) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppGetOldFileIdDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetOldFileIdDelegate)) as cppGetOldFileIdDelegate; return((int)function.Invoke(pCharArray, pTypeConstant)); }
public static IntPtr cppGetInput_String(IntPtr graphHandle, string pInputName) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(IntPtr.Zero); } cppGetInput_StringDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetInput_StringDelegate)) as cppGetInput_StringDelegate; return((IntPtr)function.Invoke(graphHandle, pInputName)); }
public static uint cppRenderSubstances(bool bAsync, IntPtr preComputeCallback) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppRenderSubstancesDelegate function = DLLHelpers.GetFunction( myName, typeof(cppRenderSubstancesDelegate)) as cppRenderSubstancesDelegate; return((uint)function.Invoke(bAsync, preComputeCallback)); }
public static bool cppIsRendererBusy(uint runid) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(false); } cppIsRendererBusyDelegate function = DLLHelpers.GetFunction( myName, typeof(cppIsRendererBusyDelegate)) as cppIsRendererBusyDelegate; return((bool)function.Invoke(runid)); }
public static IntPtr cppGetOutputChannelStrFromHash(string pAssetPath, UInt32 outputHash) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(IntPtr.Zero); } cppGetOutputChannelStrFromHashDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetOutputChannelStrFromHashDelegate)) as cppGetOutputChannelStrFromHashDelegate; return((IntPtr)function.Invoke(pAssetPath, outputHash)); }
public static void cppRemoveGraphInstance(IntPtr graphHandle) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppRemoveGraphInstanceDelegate function = DLLHelpers.GetFunction( myName, typeof(cppRemoveGraphInstanceDelegate)) as cppRemoveGraphInstanceDelegate; function.Invoke(graphHandle); }
public static void cppFreeMemory(IntPtr pointer) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppFreeMemoryDelegate function = DLLHelpers.GetFunction( myName, typeof(cppFreeMemoryDelegate)) as cppFreeMemoryDelegate; function.Invoke(pointer); }
public static void cppSetCreateSubstanceGraphCallbackEditorPtr(IntPtr fp) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppSetCreateSubstanceGraphCallbackEditorPtrDelegate function = DLLHelpers.GetFunction( myName, typeof(cppSetCreateSubstanceGraphCallbackEditorPtrDelegate)) as cppSetCreateSubstanceGraphCallbackEditorPtrDelegate; function.Invoke(fp); }
public static IntPtr cppListAssets() { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(IntPtr.Zero); } cppListAssetsDelegate function = DLLHelpers.GetFunction( myName, typeof(cppListAssetsDelegate)) as cppListAssetsDelegate; return((IntPtr)function.Invoke()); }
public static int cppGetNumMainTextures(IntPtr graphHandle) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppGetNumMainTexturesDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetNumMainTexturesDelegate)) as cppGetNumMainTexturesDelegate; return((int)function.Invoke(graphHandle)); }
public static void cppApplyPreset(IntPtr graphHandle, string presetStr) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppApplyPresetDelegate function = DLLHelpers.GetFunction( myName, typeof(cppApplyPresetDelegate)) as cppApplyPresetDelegate; function.Invoke(graphHandle, presetStr); }
public static bool cppCheckDimensions(IntPtr pGraphHandle) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(false); } cppCheckDimensionsDelegate function = DLLHelpers.GetFunction( myName, typeof(cppCheckDimensionsDelegate)) as cppCheckDimensionsDelegate; return(function.Invoke(pGraphHandle)); }
public static void cppSetCallbacks(IntPtr log, IntPtr texture, IntPtr numerical, IntPtr graphInitialized) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppSetCallbacksDelegate function = DLLHelpers.GetFunction( myName, typeof(cppSetCallbacksDelegate)) as cppSetCallbacksDelegate; function.Invoke(log, texture, numerical, graphInitialized); }
public static int cppProcessQueuedOutputs() { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppProcessQueuedOutputsDelegate function = DLLHelpers.GetFunction( myName, typeof(cppProcessQueuedOutputsDelegate)) as cppProcessQueuedOutputsDelegate; return((int)function.Invoke()); }
public static IntPtr cppGetOutputsDesc(IntPtr graphHandle, ref int pNumOutputs) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(IntPtr.Zero); } cppGetOutputsDescDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetOutputsDescDelegate)) as cppGetOutputsDescDelegate; return((IntPtr)function.Invoke(graphHandle, ref pNumOutputs)); }
public static bool cppIsImageOutputFromHash(string pAssetPath, UInt32 outputHash) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(false); } cppIsImageOutputFromHashDelegate function = DLLHelpers.GetFunction( myName, typeof(cppIsImageOutputFromHashDelegate)) as cppIsImageOutputFromHashDelegate; return((bool)function.Invoke(pAssetPath, outputHash)); }
public static int cppMoveAsset(string pFromAssetPath, string pToAssetPath) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppMoveAssetDelegate function = DLLHelpers.GetFunction( myName, typeof(cppMoveAssetDelegate)) as cppMoveAssetDelegate; return((int)function.Invoke(pFromAssetPath, pToAssetPath)); }
public static void cppOnGenerateMipMapsChanged(IntPtr graphHandle, bool bGenerateMipMaps) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppOnGenerateMipMapsChangedDelegate function = DLLHelpers.GetFunction( myName, typeof(cppOnGenerateMipMapsChangedDelegate)) as cppOnGenerateMipMapsChangedDelegate; function.Invoke(graphHandle, bGenerateMipMaps); }
public static void cppSetInput_Int(IntPtr graphHandle, string pInputName, int[] values, UInt32 numValues) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppSetInput_IntDelegate function = DLLHelpers.GetFunction( myName, typeof(cppSetInput_IntDelegate)) as cppSetInput_IntDelegate; function.Invoke(graphHandle, pInputName, values, numValues); }
public static uint cppGetOutputHash(IntPtr graphHandle, int pOutputIndex) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppGetOutputHashDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetOutputHashDelegate)) as cppGetOutputHashDelegate; return((uint)function.Invoke(graphHandle, pOutputIndex)); }
public static IntPtr cppGetMComboBoxItems(IntPtr graphHandle, string pIdentifier, out int pNumValues) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { pNumValues = 0; return(IntPtr.Zero); } cppGetMComboBoxItemsDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetMComboBoxItemsDelegate)) as cppGetMComboBoxItemsDelegate; return((IntPtr)function.Invoke(graphHandle, pIdentifier, out pNumValues)); }
public static void cppInitSubstance(string applicationDataPath) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; DLLHelpers.LoadDLL(applicationDataPath); if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppInitSubstanceDelegate function = DLLHelpers.GetFunction( myName, typeof(cppInitSubstanceDelegate)) as cppInitSubstanceDelegate; function.Invoke(applicationDataPath); }
public static void cppGetTextureDimensions(IntPtr graphHandle, out int pWidth, out int pHeight) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { pWidth = 256; pHeight = 256; return; } cppGetTextureDimensionsDelegate function = DLLHelpers.GetFunction( myName, typeof(cppGetTextureDimensionsDelegate)) as cppGetTextureDimensionsDelegate; function.Invoke(graphHandle, out pWidth, out pHeight); }
public static int cppShutdownSubstance() { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppShutdownSubstanceDelegate function = DLLHelpers.GetFunction( myName, typeof(cppShutdownSubstanceDelegate)) as cppShutdownSubstanceDelegate; int result = (int)function.Invoke(); DLLHelpers.UnloadDLL(); return(result); }
public static int cppLoadSubstance(string pAssetPath, IntPtr array, Int32 size, IntPtr assetCtx, IntPtr substanceObject, UInt32[] graphIndices, string[] graphPrototypeNames, string[] graphLabels, int[] graphFormats, int[] normalFormats, UInt32 numGraphIndices, int rawOverride, int projectContext) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return(0); } cppLoadSubstanceDelegate function = DLLHelpers.GetFunction( myName, typeof(cppLoadSubstanceDelegate)) as cppLoadSubstanceDelegate; return((int)function.Invoke(pAssetPath, array, size, assetCtx, substanceObject, graphIndices, graphPrototypeNames, graphLabels, graphFormats, normalFormats, numGraphIndices, rawOverride, projectContext)); }
public static void cppModifyTexturePacking(IntPtr graphHandle, string pSourceNames, int[] pSourceComponents, string pTargetName, int[] pTargetComponents, int pNumComponents) { string myName = System.Reflection.MethodBase.GetCurrentMethod().Name; if (DLLHelpers.DllHandle == IntPtr.Zero) { return; } cppModifyTexturePackingDelegate function = DLLHelpers.GetFunction( myName, typeof(cppModifyTexturePackingDelegate)) as cppModifyTexturePackingDelegate; function.Invoke(graphHandle, pSourceNames, pSourceComponents, pTargetName, pTargetComponents, pNumComponents); }