sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #36672
[Bug 1540233] Re: ObserveScanRate vs. WaitScanRate
** Summary changed:
- ObserveScanRate without any function
+ ObserveScanRate vs. WaitScanRate
** Description changed:
+ Hi,
+
+ as far as I understood from the documentation the properties
+ WaitScanRate and ObserveScanRate should be the same function. But
+ ObserveScanRate does not change anything in my case, where WaitScanRate
+ behaves as expected. Even worse is that only the ObserveScanRate can be
+ set for a region.
+
+ Here is my test.
+
public class SikuliTest {
public static void main(String[] args) {
try {
- Region searchRegion = new Screen();
- searchRegion.setObserveScanRate(0.1f);
+
+ // Settings.WaitScanRate = 0.1f; // Does work
+ // Settings.ObserveScanRate = 0.1f; /Does not work
+
+ Region searchRegion = new Screen();
+
+ searchRegion.setObserveScanRate(0.1f); // Does not work
Long startingTime = System.currentTimeMillis();
Match match = searchRegion.wait("cancel_button.png",
Constants.FOREVER);
match.click();
System.out.println("Thread1: "
+ (System.currentTimeMillis() - startingTime) + "ms");
} catch (FindFailed e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
If I bring the desired target to the screen after the program started I
get always a similar reaction time.
[log] CLICK on L(280,194)@S(0)[0,0 2560x1440]
Thread1: 4157ms
With 0.1f I would have expected that Sikulix searches every 10 seconds
with a lower CPU usage, but it is always the same. It has also no effect
if I set the observe scan rate via the global settings. Only
Settings.WaitScanRate behaves as expected.
+
+ Edited on 03-02-2016, when I realized the difference between
+ WaitScanRate and ObserveScanRate.
** Description changed:
Hi,
as far as I understood from the documentation the properties
WaitScanRate and ObserveScanRate should be the same function. But
- ObserveScanRate does not change anything in my case, where WaitScanRate
+ ObserveScanRate does not change anything in my case but WaitScanRate
behaves as expected. Even worse is that only the ObserveScanRate can be
set for a region.
Here is my test.
public class SikuliTest {
public static void main(String[] args) {
try {
-
- // Settings.WaitScanRate = 0.1f; // Does work
- // Settings.ObserveScanRate = 0.1f; /Does not work
-
- Region searchRegion = new Screen();
-
- searchRegion.setObserveScanRate(0.1f); // Does not work
+
+ // Settings.WaitScanRate = 0.1f; // Does work
+ // Settings.ObserveScanRate = 0.1f; /Does not work
+
+ Region searchRegion = new Screen();
+
+ searchRegion.setObserveScanRate(0.1f); // Does not work
Long startingTime = System.currentTimeMillis();
Match match = searchRegion.wait("cancel_button.png",
Constants.FOREVER);
match.click();
System.out.println("Thread1: "
+ (System.currentTimeMillis() - startingTime) + "ms");
} catch (FindFailed e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
If I bring the desired target to the screen after the program started I
get always a similar reaction time.
[log] CLICK on L(280,194)@S(0)[0,0 2560x1440]
Thread1: 4157ms
With 0.1f I would have expected that Sikulix searches every 10 seconds
with a lower CPU usage, but it is always the same. It has also no effect
if I set the observe scan rate via the global settings. Only
Settings.WaitScanRate behaves as expected.
Edited on 03-02-2016, when I realized the difference between
WaitScanRate and ObserveScanRate.
** Summary changed:
- ObserveScanRate vs. WaitScanRate
+ [1.1.0] ObserveScanRate vs. WaitScanRate
** Summary changed:
- [1.1.0] ObserveScanRate vs. WaitScanRate
+ [1.1.0] ObserveScanRate without any function
--
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1540233
Title:
[1.1.0] ObserveScanRate without any function
Status in Sikuli:
Invalid
Bug description:
Hi,
as far as I understood from the documentation the properties
WaitScanRate and ObserveScanRate should be the same function. But
ObserveScanRate does not change anything in my case but WaitScanRate
behaves as expected. Even worse is that only the ObserveScanRate can
be set for a region.
Here is my test.
public class SikuliTest {
public static void main(String[] args) {
try {
// Settings.WaitScanRate = 0.1f; // Does work
// Settings.ObserveScanRate = 0.1f; /Does not work
Region searchRegion = new Screen();
searchRegion.setObserveScanRate(0.1f); // Does not work
Long startingTime = System.currentTimeMillis();
Match match = searchRegion.wait("cancel_button.png",
Constants.FOREVER);
match.click();
System.out.println("Thread1: "
+ (System.currentTimeMillis() - startingTime) + "ms");
} catch (FindFailed e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
If I bring the desired target to the screen after the program started
I get always a similar reaction time.
[log] CLICK on L(280,194)@S(0)[0,0 2560x1440]
Thread1: 4157ms
With 0.1f I would have expected that Sikulix searches every 10
seconds with a lower CPU usage, but it is always the same. It has also
no effect if I set the observe scan rate via the global settings. Only
Settings.WaitScanRate behaves as expected.
Edited on 03-02-2016, when I realized the difference between
WaitScanRate and ObserveScanRate.
To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1540233/+subscriptions
References