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.


Messages - Haze

Pages: 1 2 [3] 4 5 ... 9
31
General discussions / Re: A new logo for SFML
« on: April 12, 2013, 03:28:13 pm »
I really like krzat's contribution. I suppose I've associated SFML with an ellipse for a too long time :)
With new colorscheme, lighting and drop shadow:




Here some integration tests based on his logo:




With Cornstalk's font:




I like the idea of the acronym "SFML" being a part of the logo itself, I think the logo will be more identifiable that way.
While I also like the concept of a pentagon/power button, a multimedia library is something too much abstract to be easily represented by just a pictograph, and it's hard to have a distinctive visual representation.


[attachment deleted by admin]

32
General discussions / Re: A new logo for SFML
« on: April 09, 2013, 01:07:03 pm »
Yes I prefer his green. It's almost the same that I use in the new website. In fact I think we can completely drop blue. Green and grey/black would be the new colors.

What about giving the color codes of the new website's color scheme? Or even a screenshot.
I think a lot of people are influenced by the blue/green design featured on the current website.

33
General discussions / Re: A new logo for SFML
« on: April 09, 2013, 12:06:18 pm »
- let's find less common fonts; I think Cornstalks is on the right way ;)
If I'm not mistaken by your previous comments in this threads, it seems to me you have a thing for retro-looking, bitmap-like fonts. Is this the direction to go?

34
Graphics / Re: How to draw a line between two points ?
« on: April 06, 2013, 08:39:20 pm »
Oh, sorry about that!
I assumed you've only addressed the fact the OP used a vector for just 2 vertices.


35
Graphics / Re: How to draw a line between two points ?
« on: April 06, 2013, 06:33:06 pm »
But, how can I change the color of this line ?

Each vertex has a position and a color property.
sf::Vertex line[2];
line[0].position = sf::Vector2f(10, 0);
line[0].color  = sf::Color::Red;
line[1].position = sf::Vector2f(20, 0);
line[1].color = sf::Color::Red;
 

If the two vertices of the line have a different color, you'll obtain a gradient from color 1 to color 2.

36
There's no reallocation because sf::VertexArray is based on std::vector which never frees its memory until it is destroyed.
But the number of particles will increase overtime, so if a vector doesn't have enough memory allocated, a new chunk of memory will be allocated and the old content is copied, then free'd.
But I think I overestimated this, reallocations shouldn't happen often thanks to the vector growing strategy.

Moreover, draw calls are very expensive, the graphics card is not designed for many draw calls, but rather for few calls that draw many polygons at once.
Good to know, thanks for the tip.

37
Graphics / Re: Scrolling tile map sfml2.0
« on: April 05, 2013, 09:41:54 pm »
You know anything about tile map collision detection? :P
I suggest you read about tile-based engines, there's plenty of tutorials.
This one is a good introduction:
http://www.gamedev.net/page/resources/_/technical/game-programming/the-guide-to-implementing-2d-platformers-r2936

I also like this one, very detailed with interactive demos, but it's aimed for Flash developer (the theory remains the same however)
http://www.tonypa.pri.ee/tbw/start.html

38
Just wondering, rebuilding a vertex array for each frame (which can induce memory reallocation + copy) is more efficient than drawing each particle one at a time with a different draw call?

39
SFML projects / Re: CosmoScroll - space shooter game
« on: April 03, 2013, 08:54:59 pm »
Thanks for the kind words! The source code could be greatly improved however (conception mistakes, too many singletons, half of the documentation is written in French...).
It's been a while since last release, but I'm still working on it time to time (migration from SFML 1.6 to 2.0 was a big change).

40
Graphics / Re: Scrolling tile map sfml2.0
« on: April 03, 2013, 08:09:10 pm »
I would suggest using sf::View, very handy for this kind of feature.
There's a really good tutorial about it on the SFML wiki:
https://github.com/SFML/SFML/wiki/Tutorial%3A-Using-View

41
General discussions / Re: Why change the spelling of functions
« on: April 03, 2013, 08:05:24 pm »
Quote
what_the_hell("?!?!?");[...]And now Tank comes out with his hello_stefan_convetion
I assume you don't like it? I even don't get why people use different styles for C++. In other languages people tend to stick to the naming conventions the standard lib uses, at least in Python, JavaScript, Ruby and similar languages.
Don't worry, I use the superior_cpp_naming_convention when I code in Java or JS in retaliation.

I'm also very surprised people can actually find it less readable, as I precisely prefer this naming convention for its readability.
However it makes identifiers a bit longer (thus, longer lines).

42
General / Re: Static Linking for SFML 2.0 RC on Linux
« on: April 03, 2013, 07:53:54 pm »
Why would you say it's impractical to link statically? Surely dynamic linking is just another thing that could go wrong when distributing the binary?
There's nothing wrong with static linking, but it's simply not the "linux way", and using the system shared libraries (installed from your distribution packages) is regarded as a better practice.
Libraries are usually built for shared linking, so if you intend to static link, you'll probably have to compile them yourself, which can be a serious pain.

A separate run script needs to be created to first export the LD_LIBRARY_PATH variable before executing the binary, or is there another way?
Yes, this is very easy and seems to be the more popular way for distributing stand-alone release of your project.
Just copy the .so files to a sub directory, and provide a shell launcher.
You can see an example of mine here.

43
Graphics / Re: Bug in sf::RenderTexture
« on: March 25, 2013, 01:52:06 am »
If you mean delete NULL; it's alright.
Quote
In C++, the definition of NULL is 0
Quote
deleting a zero pointer is harmless by definition
http://www.stroustrup.com/bs_faq2.html#null
http://www.stroustrup.com/bs_faq2.html#delete-zero

Huh, I didn't know that. But wasn't the point of creating the nullptr keyword in C++11 was because NULL (thus, 0) could be a valid pointer address on some obscure cases and obscure compilers? (for example, pointer to the first virtual method in a vtable, because pointer addresses can be relatives).

44
Graphics / Re: Cant load font from terminal
« on: March 11, 2013, 07:19:21 pm »
Are both the executable and the resources files located in the working directory (the one from which you launch the executable?)

45
I open this thread to collect information about all the SFML bindings that exist, for the corresponding page on the new website.
Authors of bindings for SFML may not browse the forum on a regular basis and miss this thread.
Maybe you should contact them yourself if you want an up-to-date report.

Anyway, here's a quick list of SFML bindings I've found, with contact info:


Pages: 1 2 [3] 4 5 ... 9
anything