Git Product home page Git Product logo

sharpdl's People

Contributors

babelshift avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

sharpdl's Issues

Native library resolution fails on Ubuntu

The SDL2-CS library uses PInvoke to load SDL2 libraries. SDL2 is distributed in Windows as SDL2.dll, Mac as libSDL2.dylib, and Linux under varying names such as libSDL2.so or libSDL2-2.0-0.so.

This works properly under the following scenarios:

  • Windows with .NET Framework
  • Mac with Mono
  • Linux with Mono

Mono uses a dllmap algorithm to allow developers to redirect native library resolution in case of libraries not being found with standard names.

.NET Core doesn't have dllmap abilities and instead will only search for the name you provide and slight variations such as appending lib to the front.

While there is a new NativeLibrary class that allows developers to customize the way in which native libraries are resolved, this is only supported in .NET Core 3.0 and above. The library has yet to be added to any version of the .NET Standard, making it challenging to use in a library such as SharpDL that strives to be as broadly accessible as possible.

More examples

Dear Justin / babelshift,

It would be really good if you could post more examples. For instance, how to draw shapes and / or handle events.

Thank you in advance, Goicox

Framerate / Refreshrate

in public sealed class GameEngine : IGameEngine

//think i broke the code tags lol.
private const float fixedFramesPerSecond = 60f;
private bool isFrameRateCapped = true;

These 2 property's need to be set to public, well the fixed frames per second needs to be public, if we decided to create the renderer as such
mRenderer = mEngine.RendererFactory.CreateRenderer(mWindow, -1, RendererFlags.RendererAccelerated)
this should completely nullify the limiter (which it doesn't), however if you make that frame rate public we can set it to whatever we would like 60/122/244 etc. etc. as the moniters and whatnot get better so were not set by default to a monitor from the early 2000s lol.
Most games these days you can edit those values on the fly through in-game video menus.

Text Rendering Bug



Left is what it should look like: C++ using the sdl libs directly, right is what it looks like under SharpDL.
Both font sizes are set to 20 and here is the font used z3.ttf.
Dunno whats up with it to me looks like the .net library added some sort of shadowing to it which shouldent be the case.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.