Skip to content

Make edlink n8 cross-platform by upgrading project to .NET SDK - #10

Open
LVS12122 wants to merge 4 commits into
krikzz:mainfrom
LVS12122:modernize/edlink-n8-sdk-style
Open

Make edlink n8 cross-platform by upgrading project to .NET SDK#10
LVS12122 wants to merge 4 commits into
krikzz:mainfrom
LVS12122:modernize/edlink-n8-sdk-style

Conversation

@LVS12122

Copy link
Copy Markdown

(Feel free to deny this PR if you want to stick with .NET Framework for whatever reason)

This PR modernizes the project to work with .NET SDK, which allows for building on Windows, Mac, and Linux (with "dotnet build edlink-n8/edlink-n8.sln"). It also integrates nicely with C# Dev Kit in VS Code (I included the VS Code Build Tasks for convenience).
Also for the screenshot option, I needed to swap out the Bitmap class with a cross-platform option called SkiaSharp. I've tested this (on Mac) as well as running a .nes, and running diagnostics, and they all work great. The only thing that hasn't worked that i tested was -cp, but it seems to be a separate issue.

… 10.0

- Convert project from legacy .NET Framework format to modern SDK-style format
- Upgrade target framework from .NET Framework 4.7.2 to .NET 10.0 (LTS)
- Replace legacy assembly references with NuGet packages:
  - System.IO.Ports (for serial communication)
  - System.Drawing.Common (for graphics operations)
- Clean up AssemblyInfo.cs to let SDK auto-generate assembly attributes
- Project now builds successfully with C# Dev Kit

This modernization enables the project to work with Visual Studio 2024 C# Dev Kit
and benefit from modern .NET features and performance improvements.
- Remove System.Drawing.Common package (Windows-only)
- Add SkiaSharp package (cross-platform graphics library)
- Update MenuImage.cs to use SkiaSharp APIs:
  - SKSurface/SKCanvas instead of Bitmap
  - DrawPoint instead of SetPixel
  - PNG encoding instead of Save method
- Project now builds and runs on macOS, Windows, and Linux
- Maintains identical functionality for NES image generation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant