Added severial examples. Corrected towards the correct return type and add utilities to prevent working with pointers
This commit is contained in:
parent
2a86968da0
commit
6c94ffb0cc
21 changed files with 1252 additions and 205 deletions
|
|
@ -1,3 +1,4 @@
|
|||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Raylib_cs;
|
||||
|
|
|
|||
|
|
@ -21,6 +21,11 @@ public readonly ref struct Utf8Buffer
|
|||
return (sbyte*)_data.ToPointer();
|
||||
}
|
||||
|
||||
public unsafe byte* AsBytePointer()
|
||||
{
|
||||
return (byte*)_data.ToPointer();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
Marshal.ZeroFreeCoTaskMemUTF8(_data);
|
||||
|
|
|
|||
Loading…
Reference in a new issue