| View previous topic :: View next topic |
| Author |
Message |
rodo
Joined: 08 Nov 2006 Posts: 10
|
Posted: Wed Nov 08, 2006 1:04 am Post subject: RxPixelGetColor and RxPixelSetColor too slow |
|
Hi,
Code: click into code to enlarge
for (mx = 20; mx < 25; ++mx)
{
for (my = 20; my < 25; ++my)
{
RxPixelSetColor(mx+500, my+500, RxPixelGetColor(mx, my));
}
}
Why does it take about 5 sec to finish this example?
I am using a 2.6MHz computer, VC++ .NET, Win XP, release-compiled program.
Thanks
rodo |
|
| Back to top |
|
 |
admin Site Admin
Joined: 05 Jul 2006 Posts: 351
|
Posted: Wed Nov 08, 2006 9:14 am Post subject: |
|
It was a bug, we fixed it for the next release.
But i think you can easily write a workaround as follows:
Code: click into code to enlarge
DWORD oldSleepTime = RxGetSleepTime();
RxSetSleepTime(0);
for (mx = 20; mx < 25; ++mx)
{
for (my = 20; my < 25; ++my)
{
RxPixelSetColor(mx+500, my+500, RxPixelGetColor(mx, my));
}
}
RxSetSleepTime(oldSleepTime);
Please try it and answer me the new time.
Jenö Herget
Ranorex Team |
|
| Back to top |
|
 |
rodo
Joined: 08 Nov 2006 Posts: 10
|
Posted: Wed Nov 08, 2006 7:49 pm Post subject: |
|
Thanks for your help!
Now it takes less than 1ms.
Brds
rodo |
|
| Back to top |
|
 |
rodo
Joined: 08 Nov 2006 Posts: 10
|
Posted: Wed Nov 08, 2006 11:35 pm Post subject: |
|
Hi,
is there any possibility to copy an area instead of only one point?
I'd like to copy about 1000x500 pixels - this takes about 1.5 sec using RxPixelGetColor...
Thx,
rodo |
|
| Back to top |
|
 |
admin Site Admin
Joined: 05 Jul 2006 Posts: 351
|
Posted: Thu Nov 09, 2006 10:50 pm Post subject: |
|
| rodo wrote: |
| is there any possibility to copy an area instead of only one point? |
Not at the moment, i'm sorry.
But we will support some graphic features in future versions.
Jenö Herget
Ranorex Team |
|
| Back to top |
|
 |
|