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

Author Topic: sdl user but I'll switch  (Read 7118 times)

0 Members and 1 Guest are viewing this topic.

vectorg

  • Newbie
  • *
  • Posts: 4
    • View Profile
sdl user but I'll switch
« on: January 16, 2012, 05:21:17 am »
hello,

I'm here because I just updated my Intel HD2000/HD3000 graphics drivers, and SDL stencil buffer stopped working.  No shadows.

Are there any known issues with SFML and HD2000 graphics drivers on Windows 7, or a 64-bit OS?

One other question, can SFML be used to do software rendering?  I currently use SDL to do that on Windows and Linux.

Thanks.

Tex Killer

  • Full Member
  • ***
  • Posts: 242
    • View Profile
sdl user but I'll switch
« Reply #1 on: January 16, 2012, 05:53:21 am »
What do you mean by software rendering?

Perhaps you want something like "SFGUI"... If so, check on the projects sub-forum.

Edit: How dumb of me, only realised what you meant after Laurent reply...

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
sdl user but I'll switch
« Reply #2 on: January 16, 2012, 07:33:11 am »
Stencil buffer has nothing to do with SDL, it's most likely a driver problem. Same for SFML, by the way.

SFML is based on OpenGL, so if you want to do software rendering you must find a software implementation of OpenGL.
Laurent Gomila - SFML developer

vectorg

  • Newbie
  • *
  • Posts: 4
    • View Profile
sdl user but I'll switch
« Reply #3 on: January 16, 2012, 11:09:44 pm »
Yes, I solved the problem and it was a driver issue, not SDL.  Intel driver installation reset a parameter, and you must set it to "Software" in the 3D section of their HD3000 setup utility.

>>What do you mean by software rendering?

I draw all pixels in the video buffer myself, then swap the page, and draw again.  Like in the old days.  Lots of clipping, poly-filling, z-buffer maintenance, etc.  Very fun.

Laurent, does SFML provide a video buffer address to OpenGL so it can draw?  If so, then I could use that address to do my own drawing.  Do you think yes or no?  Is there an explicit page-flipping function in SFML that I would call?

Anyway, thanks for the help guys!

caracal

  • Newbie
  • *
  • Posts: 19
    • View Profile
sdl user but I'll switch
« Reply #4 on: January 17, 2012, 12:54:19 am »
You can use pretty much any 2d graphics library "Cairo, Pixman, QPainter, AGG, Fog Framework, Skia, ImageMagick" to do your drawing and then just
copy the the pixel buffer to a sfml Image.

Here is a ImageMagick (Magick++) Example

Code: [Select]

  sf::Image image;

  Image im("picture.png");;
  Blob blob;

  im.magick("RGBA");
  im.swirl( 100 );
  im.write(&blob);
 
  image.Create(im.columns(), im.rows(), reinterpret_cast<const sf::Uint8*>(blob.data()));
 
  // Load a sprite to display
  sf::Texture texture;
  if (!texture.LoadFromImage(image))
          return EXIT_FAILURE;



If your interested I have examples for all the above 2d graphics engine except AGG. Let me know and Ill prepair them for you :)

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
sdl user but I'll switch
« Reply #5 on: January 17, 2012, 08:09:20 am »
Quote
Laurent, does SFML provide a video buffer address to OpenGL so it can draw?

This was possible 20 years ago, but this is not how things work anymore today ;)
You must use your own pixel buffer in system memory, then upload it to the video card through a texture and display it with a fullscreen sprite.
Laurent Gomila - SFML developer

vectorg

  • Newbie
  • *
  • Posts: 4
    • View Profile
sdl user but I'll switch
« Reply #6 on: January 17, 2012, 09:27:20 pm »
Ok, here's what I have learned about the stencil buffer HD3000 issue...

A Windows OpenGL app (using CreateWindowEx) works when the Intel HD3000 3D option is set to "Default Settings" or "Application Settings", or any setting.

An SDL app only works with HD3000 3D option set to "Enable Software Processing".

Also, with "Enable Software Processing", both apps run at about half speed.

Questions:

What parameter options should I try in SDL to get it to work at Intel "Default Settings"?

Will SFML require "Enable Software Processing" also?

Thanks.

Mario

  • SFML Team
  • Hero Member
  • *****
  • Posts: 879
    • View Profile
sdl user but I'll switch
« Reply #7 on: January 18, 2012, 12:00:24 am »
I'd say best way to test would be "trial & error". You could use any of the minimal examples or a short test program to test this.

dydya-stepa

  • Jr. Member
  • **
  • Posts: 82
    • View Profile
sdl user but I'll switch
« Reply #8 on: January 18, 2012, 11:51:11 am »
I have no idea how to send messages to other users.

I have a question to caracal:

you mention you have lots of samples with graphics libraries. I'm looking for an algorithm of a glow - maybe you know what options might be?

http://www.sfml-dev.org/forum/viewtopic.php?t=6629

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
sdl user but I'll switch
« Reply #9 on: January 18, 2012, 12:01:00 pm »
Quote
I have no idea how to send messages to other users.

Laurent Gomila - SFML developer

dydya-stepa

  • Jr. Member
  • **
  • Posts: 82
    • View Profile
sdl user but I'll switch
« Reply #10 on: January 18, 2012, 01:16:20 pm »
you wanted to say something ? :-) or what

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
sdl user but I'll switch
« Reply #11 on: January 18, 2012, 01:24:27 pm »
I show you which button you must click to send a Private Message to a user.
Laurent Gomila - SFML developer

dydya-stepa

  • Jr. Member
  • **
  • Posts: 82
    • View Profile
sdl user but I'll switch
« Reply #12 on: January 18, 2012, 03:05:50 pm »
ahh, thanks.

caracal

  • Newbie
  • *
  • Posts: 19
    • View Profile
sdl user but I'll switch
« Reply #13 on: January 18, 2012, 06:40:14 pm »
Quote from: "dydya-stepa"
I have no idea how to send messages to other users.

I have a question to caracal:

you mention you have lots of samples with graphics libraries. I'm looking for an algorithm of a glow - maybe you know what options might be?

http://www.sfml-dev.org/forum/viewtopic.php?t=6629


Ummm I am the wrong person to ask about shaders. I am the "Cairo, QPainter, Skia, ImageMadick(Magick++), ... guy.

Hell I could even show you how to integrate OpenSceneGraph.

Shaders are beyond my capability's :) sorry

If you have a question just ask, here on the forums. I am unlikely to answer any private messages.

dydya-stepa

  • Jr. Member
  • **
  • Posts: 82
    • View Profile
sdl user but I'll switch
« Reply #14 on: January 18, 2012, 08:51:14 pm »
i dont care about shaders. i'm interested in approach. i can implement myself whatever i'll have to. even pseudocode would be sufficient.

maybe you know if there's a glow in those libraries - should i take a closer look? maybe you know what options exist to create a glow

 

anything