← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #242839]: Why the multithreading is too long when I use the wait method on different region

 

Question #242839 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/242839

    Status: Needs information => Open

Greg83140 gave more information on the question:
Hi again, his is my real code :


	public ExtractionThread(Region region, Glyph g, String resultatAttendu){
		this.region = region;
		this.g = g;
		this.resultatAttendu = resultatAttendu;
	}
	
	
	public void run() {
		System.out.println("Starting extraction for " + g  "!In region : "+region);
		Match pattern = null;
		Pattern glyph = g.getPattern();
		long extractionStartTime = System.currentTimeMillis();
		try {
			pattern = region.wait(glyph,0.5);
			
		} catch (FindFailed e) {
			System.out.println("Glyph not found ("+ g +")");
		
		System.err.println("Extraction time for "+ g + " : "+ (System.currentTimeMillis() - extractionStartTime));
		
		if (pattern != null) {
			//Do my Action
		}

        }

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.