mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-29 14:38:25 +01:00
SOURCE DUMP v1
This commit is contained in:
parent
bd62d51ec9
commit
fb20299e9d
1 changed files with 768360 additions and 0 deletions
|
|
@ -0,0 +1,78 @@
|
|||
// <auto-generated/>
|
||||
// Generated by Brutal.Glfw.Generate; do not edit by hand.
|
||||
#nullable enable
|
||||
|
||||
namespace Brutal.GlfwApi.OSMesa
|
||||
{
|
||||
/// <summary>
|
||||
/// Native handle accessors for the OSMesa software context backend. Add <c>using Brutal.GlfwApi.OSMesa;</c> to
|
||||
/// call these extension methods on <see cref="GlfwWindow"/>.
|
||||
/// </summary>
|
||||
public static unsafe class OSMesaExtensions
|
||||
{
|
||||
extension(GlfwWindow window)
|
||||
{
|
||||
/// <summary>
|
||||
/// Retrieves the color buffer associated with the specified window.
|
||||
/// </summary>
|
||||
/// <param name="width">Receives the width of the color buffer.</param>
|
||||
/// <param name="height">Receives the height of the color buffer.</param>
|
||||
/// <param name="format">Receives the OSMesa pixel format of the color buffer.</param>
|
||||
/// <param name="buffer">Receives the address of the color buffer.</param>
|
||||
/// <returns><c>true</c> if successful, or <c>false</c> if an error occurred.</returns>
|
||||
/// <remarks>
|
||||
/// This function is only available when GLFW was built with OSMesa context support. Calling it otherwise
|
||||
/// will result in an <see cref="EntryPointNotFoundException"/>.
|
||||
/// </remarks>
|
||||
/// <possibleErrors>
|
||||
/// <see cref="GlfwErrorCode.NotInitialized"/>, <see cref="GlfwErrorCode.NoWindowContext"/>
|
||||
/// </possibleErrors>
|
||||
/// <threadSafety>
|
||||
/// This function may be called from any thread. Access is not synchronized.
|
||||
/// </threadSafety>
|
||||
/// <seealso href="https://www.glfw.org/docs/latest/group__native.html">glfwGetOSMesaColorBuffer</seealso>
|
||||
public bool GetOSMesaColorBuffer(out int width, out int height, out int format, out void* buffer) =>
|
||||
Glfw.PInvoke.GetOSMesaColorBuffer(window, out width, out height, out format, out buffer) == GLFW_TRUE;
|
||||
|
||||
/// <summary>
|
||||
/// Retrieves the depth buffer associated with the specified window.
|
||||
/// </summary>
|
||||
/// <param name="width">Receives the width of the depth buffer.</param>
|
||||
/// <param name="height">Receives the height of the depth buffer.</param>
|
||||
/// <param name="bytesPerValue">Receives the number of bytes per depth buffer element.</param>
|
||||
/// <param name="buffer">Receives the address of the depth buffer.</param>
|
||||
/// <returns><c>true</c> if successful, or <c>false</c> if an error occurred.</returns>
|
||||
/// <remarks>
|
||||
/// This function is only available when GLFW was built with OSMesa context support. Calling it otherwise
|
||||
/// will result in an <see cref="EntryPointNotFoundException"/>.
|
||||
/// </remarks>
|
||||
/// <possibleErrors>
|
||||
/// <see cref="GlfwErrorCode.NotInitialized"/>, <see cref="GlfwErrorCode.NoWindowContext"/>
|
||||
/// </possibleErrors>
|
||||
/// <threadSafety>
|
||||
/// This function may be called from any thread. Access is not synchronized.
|
||||
/// </threadSafety>
|
||||
/// <seealso href="https://www.glfw.org/docs/latest/group__native.html">glfwGetOSMesaDepthBuffer</seealso>
|
||||
public bool GetOSMesaDepthBuffer(out int width, out int height, out int bytesPerValue, out void* buffer) =>
|
||||
Glfw.PInvoke.GetOSMesaDepthBuffer(window, out width, out height, out bytesPerValue, out buffer)
|
||||
== GLFW_TRUE;
|
||||
|
||||
/// <summary>
|
||||
/// Returns the <c>OSMesaContext</c> of the specified window.
|
||||
/// </summary>
|
||||
/// <returns>The <c>OSMesaContext</c> of the specified window, or <c>0</c> if an error occurred.</returns>
|
||||
/// <remarks>
|
||||
/// This function is only available when GLFW was built with OSMesa context support. Calling it otherwise
|
||||
/// will result in an <see cref="EntryPointNotFoundException"/>.
|
||||
/// </remarks>
|
||||
/// <possibleErrors>
|
||||
/// <see cref="GlfwErrorCode.NotInitialized"/>, <see cref="GlfwErrorCode.NoWindowContext"/>
|
||||
/// </possibleErrors>
|
||||
/// <threadSafety>
|
||||
/// This function may be called from any thread. Access is not synchronized.
|
||||
/// </threadSafety>
|
||||
/// <seealso href="https://www.glfw.org/docs/latest/group__native.html">glfwGetOSMesaContext</seealso>
|
||||
public nint GetOSMesaContext() => Glfw.PInvoke.GetOSMesaContext(window);
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue