← Back to team overview

sikuli-driver team mailing list archive

[Bug 1566812] Re: Match class method saveScreenCapture(path, filename) save image with filename-somevalue but getLastScreenImageFile(path, name) should also give if name is same

 

This is some kind of misunderstanding:
both features have nothing to do with each other.

Both features are implemented in class Region which is the base class of
Match (hence each match is also a region with the matched coordinates).

--- saveScreenCapture()
... makes a shot of the given region in that moment and stores it in the given place with the name and a timestamp, to avoid overwriting (mainly to be used with debugging/logging).
It returns the created absolute filename, which has to be kept in your workflow, if you want to use the image file later.

--- getLastScreenImageFile() (agreed: naming is a bit misleading ;-)
... stores the last shot of the region, that was used with the last find operation in that region, to the given path with the given name. As such it corresponds with the feature getLastMatch(), which returns the match of the last find op (found in the LastScreenImage, which is held only in memory). It also returns the generated absolute filename. This feature also is intended to be used for debugging/logging.

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1566812

Title:
  Match class method saveScreenCapture(path,filename) save image with
  filename-somevalue but  getLastScreenImageFile(path,name) should also
  give if name is same

Status in Sikuli:
  Invalid

Bug description:
  Match class method saveScreenCapture(path,filename) saves image with
  filename-someuniqueNumber ,why? it  should save with given name and
  when i am trying to use getLastScreenImageFile(path,filename) it
  should give name-someuniqueNumber format instead of that its giving
  only name.

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1566812/+subscriptions


References