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 - eXpl0it3r

Pages: 1 ... 602 603 [604] 605 606 ... 721
9046
Graphics / AW: Re: Shape doesn't compile
« on: December 18, 2012, 11:51:38 am »
There is a boolean in sf::Shape that is private. When I use MSVC++ 2010 debug mode I can 'watch' a variable or what have you. The boolean is something like isCompiled or myIsCompiled or some such name and it shows up as false. So I wondered if anyone here might know what that means...obviously not.
And I should've guessed that how? ???
If you're already looking at implementation details you could've also looked how and when that boolean gets set.
I'd guess that your described shape is a concave shape and iirc SFML 1.6 as well as SFML 2.0 provides only direct support for convex shapes.

As for 2.0 I would use it if there were a tutorial on how to get it up and running. The download page says to "wait until the final version is released, and tutorials are written. " so in an effort to not annoy the piss out of people here, I abstain. Also tutorials I've looked at elsewhere are either incomplete or incorrect, or something on my pc is broken.
The offical tutorials on how to set things up are already finished and complete for SFML 2. What other sources say I can't judge, but it's often the case that they get outdated.

I wonder when posting links to board rules got started as a way of answering a question. All it seems to do in most cases is annoy the hell out of people. That was a musing, not a flame btw.
If you had taken your time to read the rules you'd have seen in the last post how to write a good post and if then had compared it to your post it would've gotten clear to you what I wanted to point out. ;)

And again if you want solutions to your problems quickly, it's important to not hold back information or assume that somthing is well known and most impotantly provide a minimal and complete example that reproduces your problem. ;)

9047
General discussions / Re: Unofficial Nightly Builds
« on: December 18, 2012, 01:42:58 am »
Thanks for pointing it out, got already fixed! :)

New builds will get uploaded later today. ;)

9048
Graphics / Re: Laggs when drawing.
« on: December 17, 2012, 09:46:24 pm »
If you don't allocate the space dynamically but statically your tiles will be continues in memory and thus the cache misses of the CPU will be reduced. If you allocate it manually on the heap, you'll get pointers to arrays and there will be more cache misses. If that's the case here isn't really obvious, but it might.

I suggest three things:
  • Don't use arrays, but vectors.
  • Don't use multi-dimensional containers, but use one big container and calculate the multi-dimensions on your own.
  • Don't use sprites for tile-maps but vertex arrays to get skyrocketing performances. ;)

9049
Graphics / Re: Shape doesn't compile
« on: December 17, 2012, 07:06:17 pm »
What I mean to say is the shape says it isn't compiled.
Where and what does say it doesn't get compiled? ???

We're not magician who can see what you've written, if you want us to help you need to provide the code. Also read this.

Anyways I'd strongly advice you to use SFML 2.0, because SFML 1.6 has some serious bugs, hasn't been maintained in over two years and lacks a lot of features that SFML 2 provides (e.g. sf::VertexArray, sf::RenderTexture, etc..).

9050
Graphics / Re: Shape doesn't compile
« on: December 17, 2012, 06:40:19 pm »
Wait what? You're able to run an application that doesn't compile? ???

If you want help you need to provide the complete and minimal code that reproduces the problem... ;)

9051
Audio / Re: sf::Music is running my cpu at 40-100%?
« on: December 17, 2012, 01:18:27 pm »
Have you now added the directory to libraries to your search path? Because it's missing in the cbp file posted.

Here is one of my Code::Blocks project file, which I often use and which works fine:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<CodeBlocks_project_file>
        <FileVersion major="1" minor="6" />
        <Project>
                <Option title="Support" />
                <Option execution_dir="D:/Programming/CPP/Support/" />
                <Option pch_mode="2" />
                <Option compiler="gcc" />
                <Build>
                        <Target title="Debug">
                                <Option output="bin/Debug/Support" prefix_auto="1" extension_auto="1" />
                                <Option object_output="obj/Debug/" />
                                <Option type="1" />
                                <Option compiler="gcc" />
                                <Option use_console_runner="0" />
                                <Compiler>
                                        <Add option="-g" />
                                </Compiler>
                                <Linker>
                                        <Add library="sfml-graphics-d" />
                                        <Add library="sfml-window-d" />
                                        <Add library="sfml-audio-d" />
                                        <Add library="sfml-system-d" />
                                </Linker>
                        </Target>
                        <Target title="Release">
                                <Option output="bin/Release/Support" prefix_auto="1" extension_auto="1" />
                                <Option object_output="obj/Release/" />
                                <Option type="1" />
                                <Option compiler="gcc" />
                                <Option use_console_runner="0" />
                                <Compiler>
                                        <Add option="-O2" />
                                </Compiler>
                                <Linker>
                                        <Add option="-s" />
                                        <Add library="sfml-graphics" />
                                        <Add library="sfml-window" />
                                        <Add library="sfml-audio" />
                                        <Add library="sfml-system" />
                                </Linker>
                        </Target>
                </Build>
                <Compiler>
                        <Add option="-Wall" />
                        <Add directory="D:/Programming/libraries/SFML/include" />
                </Compiler>
                <Linker>
                        <Add directory="D:/Programming/libraries/SFML/lib" />
                </Linker>
                <Unit filename="Main.cpp" />
                <Extensions>
                        <code_completion />
                        <envvars />
                        <debugger />
                        <lib_finder disable_auto="1" />
                </Extensions>
        </Project>
</CodeBlocks_project_file>
 

Obviously if you'd use it, you'll need the specified paths.

9052
Audio / AW: Re: sf::Music is running my cpu at 40-100%?
« on: December 17, 2012, 10:33:21 am »
And you've also changed the library search path to /.../SFML-2.0/lib, or are you still linking the 1.6 libs?

9053
Audio / AW: sf::Music is running my cpu at 40-100%?
« on: December 17, 2012, 10:20:30 am »
It seems you're not linking the needed libraries (sfml-graphics, sfml-window, sfml-audio, sfml-system).
What compiler and IDE are you using?

9054
SFML projects / Re: Black Knight Blockade (Minigame)
« on: December 17, 2012, 12:23:03 am »
Do you have anything else about your LD entry? Blog, video time lapse ect.
It doesn't seem like he did a time lapse or something, but he's Smaxx on the LD website.

9055
General / Re: Building C::B 8.02 + mingw = 'NULL' not declared
« on: December 15, 2012, 12:07:32 pm »
You are aware that you answered to an over one year old thread and that Code::Blocks in the meantime is at version 12.11 and if chosen ships with TDM-GCC 4.7.1?
If not, now you know it and the whole problem doesn't exist anymore. :D

9056
System / AW: Question about Time.hpp
« on: December 15, 2012, 08:22:36 am »
As Nexus said the implementation is in the Time.cpp file, e.g. see on GitHub.

9057
Have you built SFML on your own or are you still using SFML 2.0RC which is 'known' for crashing due to the default font. ;)

9058
General / Re: if statement and drawing to window problem...
« on: December 14, 2012, 06:14:10 pm »
You should use the code=cpp tag in the forum to post code... ;)

sf::Keyboard::isKeyPressed as well as sf::Mouse don't have anything to do with events, so don't process them in the event loop! Also the collision check has nothing to do with events, so don't put it in the event loop (while(window.pollEvent(event))).
You're aware though that object and object2 are rendered to the same position and thus only one might get displayed?

Additional tips:
  • Always use forward slashes!
  • You have to call srand() before rand() and if you're using a compiler with C++11 support you might want to look into the new random generator.

9059
SFML projects / AW: SFML Light System - Let There Be Light
« on: December 14, 2012, 11:14:27 am »
This looks really great!
You should open a thread in the project section of this forum, so more people could discover it. :)

9060
Graphics / AW: Re: Drawing lines in SFML 2.0
« on: December 14, 2012, 11:08:56 am »
Sure I could do that, but how do I actually remove a vertex from the VertexArray at all?
You don't... ;)
If you want more than sf::VertexArray offers you can use std::vector<sf::Vertex> directly.

Pages: 1 ... 602 603 [604] 605 606 ... 721