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

Pages: [1]
1
Graphics / Re: Smooth movement.
« on: October 03, 2013, 11:30:58 pm »
Ok, seems that me and my brother have better frame perception o.O
I send to some friends and they also didn't see the problem.
This is awkward. Thank you anyway ^^

2
Graphics / Re: Smooth movement.
« on: October 02, 2013, 11:12:52 pm »
Yes, i was thinking that may be my pc, but i tested on another and see the same..
https://dl.dropboxusercontent.com/u/8711710/base_testing.rar
2 images, 2 .exe (with and without frame limit for comparison), and source. no dlls.

3
Graphics / Re: Smooth movement.
« on: October 02, 2013, 10:08:10 pm »
Unfortunately doesn't work. ;(
I also have the same code on SDL and there it uses your solution since SDL_Rect positions are ints, but it shows the same problem.
Thank you anyway ^^
Im starting to think that my eyes see more frames that it should ;)

4
Graphics / Re: Smooth movement.
« on: October 02, 2013, 10:28:08 am »
hm, right, thanks ^^
But the problem is really that small jumps that occurs when render at 60 fps.
It get better at 75, and are almost gone at 100fps (and vanish with more).
The delta time is very stable so i was unable to detect where this jumps come from.

5
Graphics / Re: Smooth movement.
« on: October 02, 2013, 03:50:34 am »
Same problem.
Only render more than 60fps make it look smooth.
If I update the movement at 30fps and render at eg. 100fps, its looks ok. Which is the reverse of what I read o.O

6
Graphics / Smooth movement.
« on: October 01, 2013, 08:15:54 am »
I see a lot of this topics and still doesn't work for me:
    sf::RenderWindow window(sf::VideoMode(640, 480), "My window");
        window.setFramerateLimit(60);
       
        sf::Texture tex;
        tex.loadFromFile("bomberman.png");
        sf::Sprite sprite;
        sprite.setTexture( tex );      

        auto move = 100.f;
        auto dt   = 0.f;
        sf::Clock clock;
    while (window.isOpen()){        
        sf::Event event;
        while (window.pollEvent(event)){    
            if (event.type == sf::Event::Closed)
                window.close();
        }  
        sprite.move( move * dt, 0 );

        window.clear();        
        window.draw( sprite );
        window.display();

        auto& pos = sprite.getPosition();
        if((pos.x > 640) || (pos.x < 0)) move = -move;

        dt = clock.restart().asSeconds();                    
    }
 

The sprite speed up randomly (small but perceptible jumps).
I read about here
http://gafferongames.com/game-physics/fix-your-timestep/ and here http://gamedev.tutsplus.com/tutorials/implementation/how-to-create-a-custom-2d-physics-engine-the-core-engine/.
Implemented the timestepping and the interpolation rendering.
Implemented everything on sdl2.
Tried also on different computers.
And run the sfml examples.
All have the same problem.
And in all cases, without frame limit or vsync (or with framelimit >=75 (+-) ) all runs smooth.
At 60fps or less the problem continues.

Thank you for the patience!

7
Well...
if you comment this:
//box.setOutlineThickness(2.0f) ;  /* REQUIRED FOR RENDERING FAILURE */
and change the first draw order:

// window.draw(box) ;
// window.draw(text) ;  
   window.draw(text) ;
   window.draw(box) ;

You get the error again.. in the second draw o.O.

8
Nice, the same problem ^^.
Same config as above, but Radeon HD 5800.
And I´m just get the latest src to verify.

9
DotNet / SFML-2 and Boo
« on: November 30, 2011, 03:42:05 am »
Hello, I will try to work with SFML-2 and Boo Language but I need the dll files to work with. There is some place where I can get it?

10
Python / Help with PySFML
« on: November 30, 2011, 02:40:04 am »
I tried to compile on windows too with no success..
But Bastien already help us  :D

https://github.com/downloads/bastienleonard/pysfml2-cython/python2-sfml2-cython-win32.zip

11
Python / pysfml2-cython
« on: November 28, 2011, 08:55:10 pm »
Well, I try this:
(in a pyx file)
Code: [Select]

cdef class Obj:      
    def python_method(self):    
        #operations
        pass
   
    cpdef cpython_method(self):
        #operations
        pass

import time

cdef Obj obj = Obj()

i = time.clock()

#cdef int x

for x in range(1000000):
    obj.python_method()

f = time.clock()

print "python_method %f" % (f-i)

i = time.clock()

for x in range(1000000):
    obj.cpython_method()

f = time.clock()

print "cpython_method %f" % (f-i)


I expected a fast loop with cpython_method, but there was only a little speed up. Then uncomment this "#cdef int x" and Voilá. Great speed up!(At least here, hundred of times faster).

I think this is nice i.e. for things like moving the main draw loop (that use Sprite.Draw)  in a cython 'for loop'.( Or any other loop that use a lot of python (slow)method calls)

12
Python / pysfml2-cython
« on: November 28, 2011, 12:54:39 pm »
Hello, first let me thank you for this excelent game lib and for port it for python/cython  :D

Isn´t  a good idea make the cython-sfml methods with cpdef  instead of def ?
If someone code with cython and import the lib , they can take advantage of c-speed method call.

Thank you in advance.

Pages: [1]
anything