Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: sfmlnet-graphics-2.dll - System.AccessViolationException  (Read 4424 times)

0 Members and 1 Guest are viewing this topic.

Enok

  • Newbie
  • *
  • Posts: 16
    • View Profile
sfmlnet-graphics-2.dll - System.AccessViolationException
« on: November 25, 2014, 06:16:16 pm »

I compiled the latest source from github and this happens when I use the Sprite class.
Specifically when I try to draw the sprite. If I comment that part out, it'll run without any problems.


namespace ForScience
{
    class Program
    {
        static void Main(string[] args)
        {

            using(var rWindow = new RenderWindow(new VideoMode(800, 600), "For science!", Styles.Close))
            {
                Sprite spr = new Sprite(new Texture("spr_cannon_barrel.png"));

                rWindow.Closed += (sender, e) =>
                {
                    rWindow.Close();
                };

                while(rWindow.IsOpen)
                {
                    rWindow.DispatchEvents();
                    rWindow.Clear(new Color(248, 240, 255));
                    rWindow.Draw(spr);
                    rWindow.Display();
                }

            }  
       
        }
    }
}
 

The image is copied to build directory along with the extlibs and all libs are properly referenced.

zombox

  • Newbie
  • *
  • Posts: 8
    • View Profile
Re: sfmlnet-graphics-2.dll - System.AccessViolationException
« Reply #1 on: November 25, 2014, 07:07:59 pm »
Try newer csfml-*.dll files. You can get them here: http://www.nightlybuilds.ch/project/show/4/CSFML/

Enok

  • Newbie
  • *
  • Posts: 16
    • View Profile
Re: sfmlnet-graphics-2.dll - System.AccessViolationException
« Reply #2 on: November 25, 2014, 07:15:44 pm »
Try newer csfml-*.dll files. You can get them here: http://www.nightlybuilds.ch/project/show/4/CSFML/

Haha, I did do that some minutes ago and I was just about to write that I had it up and running properly when you wrote. :D

Anyhow, it's working, thank's for the quick response yo.

 

anything