Skip to content

[2.0] Silk.NET on Android #341

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 29 commits into from
Oct 27, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
06153fc
Merge branch '2.0' into feature/android
Perksey Aug 25, 2020
6428006
Progress commit, by no means done or ready
Perksey Sep 2, 2020
258a32c
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
Perksey Oct 4, 2020
e8906bf
Merge branch '2.0' into feature/android
Perksey Oct 4, 2020
a56e83e
Push latest progress on iOS and Android
Perksey Oct 10, 2020
8556b48
Update most NuGet packages
Perksey Oct 17, 2020
0d61e85
Push latest progress on iOS
Perksey Oct 17, 2020
a4f8eb9
Push latest progress on Android
Perksey Oct 17, 2020
68599d9
Merge branch '2.0' into feature/android
Perksey Oct 18, 2020
be0ceb3
Merge branch '2.0' into feature/android
Perksey Oct 24, 2020
c9668b6
Introduce PInvokeOverride
Perksey Oct 24, 2020
4b3596c
Add ZeroStart
Perksey Oct 25, 2020
7189455
Zero start of alloced memory
HurricanKai Oct 25, 2020
aad562e
Don't inline zeroing
HurricanKai Oct 25, 2020
c7a569f
Remove Debug statement
HurricanKai Oct 25, 2020
6396188
Less debug more functioning
HurricanKai Oct 25, 2020
7405cd1
Cast count to int
HurricanKai Oct 25, 2020
4a0c3f7
Stop forwarding SilkMarshal to Marshal, as this is inconsistent
Perksey Oct 25, 2020
448592b
Add Allocate/FreeStringPtr use new methods in SilkTouch
HurricanKai Oct 25, 2020
7b52a6a
See previous
HurricanKai Oct 25, 2020
6d91a88
Push GLSL ES shaders
Perksey Oct 25, 2020
24ffbd1
Merge remote-tracking branch 'origin/feature/android' into feature/an…
Perksey Oct 25, 2020
6991140
Rename Allocate/FreeString and fix a bug
HurricanKai Oct 25, 2020
2e7df9f
Merge remote-tracking branch 'origin/feature/android' into feature/an…
HurricanKai Oct 25, 2020
851fb93
A workingish prototype of Silk on Android
Perksey Oct 25, 2020
263e0a5
This is Silk.NET on Android
Perksey Oct 25, 2020
5db019e
Update src/Lab/Triangle/Triangle.csproj
Perksey Oct 26, 2020
8c560a1
Update src/Input/Silk.NET.Input.Common/Interfaces/IKeyboard.cs
Perksey Oct 26, 2020
456c76b
Update src/Input/Silk.NET.Input.Common/Interfaces/IKeyboard.cs
Perksey Oct 26, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
141 changes: 141 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -329,3 +329,144 @@ ASALocalRun/

# MFractors (Xamarin productivity tool) working folder
.mfractor/


# Created by https://www.toptal.com/developers/gitignore/api/android,java,gradle
# Edit at https://www.toptal.com/developers/gitignore?templates=android,java,gradle

### Android ###
# Built application files
*.apk
*.aar
*.ap_
*.aab

# Files for the ART/Dalvik VM
*.dex

# Java class files
*.class

# Generated files
bin/
gen/
out/
# Uncomment the following line in case you need and you don't have the release build type files in your app
# release/

# Gradle files
.gradle/
build/

# Local configuration file (sdk path, etc)
local.properties

# Proguard folder generated by Eclipse
proguard/

# Log Files
*.log

# Android Studio Navigation editor temp files
.navigation/

# Android Studio captures folder
captures/

# IntelliJ
*.iml
.idea/workspace.xml
.idea/tasks.xml
.idea/gradle.xml
.idea/assetWizardSettings.xml
.idea/dictionaries
.idea/libraries
# Android Studio 3 in .gitignore file.
.idea/caches
.idea/modules.xml
# Comment next line if keeping position of elements in Navigation Editor is relevant for you
.idea/navEditor.xml

# Keystore files
# Uncomment the following lines if you do not want to check your keystore files in.
#*.jks
#*.keystore

# External native build folder generated in Android Studio 2.2 and later
.externalNativeBuild
.cxx/

# Google Services (e.g. APIs or Firebase)
# google-services.json

# Freeline
freeline.py
freeline/
freeline_project_description.json

# fastlane
fastlane/report.xml
fastlane/Preview.html
fastlane/screenshots
fastlane/test_output
fastlane/readme.md

# Version control
vcs.xml

# lint
lint/intermediates/
lint/generated/
lint/outputs/
lint/tmp/
# lint/reports/

### Android Patch ###
gen-external-apklibs
output.json

# Replacement of .externalNativeBuild directories introduced
# with Android Studio 3.5.

### Java ###
# Compiled class file

# Log file

# BlueJ files
*.ctxt

# Mobile Tools for Java (J2ME)
.mtj.tmp/

# Package Files #
*.jar
*.war
*.nar
*.ear
*.zip
*.tar.gz
*.rar

# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*

### Gradle ###
.gradle

# Ignore Gradle GUI config
gradle-app.setting

# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored)
!gradle-wrapper.jar

# Cache of project
.gradletasknamecache

# # Work around https://youtrack.jetbrains.com/issue/IDEA-116898
# gradle/wrapper/gradle-wrapper.properties

### Gradle Patch ###
**/build/

# End of https://www.toptal.com/developers/gitignore/api/android,java,gradle
398 changes: 237 additions & 161 deletions Silk.NET.sln

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.0-rc0003" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
12 changes: 6 additions & 6 deletions src/Core/Silk.NET.BuildTools/Silk.NET.BuildTools.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@

<ItemGroup>
<PackageReference Include="ClangSharp" Version="10.0.0-beta" />
<PackageReference Include="CommandLineParser" Version="2.7.82" />
<PackageReference Include="HtmlAgilityPack" Version="1.11.18" />
<PackageReference Include="Humanizer.Core" Version="2.7.9" />
<PackageReference Include="JetBrains.Annotations" Version="2019.1.3" />
<PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="3.4.0" />
<PackageReference Include="Microsoft.Extensions.FileSystemGlobbing" Version="3.1.6" />
<PackageReference Include="CommandLineParser" Version="2.8.0" />
<PackageReference Include="HtmlAgilityPack" Version="1.11.24" />
<PackageReference Include="Humanizer.Core" Version="2.8.26" />
<PackageReference Include="JetBrains.Annotations" Version="2020.1.0" />
<PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="3.8.0-3.final" />
<PackageReference Include="Microsoft.Extensions.FileSystemGlobbing" Version="3.1.8" />
<PackageReference Include="morelinq" Version="3.3.2" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
</ItemGroup>
Expand Down
3 changes: 3 additions & 0 deletions src/Core/Silk.NET.Core/Loader/LibraryLoader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
using System.Runtime.InteropServices;
#endif
using System;
using System.Diagnostics;
using System.IO;

namespace Silk.NET.Core.Loader
Expand Down Expand Up @@ -250,6 +251,8 @@ public IntPtr LoadFunctionPointer(IntPtr handle, string functionName)
ThrowSymbolLoading(functionName);
return default;
}

Debug.WriteLine("Silk.NET loaded: " + functionName);

return ret;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Core/Silk.NET.Core/Native/FuncPtr.cs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public FuncPtr(Delegate @delegate)
{
var handle = GCHandle.Alloc(@delegate);
Value = Marshal.GetFunctionPointerForDelegate(@delegate);
FuncPtrInternal.Storage.Add(Value, new FuncPtrInternal {Delegate = @delegate, Handle = handle});
FuncPtrInternal.Storage[Value] = new FuncPtrInternal {Delegate = @delegate, Handle = handle};
}

/// <summary>
Expand Down
Loading