Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8828491
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T07:37:04+00:00 2026-06-14T07:37:04+00:00

I have a testing server which runs headless. One test I want is to

  • 0

I have a testing server which runs headless. One test I want is to check that an image served off a particular URL matches some reference image.

Is there an API in Sikuli which can directly accept an image as a stream and compare it with some other image taken from the local resource file? Unfortunately, there is no complete tutorial on Sikuli’s Java API, all I’ve found is tutorials that assume that there is a display available.

I’ll be glad to see any examples or at least links to the needed parts of Sikuli javadocs. Also, suggestions for other approaches are welcome.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T07:37:06+00:00Added an answer on June 14, 2026 at 7:37 am

    To use Sikuli you need

    1. A base image on which the other image will be searched.
    2. The image which will be searched within the other image.

    If image 1 is your local resource image, you can create a org.sikuli.Finder instance with the path to the image and the Region of this image which will be searched.
    Example (java level):

    finder = new Finder("path/to/image", new Region(0, 0, <imgwidth>, <imgheight>));
    

    If image 1 is your stream, you have to make a BufferedImage out of it somehow (I do not know the best way to do this).
    Then you can make a org.sikuli.ScreenImage from this BufferedImage with the help of an java.awt.Rectangle and an org.sikuli.Region.

    finder = new Finder(new ScreenImage(new Rectangle(0,0,<imgwidth>,<imgheight>), bufferedImage), new Region(0,0,<imgwidth>,<imgheight>))
    

    After you created the finder from image 1, you can search image 2 within this image.

    Again, you have two possibilities.
    If the second image is your local resource image, you can create an org.sikuli.Pattern object with the file location:

    pattern = new Pattern("path/to/image.png");
    

    Else, if this is your stream, you have to make a BufferedImage out of the stream somehow. You can then create a pattern from this image:

    pattern = new Pattnern(bufferedImage);
    

    As a last step, you can now run the finder to search for the pattern:

    finder.find(pattern);
    

    You can check if the finder found anything with:

    finder.hasNext();
    

    And you should be able to iterate all findings with:

    for (Match m : finder):
        //do something with the match
    

    I hope I could help you although your question is already some weeks old.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to have a seperate project that runs my server communication code in
I have a Linux server at home that runs VMWare Server. I have one
I have an express server which I am testing using vows. I want to
I have a Testing project that contains a csv file which a webtest uses
I have made a TCP server which I have been testing locally and it
I have a problem executing a process from our testing server. On my localhost
I'm working on an online store. I have it setup on my testing server.
I have been testing the performance of reading server socket input stream. I found
What tools for server side application performance testing you suggest? Have an application server
I testing setting up a web logic server which can use an Oracle AQ

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.