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

Pages: [1] 2
1
General / Re: C++ SFML how to add movie/scene?
« on: January 29, 2013, 02:58:21 am »
lol? Yes I do know how to program with C++, I don't understand why you would assume me not knowing how lol. Maybe I haven't mastered it (as it's impossible to do so, since the language is so esoteric and is always growing) but I have the basics down, etc.

Edit: Yes.. by programming.  :P

Edit 2: I think I'll stick with loading and playing back the loaded file. Thanks for your help!

2
General / Re: C++ SFML how to add movie/scene?
« on: January 29, 2013, 01:46:18 am »
Wow that's cool. This is what I mean though, I wanted to know how you can make a scene to show the players. Would I make a video in some kind of video format and play it? I don't know :S

3
General / Re: C++ SFML how to add movie/scene?
« on: January 29, 2013, 12:49:33 am »
Basically just playing a scene at the start before the main menu so they have a little bit of story. Nothing else really after that, just basic animation from sprite sheets. It'll contain a story animation and some music.

Which brings up another question actually, I'm interested if there's an alternative way to do animation apart from sprite sheets? This is 2D by the way, not 3D.

4
General / Re: C++ SFML how to add movie/scene?
« on: January 29, 2013, 12:11:42 am »
SFML doesn't support movies directly, but there are a few project on the forum, that make use of FFMPEG, the best known one is the sfMovie Project.
But FFMPEG is not the only way to do thing. You can for example also animate the scene directly with SFML or one could make use of gstreamer (there should also be something in the project section) or many many other ways. :)

How could you animate the scene directly using SFML? I was thinking of doing frame by frame (picture by picture), but again, not practical.

5
General / C++ SFML how to add movie/scene?
« on: January 28, 2013, 06:03:43 pm »
Hi, I looked around on google but couldn't find an answer.

What I wanted to know is how you can add a movie/scene to the game? For example, I come from a Flash background and all you had to do was create your scene in a Movieclip, then you could just export it and basically add it to your game. Or do a more and unorganized way, do it directly on the timeline.

How could you achieve this in C++ and SFML? I was thinking about having multiple png files and drawing that to the screen but obviously, this is impractical and a big waste of memory (having to load every single png file, etc).

I'm completely stumped and I don't know how you could achieve this.

Thanks.

6
Thanks, I got it working now.

7
SFML/Graphics.hpp error is gone but I'm getting cannot find "-lsfml-graphics", etc because I didn't include the SFML/lib folder. I tried using include_directories but it doesn't work. I've tried using find_package but I needed sfml.cmake and stuff.

Is there any way to include the lib folder? I've looked at existing projects using cmake but they were all very confusing. All I need right now is how to include the lib folder.

Thanks.

8
Hi, thanks, MinGW works but I'm still getting errors saying SFML/Graphics.hpp no such file or directory.

Thanks.

9
Hi, I'm new to CMake and Make and want to cross compile between Linux and Windows all in one CMakeLists.txt.

I've looked up online on a few tutorials, got some basics down but there's only one problem, on my windows computer I don't have environment path variables setup and that MinGW is on a USB drive. This is how my current CMakeLists.txt looks like.

cmake_minimum_required(VERSION 2.8)

set(PROJECTNAME "Pong")
project(${PROJECTNAME})

aux_source_directory(src/ Sources)
add_executable(bin/${PROJECTNAME} ${Sources})
target_link_libraries(bin/${PROJECTNAME} sfml-graphics sfml-window sfml-system sfml-audio)
include_directories(D:/SFML/include)

So basically what happens is, is that I have to specify my C and CPP compiler which I've already done by doing "cmake -G "MinGW Makefiles" -DCMAKE_C_COMPILER=D:/MinGW/bin/gcc.exe -DCMAKE_CXX_COMPILER=D:/MinGW/bin/g++.exe" But now I have to somehow specify the lib folder too, which I don't know how. I looked at add_library but it was confusing.

Also, this is geared towards the Windows platform. How can I make it so that it has an if statement and sees whether the system is Linux or Windows?

Thanks.

TL:DR: How do you add SFML lib folder to CMakeLists.txt file? How do you check whether the system is Linux or Windows?

10
It's most probably i3-wm's fault and/or your setup...
Have you ever run any other OpenGL application with i3-wm?

Also does your testing code simply create a window?

Yeah it's probably i3-wm's fault; and no I haven't run any other OpenGL with i3-wm. No, my testing code doesn't create a simple window, it's an actual Pong game I made. However, even creating a simple window still causes this. I think the cause of this problem is that i3-wm automatically tiles it. I looked up on how to start a program without automatically tiling it, but no results.

It'd be nice if someone could fix this problem though.

11
Hi, I'm creating SFML games/applications on Arch Linux using i3-wm, a tiling window manager.

For some reason, I get really weird things happening such as things being wrong size, etcetera. Here's a picture of this happening:  http://i46.tinypic.com/v4v7g1.png As you can see, the resolution is 1024 x 768 and the paddles and ball are not the right size. Furthermore, they're in the wrong place and it seems as if the game has been scaled down with a bunch of space not being used up.

Also, when I start the program in the terminal and then I put it into floating mode (not tiled mode), the program doesn't update the display until a click happens. http://i46.tinypic.com/2vb7p83.png

When I compile the same code in Windows, it doesn't happen. It only happens in Linux when using a tiling window manager. How do I fix this? Thanks.

12
Thanks for the help.

13
However, can someone explain why now it doesn't require libgcc_s_dw2-1.dll and libstdc++-6.dll?
If you run it from with in the MSYS, then it will already have the compiler's binaries in PATH, which includes libgcc and libstdc++.
The other explanation would be, that the libs got linked statically.

Also, is there a way to hide the command prompt that pops up after I open the program?
You have to set the subsystem to windows instead of console and then link against sfml-main.
For debugging purposes I advise you though to keep the console, so you see SFML's, OpenGL's and your own error messages.

Ah I see, thanks! I was using MSYS, which is why it didn't complain.

And can you tell me how I can go about setting the subsystem to windows instead of console and then link against sfml main? And yes, for debugging purposes I will keep the console, but I need to know how to do this because I know some people will complain about seeing this command prompt being shown every time they run my program.

Thanks for the help.

14
Thanks, it works now! However, can someone explain why now it doesn't require libgcc_s_dw2-1.dll and libstdc++-6.dll? Also, is there a way to hide the command prompt that pops up after I open the program?

15
Ah I see, okay, I'll recompile SFML if that works. Also, is there any reason why it isn't compiled using GCC 4.7.2?

Pages: [1] 2