• Alternative rendering libraries?
    12 replies, posted
I tried XNA and SDL.Net, but I'm not very happy with any of them. I just want to code the game logic and tell the library: "Render this, please." Is there any other good rendering library?
[QUOTE=SupahVee;21163698]I tried XNA and SDL.Net, but I'm not very happy with any of them. I just want to code the game logic and tell the library: "Render this, please." Is there any other good rendering library?[/QUOTE] You might want to take a look at SFML, it has .Net bindings as well [url]http://www.sfml-dev.org/index.php[/url]
You could use the native System.Drawing.Graphics if you don't need something overly complex.
[QUOTE=nullsquared;21163940]You could use the native System.Drawing.Graphics if you don't need something overly complex.[/QUOTE] Is that suitable for any kind of 2D game?
I think XNA is about as good as it gets really: you will not have an easier time making a game with System.Drawing.Complex. In what way is XNA insufficient for your needs? You can download extra physics and gui engines if you don't want to write that part of the code.
[QUOTE=SupahVee;21164079]Is that suitable for any kind of 2D game?[/QUOTE] Not if you want a fast paced game, no it isn't. GDI is slow. Go with SFML.NET. Get the latest from SVN, that's what I'm using and I'm lovin' it.
I don't really like XNA, I don't know why. SDL is simpler and I prefer that, but I'm still not happy with it. I'll give SFML.NET a try. [editline]03:46PM[/editline] [QUOTE=Xeon06;21164217]Not if you want a fast paced game, no it isn't. GDI is slow. Go with SFML.NET. Get the latest from SVN, that's what I'm using and I'm lovin' it.[/QUOTE] I downloaded the non-SVN version, and I'm stuck at the first step of the first tutorial. I have imported 3 libraries: audio, graphics and window. However I can't find the "Clock" class. Is there a .NET tutorial?
There's also OpenTK which is probably a much better solution for OpenGL in C#
I like SFML so far. It's pretty simple.
[QUOTE=SupahVee;21164252]I don't really like XNA, I don't know why. SDL is simpler and I prefer that, but I'm still not happy with it. I'll give SFML.NET a try. [editline]03:46PM[/editline] I downloaded the non-SVN version, and I'm stuck at the first step of the first tutorial. I have imported 3 libraries: audio, graphics and window. However I can't find the "Clock" class. Is there a .NET tutorial?[/QUOTE] Yes, download the documentation, there is a basic example there. Otherwise, off the top of my head: [code] using System; using SFML.Window; using SFML.Graphics; namespace Bleh { class Foo { static void Main() { RenderWindow app = new RenderWindow(new VideoMode(500, 500), "Test"); while(app.IsOpened()) { app.DispatchEvents(); app.Clear(); app.Draw(Shape.Circle(new Vector2(250, 250), 100, Color.Red)); app.Display(); } } } } [/code]
Thanks. I need more help though, I added you on Steam if you don't mind. Anyway, here's my problem (SFML): I have a sprite, and I want another sprite (the hitbox) to stay in its center. I tried messing around with the center property but I can't make the sprite x, y position be in the center.
Well say you've got sprite A and B. You want b to stay in the centre of A. You could try getting the (x, y) position of A and then set B to it with some sort of offset. Play around with the offset and it should work.
SFML.net is very nice.
Sorry, you need to Log In to post a reply to this thread.