Skip to content
Open
Show file tree
Hide file tree
Changes from 160 commits
Commits
Show all changes
189 commits
Select commit Hold shift + click to select a range
90f7348
Initial empty commit
Exanite Nov 24, 2025
a6c9af7
Edit docs
Exanite Nov 25, 2025
aac17e3
Add NativeName attribute
Exanite Nov 25, 2025
69291ed
Add start of MarkNativeNames mod
Exanite Nov 25, 2025
9eac50d
Successfully mark structs with NativeName attribute
Exanite Nov 25, 2025
76046df
Mark most identifiers with the NativeName attribute
Exanite Nov 25, 2025
7231782
Cleanup
Exanite Nov 25, 2025
bd0b4a4
Add StripAttributes mod for removing unwanted attributes
Exanite Nov 25, 2025
b23b859
Fix MarkNativeNames mod config not being loaded
Exanite Nov 25, 2025
869ea13
Add StripAttributes to Vulkan generator config and regenerate bindings
Exanite Nov 25, 2025
6c86b0b
Cleanup
Exanite Nov 25, 2025
91a92b5
Remove unused code in PrettifyNames, pretty sure this is from the old…
Exanite Nov 25, 2025
456f3b6
Remove unused code from PrettifyNames
Exanite Nov 25, 2025
94336cb
Add ModUtils.TryGetNativeName and WithNativeName to make it easier to…
Exanite Nov 25, 2025
4042cdf
Fix incorrect attribute filtering ()
Exanite Nov 25, 2025
10328a0
Cleanup
Exanite Nov 25, 2025
c620aaa
Move attribute related code from ModUtils into a new AttributeUtils c…
Exanite Nov 25, 2025
fd45a6f
Allow NativeName to be placed on methods
Exanite Nov 25, 2025
2b86025
Prevent enums with negative values from being coerced
Exanite Nov 25, 2025
f286f65
Add constructor to generated handle structs
Exanite Nov 25, 2025
553d33f
Cleanup using statements after splitting ModUtils into two classes
Exanite Nov 25, 2025
43a2336
Backport PrettifyNames changes from Curin's Microsoft branch
Exanite Nov 25, 2025
e3b0568
Add GlobalPrefixHints for SDL bindings and regenerate on Linux
Exanite Nov 26, 2025
5537269
Regenerate all bindings on Linux
Exanite Nov 26, 2025
81aa49d
Add CandidateNames record structs and replace the tuples used by the …
Exanite Nov 26, 2025
89ca280
Add documentation for CandidateNames structs
Exanite Nov 26, 2025
00243f1
Replace usages of Enumerable.Empty with []
Exanite Nov 26, 2025
6c8e684
Add record structs for most tuples used internally within PrettifyNames
Exanite Nov 26, 2025
0cf540f
Add AttributeUtils.ContainsAttribute
Exanite Nov 27, 2025
9fa07ca
Update code to use ContainsAttribute
Exanite Nov 27, 2025
b4cdd0e
Fix compile errors
Exanite Nov 27, 2025
aaf0356
Add NamePrefix/Suffix attributes
Exanite Nov 27, 2025
19a0d48
Fix typo
Exanite Nov 27, 2025
a04d801
Add helper methods for adding name prefix/suffix attributes
Exanite Nov 27, 2025
e5f526a
Always require name prefix/suffix priority and simplify code
Exanite Nov 27, 2025
5fdd1e8
Add NameSuffix and NativeName attributes to handle types
Exanite Nov 27, 2025
381618e
Add PFN_vk as global prefix hint to strip the PFNVk prefix off of the…
Exanite Nov 27, 2025
1136b98
Remove "TODO actually eval the expression to see if necessary?" since…
Exanite Nov 27, 2025
decdac6
Move MarkNativeNames to be right after ClangScraper
Exanite Nov 27, 2025
c8c1421
Add native name annotations to MixKhronosData
Exanite Nov 27, 2025
1aa0386
Use FlagBits version of enum names for the NativeName attribute as it…
Exanite Nov 27, 2025
e96b14e
Move ExtractNestedTyping to be before MixKhronosData and AddApiProfil…
Exanite Nov 27, 2025
cbbf3f3
Remove configuration for MarkNativeNames
Exanite Nov 27, 2025
2e8a6c6
Fix compile errors in SilkTouch tests
Exanite Nov 27, 2025
2151ddb
Allow SupportedApiProfileAttribute to be placed on delegates
Exanite Nov 27, 2025
cdee2ad
Edit MarkNativeNames docs
Exanite Nov 27, 2025
24f1fdc
Also change AddNamePrefix/Suffix priority parameter to be required
Exanite Nov 27, 2025
3bfdea1
Annotate all suffixes for handles and disable handle renaming in Tran…
Exanite Nov 27, 2025
426d950
Regenerate bindings on Linux (not final)
Exanite Nov 27, 2025
5bfe7ce
Edit comment for clarity
Exanite Nov 28, 2025
7287cfd
Rename "types" variable to newNames and add comment explaining purpose
Exanite Nov 28, 2025
eb443dc
Rename translator to nameTransformer for clarity
Exanite Nov 28, 2025
f27ad2d
Format comment for better readability
Exanite Nov 28, 2025
c69a7d4
Format else statement braces
Exanite Nov 28, 2025
1a7a5ba
Add comment marking where the rename process begins
Exanite Nov 28, 2025
8362630
Add RenamedType record struct
Exanite Nov 28, 2025
984795d
Move BeforeScrapeAsync method up higher in the class
Exanite Nov 28, 2025
53bd813
Rename ClassInProgress to TypeInProgress to prepare for future change…
Exanite Nov 28, 2025
6ff0f89
Format for readability
Exanite Nov 28, 2025
8f46b93
Add IsCurrentlyInType() private utility method and add docs
Exanite Nov 28, 2025
c4fd62f
Cleanup: Format and rename PrettifyNames.Visitor code and variables
Exanite Nov 28, 2025
94da46c
Add docs to PrettifyNames.Visitor private fields
Exanite Nov 29, 2025
d6f7d02
Fix typo(?) in NameTrimmerContext.NonDeterminant doc comment
Exanite Nov 29, 2025
2742dc1
Add doc comments to public members of PrettifyNames.Visitor
Exanite Nov 29, 2025
37dc8ce
Reorder PrettifyNames methods so that struct/class/enum declaration v…
Exanite Nov 29, 2025
5392f15
Rename "inner" variable to "typeData" and fix a typo I added
Exanite Nov 29, 2025
7114754
More PrettifyNames.Visitor cleanup
Exanite Nov 29, 2025
fac864f
Prettify struct property names (bitfields structs contain properties)
Exanite Nov 29, 2025
18dc9cc
Only prettify settable properties
Exanite Nov 29, 2025
2db865c
Edit MarkNativeNames mod doc comment
Exanite Nov 29, 2025
3ff5ce4
Add storage types for affix data
Exanite Nov 29, 2025
eb2c851
Change TypeData lists to not be nullable since it doesn't really affe…
Exanite Nov 29, 2025
77cfe81
Reorder PrettifyNames.Visitor methods again
Exanite Nov 29, 2025
f835bb7
Cleanup and slightly optimize identifier usages
Exanite Nov 29, 2025
f104c7c
Organize PrettifyNames.Visitor code for consistency
Exanite Nov 29, 2025
17fa8a1
Change other data types used by PrettifyNames to be non-nullable wher…
Exanite Nov 29, 2025
4f610c0
Remove my unused code in MixKhronosData
Exanite Nov 29, 2025
1336511
Only process field declaration variables instead of all variables
Exanite Nov 29, 2025
8880443
Combine TypeData and TypeAffixData
Exanite Nov 29, 2025
c6265e8
Remove IsEnum property since it never is used
Exanite Nov 29, 2025
e8cc72d
Remove unnecessary condition
Exanite Nov 29, 2025
54265bc
Add TypeAffixData back since it needs to be stored separately to avoi…
Exanite Nov 29, 2025
029f88b
Populate type name affix information
Exanite Nov 29, 2025
3910a4b
Switch to arrays and use sparser data storage
Exanite Nov 29, 2025
67badc8
Populate affix data for type members
Exanite Nov 29, 2025
5ddddbe
Replace NamePrefix/Suffix with NameAffix
Exanite Nov 29, 2025
e80214e
Fix enum name affix data not getting populated
Exanite Nov 29, 2025
bdb90b5
Mark NameAffixAttribute as [Conditional]
Exanite Nov 29, 2025
433f9ad
Trim _T from end of handle native names
Exanite Nov 29, 2025
bec2d1b
Update Vulkan generator config
Exanite Nov 29, 2025
fa97004
Implement proof of concept name affix handling
Exanite Nov 30, 2025
1b3b89a
Allow multiple NameAffix attributes to be used on one identifier
Exanite Nov 30, 2025
b8f385d
Cleanup
Exanite Nov 30, 2025
3052bdc
Don't process secondaries when adding to outputing to newNames dictio…
Exanite Nov 30, 2025
a670548
Fix incorrect rename
Exanite Nov 30, 2025
4d05314
Remove acronym identification in order to make all names be strictly …
Exanite Nov 27, 2025
d343503
Regenerate all bindings on Linux after changing acronyms to be pascal…
Exanite Nov 30, 2025
a9029f7
Update acronyms in names to be pascal cased and fix compile errors
Exanite Nov 30, 2025
60909ef
Remove NameUtils.Prettify allowAllCaps parameter
Exanite Nov 30, 2025
62351e8
Remove transformer from NameUtils.Prettify API and prevent unnecessar…
Exanite Nov 30, 2025
f0f8efa
Properly prettify the prettify only names if no trimmer baseline is s…
Exanite Nov 30, 2025
fb41785
Cleanup code
Exanite Nov 30, 2025
285540f
Refactor name affix API
Exanite Nov 30, 2025
3ec520b
Implement name affix handling
Exanite Nov 30, 2025
286d85b
Add prefix override for VkMemoryDecompressionMethodFlagsEXT
Exanite Nov 30, 2025
a5ea18a
Improve NameUtils.Prettify error messages
Exanite Nov 30, 2025
fc068a6
Add VendorSuffixIdentifierExclusions to MixKhronosData config
Exanite Nov 30, 2025
07af5dc
Regenerate SDL and OpenAL bindings. OpenGL needs more work. SDL has n…
Exanite Nov 30, 2025
a659a82
Remove now unnecessary _T trimming code
Exanite Nov 30, 2025
ab1aa5d
Remove unused code
Exanite Nov 30, 2025
13ffcfe
Remove ExtensionVendorTrimmingMode
Exanite Nov 30, 2025
8838125
Add todos
Exanite Nov 30, 2025
27a7750
Add NameAffixerLateTrimmer back and use prettify prevention hack to g…
Exanite Nov 30, 2025
990f560
Merge branch 'feature/vulkan-bindings-3.0-name-affixer' into feature/…
Exanite Nov 30, 2025
25484bf
Fix a few compile errors
Exanite Nov 30, 2025
572d225
Handle method vendor suffixes and remove vendor suffix capitalization…
Exanite Nov 30, 2025
a853fd6
Add NativeName attribute for function pointer structs and delegates
Exanite Nov 30, 2025
8e12ba7
Ensure delegate vendor extensions are identified properly
Exanite Nov 30, 2025
af59554
Cleanup
Exanite Dec 1, 2025
d91bcd7
Update generator configs for other jobs and also strip NameAffix attr…
Exanite Dec 1, 2025
7415297
Add TransformEnums mod to all jobs
Exanite Dec 1, 2025
322cc7b
Ignore cast expressions when deciding whether to rewrite enum members…
Exanite Dec 1, 2025
c3540a8
Regenerate SDL (inconsistent generation?)
Exanite Dec 1, 2025
8eded53
Fix non strict pascal casing in generator config
Exanite Dec 1, 2025
cfc8ac9
Prevent struct method names from getting trimmed
Exanite Dec 1, 2025
880957b
Rename VendorSuffixIdentifierExclusions to VendorSuffixIdentification…
Exanite Dec 1, 2025
a720617
Fix compile error
Exanite Dec 2, 2025
ed90465
Update comments
Exanite Dec 2, 2025
2f09e5b
Add AttributeUtils.GetNativeNameOrDefault()
Exanite Dec 2, 2025
c0e6bcb
Attempt to reimplement exclusive vendor suffix trimming code. Results…
Exanite Dec 2, 2025
1e067ac
Remove the now unnecessary rewind code
Exanite Dec 2, 2025
d9d62be
Temporarily remove data type trimming code
Exanite Dec 2, 2025
eb0f8e9
Fix ALC_INVALID_CONTEXT being prettified as InvalidContEXT
Exanite Dec 2, 2025
51023e2
Organize configuration for MixKhronosData and pre-emptively add new o…
Exanite Dec 2, 2025
2004a92
Add configuration options for TrimEnumTypeNonExclusiveVendors and Tri…
Exanite Dec 2, 2025
9c263b4
Replace TrimEnumMemberExclusiveVendors with TrimEnumMemberImpliedVend…
Exanite Dec 2, 2025
e30d2ec
Decide not to special case OpenGL's SamplePatternSGIS
Exanite Dec 3, 2025
124cd1b
Optimize/cleanup trimming code
Exanite Dec 3, 2025
a34ce36
Attempt to implement data type trimming, but not working yet due to f…
Exanite Dec 3, 2025
a3437cc
Merge branch 'feature/vulkan-bindings-3.0-improvements-enum-vendor-tr…
Exanite Dec 3, 2025
b112a60
Edit doc comment for NameAffix
Exanite Dec 3, 2025
f0c674e
Add discriminator priority to NameAffix attribute
Exanite Dec 3, 2025
8cbed7e
Add ToString implementations for CandidateNames structs for easier de…
Exanite Dec 3, 2025
596a6aa
Add comment explaining PreventPrettificationHack
Exanite Dec 4, 2025
1712060
Avoid adding redundant secondaries
Exanite Dec 4, 2025
90bb541
Merge branch 'feature/vulkan-bindings-3.0-improvements' into feature/…
Exanite Dec 4, 2025
39b782c
Regen OpenAL on Linux
Exanite Dec 4, 2025
fb55107
Change secondaries to be non-nullable since I allocate all of them an…
Exanite Dec 4, 2025
e3236b0
Regen OpenGL on Linux
Exanite Dec 4, 2025
82d3b7f
Disable stripping for NameAffix attributes in OpenAL for easier debug…
Exanite Dec 4, 2025
76fb8cf
Rework the NameAffix properties and what they do again
Exanite Dec 4, 2025
67c7867
Update config options and adjust docs a bit more
Exanite Dec 4, 2025
32d4e64
Edit docs
Exanite Dec 4, 2025
eaa93cb
Store the NameAffixAttribute declaration order
Exanite Dec 4, 2025
b7428f5
Update order and priority of data type suffixes
Exanite Dec 4, 2025
2ea6a43
Attempt to get data trimming working and apparently fix a few bugs in…
Exanite Dec 4, 2025
24ce296
Fix AL_VOCAL_MORPHER_PHONEME_T's -T suffix getting trimmed
Exanite Dec 4, 2025
b0bff43
Edit doc comment on NameAffixerEarlyTrimmer.Version
Exanite Dec 4, 2025
1023090
Regenerate all bindings on Linux
Exanite Dec 4, 2025
3f575ff
Strip all NameAffix attributes for OpenAL since I'm no longer debugging
Exanite Dec 4, 2025
9a90036
Sort and ensure consistent attribute targets for NativeName and NameA…
Exanite Dec 4, 2025
8dcd207
Fix formatting
Exanite Dec 5, 2025
22a2c95
Don't mark parameters with the NativeName attribute
Exanite Dec 5, 2025
1536c15
Add INameTrimmer.Order property and sort trimmers by that instead of …
Exanite Dec 5, 2025
97586d6
Fix OpenAL's alSourceRewindv getting trimmed as alSourceRewin
Exanite Dec 5, 2025
f414752
Fix incorrect range indexing
Exanite Dec 5, 2025
58524e3
Change prettification to occur before affixes are re-added
Exanite Dec 5, 2025
5cc9c6e
Rename NameAffix.Priority to DiscriminatorPriority for clarity
Exanite Dec 6, 2025
f75dd7f
Cleanup RewriterPhase3 code in MixKhronosData
Exanite Dec 6, 2025
8fe7404
Fix incorrect hasSetter condition causing properties to be incorrectl…
Exanite Dec 6, 2025
fbcb049
Fix TexStorageAttribs and ContainerType getting over trimmed
Exanite Dec 6, 2025
682a261
Fix enums created by MixKhronosData not having their enum values rewr…
Exanite Dec 6, 2025
7b45449
Regenerate bindings on Windows
Exanite Dec 6, 2025
558a8b1
Fix compile errors in tests
Exanite Dec 6, 2025
e9c9f39
Exclude SDL_SetWindowsMessageHook
Exanite Dec 6, 2025
cd5b2c9
Exclude SDL_FILE, SDL_LINE, SDL_NULL_WHILE_LOOP_CONDITION
Exanite Dec 6, 2025
c7300c3
Fix compile errors and update windowing code to use strict pascal cas…
Exanite Dec 6, 2025
9c9fbfc
Revert after review: Revert all generated bindings changes
Exanite Dec 6, 2025
5cd9029
Revert incorrect OpenGL capitalization changes in SdlContext
Exanite Dec 6, 2025
fac347c
Revert incorrect OpenGL capitalization changes in SdlSurfaceComponent…
Exanite Dec 6, 2025
a1c0f23
Revert "Revert after review: Revert all generated bindings changes"
Exanite Dec 6, 2025
48d182f
Begin reverting acronym casing change
Exanite Dec 6, 2025
16f5753
Update openal-soft submodule
Exanite Dec 6, 2025
53fbdd3
Revert change to EGLPlatformInfo
Exanite Dec 6, 2025
8aefc51
Regenerate bindings on Windows
Exanite Dec 7, 2025
9bbf8be
Revert after review: Revert all generated bindings changes
Exanite Dec 7, 2025
4634117
Revert changes to ContextSourceExtensions
Exanite Dec 7, 2025
787081a
Revert changes to SdlEventProcessor
Exanite Dec 7, 2025
2fa139f
Revert changes to SdlSurfaceComponents
Exanite Dec 7, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
Binary file added .silktouch/72b687a9cceac28c.stout
Binary file not shown.
Binary file modified .silktouch/82fde6eb3b68e085.stout
Binary file not shown.
Binary file modified .silktouch/91c9aa14a031651f.stout
Binary file not shown.
Binary file modified .silktouch/c8c046b328b09d23.stout
Binary file not shown.
2 changes: 1 addition & 1 deletion eng/silktouch/openal/alsoft/generate.rsp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ _GUID
--file
openal-soft-al.h
--methodClassName
AL
Al
--namespace
Silk.NET.OpenAL
--output
Expand Down
2 changes: 1 addition & 1 deletion eng/silktouch/opengl/glcompat/generate.rsp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ WIN32_LEAN_AND_MEAN
--file
opengl-gl.h
--methodClassName
GL
Gl
--namespace
Silk.NET.OpenGL
--output
Expand Down
2 changes: 1 addition & 1 deletion eng/silktouch/opengl/glcore/generate.rsp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ WIN32_LEAN_AND_MEAN
--file
opengl-gl.h
--methodClassName
GL
Gl
--namespace
Silk.NET.OpenGL
--output
Expand Down
2 changes: 1 addition & 1 deletion eng/silktouch/opengl/gles1/generate.rsp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ WIN32_LEAN_AND_MEAN
--file
opengl-gl.h
--methodClassName
GL
Gl
--namespace
Silk.NET.OpenGL
--output
Expand Down
2 changes: 1 addition & 1 deletion eng/silktouch/opengl/gles2/generate.rsp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ WIN32_LEAN_AND_MEAN
--file
opengl-gl.h
--methodClassName
GL
Gl
--namespace
Silk.NET.OpenGL
--output
Expand Down
32 changes: 16 additions & 16 deletions examples/CSharp/OpenAL/Tutorial001.HelloSound/Program.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
using NAudio.Wave;
using Silk.NET.OpenAL;

// NOTE: If you prefer, you can use the static ALContext and AL functions instead of creating an API object!
// NOTE: If you prefer, you can use the static AlContext and Al functions instead of creating an API object!
// Learn more: https://dotnet.github.io/Silk.NET/docs/v3/silk.net/static-vs-instance-bindings
var alc = ALContext.Create(); // TODO disposable
var alc = AlContext.Create(); // TODO disposable

// Open an audio device.
var device = alc.OpenDevice("");
Expand Down Expand Up @@ -34,12 +34,12 @@ var pname in (IEnumerable<StringPName>)
[StringPName.Vendor, StringPName.Extensions, StringPName.Renderer, StringPName.Version]
)
{
Console.WriteLine($"{pname}: {AL.GetString(pname).ReadToString()}");
Console.WriteLine($"{pname}: {Al.GetString(pname).ReadToString()}");
}

// Create an audio source and a buffer to store the audio data played by that source.
var source = AL.GenSource();
var buffer = AL.GenBuffer();
var source = Al.GenSource();
var buffer = Al.GenBuffer();

// We're using NAudio to read the WAV file into a buffer we can then pass to OpenAL.
// We do have to do a little bit of work to map wavReader.WaveFormat into OpenAL's Format enum though.
Expand All @@ -53,27 +53,27 @@ var pname in (IEnumerable<StringPName>)

// Upload the audio data to the audio device.
var format = ConvertFormat(wavReader.WaveFormat);
AL.BufferData(buffer, format, sampleBuffer, sampleBuffer.Length, wavReader.WaveFormat.SampleRate);
AL.ThrowError();
Al.BufferData(buffer, format, sampleBuffer, sampleBuffer.Length, wavReader.WaveFormat.SampleRate);
Al.ThrowError();

// Configure the audio source to loop its audio, and play it!
// TODO this is crap - we should have a boolean overload.
AL.Source(source, (ALEnum)SourceBoolean.Looping, 1);
AL.Source(source, SourceInteger.Buffer, (int)buffer);
AL.SourcePlay(source);
AL.ThrowError();
Al.Source(source, (AlEnum)SourceBoolean.Looping, 1);
Al.Source(source, SourceInteger.Buffer, (int)buffer);
Al.SourcePlay(source);
Al.ThrowError();

Console.WriteLine("Press Enter to Exit...");
Console.ReadLine();

// Stop playing audio.
AL.SourceStop(source);
Al.SourceStop(source);

// Cleanup!
AL.DeleteSource(source);
AL.DeleteBuffer(buffer);
ALContext.DestroyContext(context);
ALContext.CloseDevice(device);
Al.DeleteSource(source);
Al.DeleteBuffer(buffer);
AlContext.DestroyContext(context);
AlContext.CloseDevice(device);
return;

static Format ConvertFormat(WaveFormat format) =>
Expand Down
Loading
Loading