Poor 'move' performance in 4.0+ engines?

Visuals, audio, animation. Blended, not stirred. If LiveCode is part of your rich media production toolbox, this is the forum for you.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
pkocsis
Posts: 105
Joined: Sat Apr 15, 2006 7:20 am

Poor 'move' performance in 4.0+ engines?

Post by pkocsis » Mon Feb 08, 2010 12:12 am

I have an application that has functionality to scroll text across the bottom of the screen...something like the news scrolls you see on cable news networks.

I accomplish this with a field and the move command. Of late I have been working with windows 7 machines that have very fast dual core processors and dedicated GPU's. I have had a problem though where my scrolling text has become very jerky. It is not moving nearly as smooth as some of my existing installations which are on lesser machines.

At first I was thinking it was a difference in the new OS and possibly graphics drivers, but I'm not so sure now...

In trying to figure out what the heck has happened, I think I'm coming to the conclusion that the 4.0 and beyond rev engines' 'move' command is not working nearly as efficiently as previous rev builds. Since I have not updated some of my existing installations yet, they are still using a version of my software that was built with pre-4.0 rev engines. My testing would indicate that this is the culprit. (I have existing installations on both XP and Vista. It seems that the Vista machines with builds using the 3.5 engine have much smoother 'move' action than the Vista machines with 4.0 engine builds)

I'm seeing such a disparity that I am surprised that folks that may be programming games or other applications that involve moving objects have not noticed a deterioration in the smoothness of their moving objects in rev 4.0.

I'm trying to quantify/document the poorer performance to file a bug report. Maybe since my fields are rather large, the poorer 'move' performance is magnified as compared to others that may be 'move'ing smaller objects.

I take note that the architecture of a standalone in 4.0 rev has significantly changed relative to earlier rev builds.

Can anyone help confirm or deny the existence of jerky object movement in 4.0 engines vs. previous rev builds?

Thanks!

EDIT: A final PS: In testing, I have coded a small routine with a repeat loop that contains a 'wait with messages' in it to control the scroll speed; it increments the position of the field's location to create movement. This routine moves the field across the screen absolutely smoothly without jerkiness vastly beyond what I can accomplish with a simple 'move' command. I'm semi-appalled that I can code 'manual' movement in a handler and end up with performance that so vastly outperforms a single move statement. I would've thought that the engine doing the movement would/should be better than anything I can code manually in a handler, but this is not the case...

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Re: Poor 'move' performance in 4.0+ engines?

Post by Mark » Wed Feb 10, 2010 6:32 pm

Dear pkocsis,

Please post your script!

I have created a stack with a lot of moving things. You can find it here.

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

pkocsis
Posts: 105
Joined: Sat Apr 15, 2006 7:20 am

Re: Poor 'move' performance in 4.0+ engines?

Post by pkocsis » Wed Feb 10, 2010 9:23 pm

Hi Mark,

Thank you for replying! Your stack does indeed move the objects smoothly on my XP machine. Oddly enough, the most problem I'm having is on Windows 7. I am in the process of building another Windows 7 machine. I shall test your stack there.

I also think that the move performance might deteriorate as the size of the object grows. I am moving a single field across the bottom of the screen. It is generally 40 to 100 pixels in height, depending upon the screen resolution. Oddly enough, my XP users have always experienced quith smooth 'move' performance, while my new users with Vista or Windows 7 along with very fast CPU's and beefy graphics cards are the ones experiencing jerky movement. Manipulating the syncRate helps some, but unfortunately not quite enough. I would post my stack but it is part of a very large project. I intend to put together a test stack that exhibits the behavior I am experiencing and will post it once I'm convinced that it works well on some machines and inadequately on others. It's the 'other' machines that is dragging this out for me. I only have limited time with others' machines, so I must wait till i get offending machines in house in order to verify my theory....

Thanks again Mark!

pkocsis
Posts: 105
Joined: Sat Apr 15, 2006 7:20 am

Re: Poor 'move' performance in 4.0+ engines?

Post by pkocsis » Mon Mar 01, 2010 9:26 am

Hello again Mark,

I will have my hands on another client windows 7 machine soon. I will try your stack on it and compare the performance against an XP machine.

Here is what is frustrating me so....

If I make a simple stack that does nothing but move a large text field (48 pt or larger) across the screen, on XP it is smooth as butter.....I take that same test stack to a 3.6GHz dual-core processor (with a 9800 gtx+ card in it) and try it....the text is *really* jerky. The default syncRate in rev 4.0 has been upped from 9 to 20, so if I lower the syncRate, I can improve on the jerkiness, but it still looks bad. The frustration is that this test stack works smoothly on an XP celeron CPU machine and outperforms (by a loooong shot) a very fast dual or quad-core (with major graphics cards) win 7 machine(s). Since my moving object is text that folks look at and read on large LCD TV's, the jerkiness is really noticable, to the point where my text scroll looks really bad and has become useless on win7 machines. Again, the test stack does *nothing* but a 'move' command. I don't know the internals of rev or how it renders (gdi bitblt?), but I'm contending that the performance on win7 is horrendous compared to xp. Again, keep in mind that since it's text I'm scrolling, the jerkiness is *really* pervasive since folks are looking at it and trying to read it while its moving. This might not be so noticable if it were a picture vs. words...

Post Reply