Skip to content

Commit

Permalink
Updated to NoesisGUI 3.2.7 version
Browse files Browse the repository at this point in the history
  • Loading branch information
s-fernandez-v committed Jan 22, 2025
1 parent b431a89 commit a2f1dda
Show file tree
Hide file tree
Showing 15 changed files with 857 additions and 67 deletions.
23 changes: 15 additions & 8 deletions Src/Noesis/Core/Src/Core/RenderDevice.cs
Original file line number Diff line number Diff line change
Expand Up @@ -487,6 +487,10 @@ public struct Batch
public readonly RenderState RenderState;
public readonly byte StencilRef;

/// <summary>Single Pass Stereo renders both left and right eye images at the same time</summary>
[MarshalAs(UnmanagedType.U1)]
public readonly bool SinglePassStereo;

/// <summary>Draw parameters</summary>
public readonly uint VertexOffset;
public readonly uint NumVertices;
Expand Down Expand Up @@ -1121,7 +1125,7 @@ private static void DrawBatch(IntPtr cPtr, ref Batch batch)

#region Imports
[DllImport(Library.Name)]
static extern uint Noesis_RenderDevice_SetCallbacks(
static extern void Noesis_RenderDevice_SetCallbacks(
Callback_GetCaps getCaps,
Callback_CreateRenderTarget createRenderTarget,
Callback_CloneRenderTarget cloneRenderTarget,
Expand Down Expand Up @@ -1216,7 +1220,8 @@ public override RenderTarget CloneRenderTarget(string label, RenderTarget surfac
throw new ArgumentNullException("surface");
}

IntPtr cPtr = Noesis_RenderDevice_CloneRenderTarget(swigCPtr, BaseComponent.getCPtr(surface));
IntPtr cPtr = Noesis_RenderDevice_CloneRenderTarget(swigCPtr, label,
BaseComponent.getCPtr(surface));

return new NativeRenderTarget(cPtr, true);
}
Expand Down Expand Up @@ -1365,10 +1370,12 @@ protected static Texture WrapTexture(object texture, IntPtr texPtr)

[DllImport(Library.Name)]
static extern IntPtr Noesis_RenderDevice_CreateRenderTarget(HandleRef device,
[MarshalAs(UnmanagedType.LPWStr)]string label, uint width, uint height, uint sampleCount, bool needsStencil);
[MarshalAs(UnmanagedType.LPWStr)]string label, uint width, uint height,
uint sampleCount, bool needsStencil);

[DllImport(Library.Name)]
static extern IntPtr Noesis_RenderDevice_CloneRenderTarget(HandleRef device, HandleRef surface);
static extern IntPtr Noesis_RenderDevice_CloneRenderTarget(HandleRef device,
[MarshalAs(UnmanagedType.LPWStr)] string label, HandleRef surface);

[DllImport(Library.Name)]
static extern void Noesis_RenderDevice_SetRenderTarget(HandleRef device, HandleRef surface);
Expand Down Expand Up @@ -1564,7 +1571,7 @@ public static IntPtr GetTextureNativePointer(Texture texture)
/// </summary>
public void SetCommandList(IntPtr commands, long fenceValue)
{
Noesis_RenderDeviceD3D12_SetCommandList(swigCPtr, commands, fenceValue);
Noesis_RenderDeviceD3D12_SetCommandList(swigCPtr, commands, (ulong)fenceValue);
}

#region Imports
Expand All @@ -1582,7 +1589,7 @@ static extern IntPtr Noesis_RenderDeviceD3D12_WrapTexture(IntPtr nativePointer,

[DllImport(Library.Name)]
static extern void Noesis_RenderDeviceD3D12_SetCommandList(HandleRef device, IntPtr commands,
long fenceValue);
ulong fenceValue);
}

/// <summary>
Expand Down Expand Up @@ -1756,7 +1763,7 @@ static extern IntPtr Noesis_RenderDeviceGNM_WrapTexture(IntPtr nativePointer,
int width, int height, int numMipMaps, bool isInverted, bool hasAlpha);

[DllImport(Library.Name)]
static extern IntPtr Noesis_RenderDeviceGNM_SetContext(HandleRef device, IntPtr context);
static extern void Noesis_RenderDeviceGNM_SetContext(HandleRef device, IntPtr context);
#endregion
}

Expand Down Expand Up @@ -1849,7 +1856,7 @@ static extern IntPtr Noesis_RenderDeviceAGC_WrapTexture(IntPtr nativePointer,
int width, int height, int numMipMaps, bool isInverted, bool hasAlpha);

[DllImport(Library.Name)]
static extern IntPtr Noesis_RenderDeviceAGC_SetCommandBuffer(HandleRef device,
static extern void Noesis_RenderDeviceAGC_SetCommandBuffer(HandleRef device,
IntPtr drawCommandBuffer);
#endregion
}
Expand Down
Loading

0 comments on commit a2f1dda

Please sign in to comment.