Comments (4)
Following the foundation meeting of March 14, the applications have been reviewed and this bounty has been locked for @tomspilman to complete.
from monogame.
DllImport
works just fine with NativeAOT. Maybe some other ahead-of-time environments don't, but we already shipped games using DllImport
and NativeAOT so we should be all fine.
(NativeAOT has modes which are stricter and might require that, but it is not required to go as far as that on consoles with MonoGame.)
from monogame.
Hello. Just a little nitpick. I think that the new LibraryImport
is probably more appropriate than the DllImport
, since NativeAOT is the target.
Using DllImport isn't an option for platforms that require full Native AOT scenarios and therefore using other approaches (for example, source generation) is more appropriate.
...
The P/Invoke source generator, included with the .NET 7 SDK and enabled by default, looks forLibraryImportAttribute
on a static and partial method to trigger compile-time source generation of marshalling code, removing the need for the generation of an IL stub at run time and allowing the P/Invoke to be inlined.
https://learn.microsoft.com/en-us/dotnet/standard/native-interop/pinvoke-source-generation
from monogame.
You're right. DllImport
doesn't work only in full NativeAOT.
from monogame.
Related Issues (20)
- Project Template Type Table Documentation URLs need to be updated HOT 2
- [PAID BOUNTY] [LOCKED] Implement the Direct3D 12 / GDK/GDKX backend HOT 1
- NoSuitableGraphicsDeviceException on Virtual Machine HOT 2
- PathHelper.GetRelativePath potential bugs HOT 2
- Issue with GetData/SetData as of 2024 HOT 2
- `DrawableGameComponent.Initialize` Does Not Behave How XNA Documentation Describe It HOT 1
- [PAID BOUNTY] [LOCKED] Package up ffmpeg and ffprobe HOT 10
- [PAID BOUNTY][LOCKED] A shared base for public and console repos
- AL lib throws unclosed device warning on proper game exit HOT 4
- Variable rate shading HOT 2
- [Urgent security issue] FreeImage arbitrary code execution vulnerability HOT 2
- tu-clausthal link does not exists HOT 2
- Getting started page is not working HOT 2
- SpriteBatch With Custom Effects and Per-Sprite Data HOT 2
- Links in Footer not working (Website)
- Visual Studio extension doesn't build anymore HOT 2
- Separate interfaces and platform-specific realizations HOT 2
- Getdata<T> allocates an extra array of T[] HOT 3
- Mitigate null reference exceptions via better communication HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from monogame.