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

Pages: 1 2 [3] 4 5 ... 16
31
SFML projects / Re: Neural Network + Genetic Algorithm
« on: December 09, 2017, 06:57:15 am »
Nice! If you like that can of things, you can have some fun with particle swarm optimization (PSO) as well.

Thank you :) Yep, maybe some time later.

32
Graphics / Re: Screen only displays movement when mouse is moving
« on: December 07, 2017, 04:04:06 pm »
Okay! I have a source formatting plugin for code blocks IDE. first I'll use my format then i will use the formatting plugin when I release  it or ask for help.
Also, Is it impossible for you to answer my question because of its format it!?

I already answered your question in my first post here. I've posted your wrong part and fixed part

33
Graphics / Re: Screen only displays movement when mouse is moving
« on: December 07, 2017, 03:43:33 pm »
Well, I kinda use my own style format like this
void see this(args){if(6==7){
}
}
 
And yes I've looked at other projects it get confusing sometimes in their format

You can't find this error by yourself only because this kind of formatting.

34
SFML projects / Re: Neural Network + Genetic Algorithm
« on: December 07, 2017, 08:44:07 am »
Impressive stuff, Alexander!

Thank you, Stefan  :)

35
Graphics / Re: Screen only displays movement when mouse is moving
« on: December 07, 2017, 07:03:53 am »
Why do you write code like this? Have you ever took a look at code formatting on some other projects?

window.close();}
playerRect.move(1,0);
if(sf::Keyboard::isKeyPressed(sf::Keyboard::Down)){playerRect.move(0,1);}
if(sf::Keyboard::isKeyPressed(sf::Keyboard::Up)){playerRect.move(0,-1);}
if(playerRect.getGlobalBounds().intersects(targetrect.getGlobalBounds())){window.close();}}

window.close();}}
playerRect.move(1,0);
if(sf::Keyboard::isKeyPressed(sf::Keyboard::Down)){playerRect.move(0,1);}
if(sf::Keyboard::isKeyPressed(sf::Keyboard::Up)){playerRect.move(0,-1);}
if(playerRect.getGlobalBounds().intersects(targetrect.getGlobalBounds())){window.close();}

36
SFML projects / Neural Network + Genetic Algorithm
« on: December 06, 2017, 03:23:09 pm »
After watching a lot of videos on YouTube I had some fun playing with neural networks + genetic algorithm. Don't know what else to say  :D

Source code: https://github.com/achpile/neural

http://www.youtube.com/watch?v=cAr90JQVxaI

http://www.youtube.com/watch?v=oeJ7Gw_vO_8

37
SFML projects / Re: Screenshot Thread
« on: November 30, 2017, 11:22:51 am »
Some workarounds on new game
http://www.youtube.com/watch?v=oJg4qipjbpE

38
Graphics / Re: TileMap show artifacts
« on: November 27, 2017, 05:46:19 pm »
that's because you have some errors in your code

39
General / Re: Static Linking SFML with MinGW in Eclipse
« on: November 25, 2017, 06:02:08 pm »
Maybe some lines from my CMake file could help :)

        SET ( CMAKE_CXX_FLAGS  "-DSFML_STATIC -s -std=c++11" )
        SET ( CMAKE_EXE_LINKER_FLAGS  "-mwindows -static-libgcc -static-libstdc++ -static -Wl,-Bstatic -Wl,-rpath,./lib/" )
        SET ( CMAKE_LINK_LIBS sfml-audio-s sfml-graphics-s sfml-window-s sfml-system-s winmm opengl32 gdi32 freetype glew jpeg opengl32 openal32 pthread FLAC vorbisfile vorbisenc vorbis ogg sndfile )
 

40
Thank you for the advice.I guess?
But I already knew that and I'm currently studying this library.
And how does that answer my question?

So if you already knew that - why don't you do that? You call display only on getting resize event

41
you should draw and display inside the main loop every time, not only in events handling.

42
Graphics / Re: Animation speed way to fast.
« on: November 25, 2017, 11:39:24 am »
because you didn't declared variable called "view"

43
Graphics / Re: Fill sf::Sprite with constant color
« on: November 24, 2017, 07:41:41 pm »
I used this one

#define SHADER_WHITE                                          \
        "uniform sampler2D texture;                             " \
        "                                                       " \
        "void main() {                                          " \
        "    vec4 pixel = texture2D(texture, gl_TexCoord[0].xy);" \
        "                                                       " \
        "    pixel.r = 1.0f;                                    " \
        "    pixel.g = 1.0f;                                    " \
        "    pixel.b = 1.0f;                                    " \
        "                                                       " \
        "    gl_FragColor = pixel;                              " \
        "}                                                      "

 

OP wants it to ignore transparent pixels though

as you can see i do NOT change the pixel.a value

44
Graphics / Re: Fill sf::Sprite with constant color
« on: November 24, 2017, 05:21:27 pm »
I used this one

#define SHADER_WHITE                                          \
        "uniform sampler2D texture;                             " \
        "                                                       " \
        "void main() {                                          " \
        "    vec4 pixel = texture2D(texture, gl_TexCoord[0].xy);" \
        "                                                       " \
        "    pixel.r = 1.0f;                                    " \
        "    pixel.g = 1.0f;                                    " \
        "    pixel.b = 1.0f;                                    " \
        "                                                       " \
        "    gl_FragColor = pixel;                              " \
        "}                                                      "

 

45
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 22, 2017, 04:09:44 pm »
I tried to reproduce this issue on my laptop but couldn't. Since I haven't upgraded to High Sierra yet, I also tested in a VM but still couldn't reproduce the issue.

Now, using a VM is far from perfect to test such things, but it would be great if this bug could be reproduced by someone else using similar hardware as you do.

BTW, (if there's a bug) I'm not sure it's the same bug as #1132; the symptoms look too different.

Thanks for your time :) Laptop is "Pro Mid 2014" as I know.
Yeah, probably app will work fine on other configurations, but I made drawing black square just for sure  :)

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