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

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Svenstaro

Pages: [1]
1
General discussions / Requesting patch release
« on: December 21, 2013, 02:32:29 pm »
I'd like to request a patch release 2.1.1 since 2.2 will probably still take some time and since there have been some important fixes in git master.

2
Graphics / Antialiasing le broken?
« on: March 26, 2011, 12:46:37 pm »
Hi, I'm having trouble getting antialiasing to work, causing my shapes to look ugly.

Le minimal code: https://gist.github.com/888217

Result:
Code: [Select]
g++ -lsfml-graphics -lsfml-window -lsfml-system antialiasing_test.cpp
./a.out
Antialiasing level: 0
and thus a ugly pixelated shape.

I tested this on two computers running Arch Linux x86_64, one with NVIDIA proprietary drivers, one with Gallium3D drivers.

3
System / Locale problem
« on: February 07, 2011, 04:22:34 am »
SetString on a sf::Text in sfml2 gets me this
Quote
terminate called after throwing an instance of 'std::runtime_error'
  what():  locale::facet::_S_create_c_locale name not valid

This only happens on a mingw compiled version of my program. A native GCC version doesn't show this problem. The issue likely is that mingw only really has the "C" locale and my environment wants my local locale.

Running the mingw generated executable in wine with LC_ALL=C works. However, I think this should be fixed in SFML itself. The code in Utf.cpp tries to handle this problem, but somehow fails still. Shouldn't it return std::locale("C") if there is a problem?

Also, somehow it never enters the catch block for me.

Laurent, can you look into this?

4
General discussions / SFML1 -> SFML2 porting notes?
« on: July 04, 2010, 09:54:47 pm »
SFML2 appears to be somewhat usable so I'm curious whether there are any porting notes available? It appears that there were quite a few changes from SFML1 that are more than just a few changes API entries.

5
Graphics / Problem with outdated image libraries
« on: April 04, 2010, 12:37:36 am »
In a recent attempt to use ImageMagick in conjunction with SFML I literally spent hours tracing down a bug that I do not want other users to stumble into.

SFML currently provides its own versions of libpng and libjpeg directly in its source tree. That in itself isn't a huge problem but when you link a library that has a different version of libpng there will be trouble along the lines of:
Quote
terminate called after throwing an instance of
'Magick::ErrorResourceLimit'
  what():  Magick: memory allocation failed `test.png' @ error/png.c/WriteOnePNGImage/6433
Aborted

It may look like an ImageMagick bug but it is actually a libpng API mismatch since ImageMagick builds in libpng 1.4 and SFML still uses libpng 1.2. A similar conflict can be observed with libjpeg.

A quick fix to this is to update those outdated libs now (SOIL probably as well) and in the long run give distro packagers a make target for using system-available packages.

Windows users probably don't care to have the versions of the external libs match up with their system installed ones as most people will not install those system wide. Windows users will still benefit from updated libpng and libjpeg versions.

6
Window / Fully transparent window with only SFML drawings?
« on: March 20, 2010, 05:55:24 pm »
Hi,

I'm aware this question has been asked before but it has not been solved. I looked into this quite a bit and it turns out that this is a complex problem after all. I "only" want to have a fully transparent window with per-pixel alpha SFML drawings on top. I also aware that this is a non-trivial task. I settled on using Qt and SFML in combination to get the best odds in solving this.

Basically, I figured I'll want two codepaths for my window-less application:

Path 1 is without a compositing window manager (No Kwin, Aero or Compiz active). It will just take a screenshot at the beginning using Qt since SFML can't do that for me yet, sadly (hint, hint), and put it as the window background with the correct subrect. This works and obviously is sub-optimal.

Path 2 is the part I'm struggling with. I'd like to make use of an available desktop compositor as many modern desktops are running one. This will save me from the screenshotting but presents me with other problems. SFML can't make a transparent window and thus I used Qt with the window attributes Qt::WA_NoSystemBackground and Qt::WA_TranslucentBackground. This works (the window is transparent when a compositor is active) but this is also the place where I'm struggling.

I now need to get my SFML data into Qt somehow draw it on top. Or can I directly use the SFML canvas trick from the tutorials and somehow make it transparent? Clear() can't clear to alpha.

Help :D

7
Network / Proper UDP communication questions
« on: January 07, 2010, 06:29:43 pm »
Hey there,

I'd like to use UDP for my game in favor of TCP but I hit some roadblocks and like to ask questions about those here.

First, how would I use selectors with UDP since I have no connected selection between server and client which can determine which packages to get. Do selectors in UDP even make sense?

Then, how can I have easy two-way communication using UDP? To my understanding, I need open, bound and forwarded ports on both sides which is inconvenient for Internet play. How do others solve this problem with UDP?

Thanks in advance.

Pages: [1]