Jump to content

Tesseract Top Indent not Working


Recommended Posts

I am using the Tesseract UDF :

#include <Tesseract.au3>
$cord_r = 1800
$cord_t = 1080
$cord_l = 0
$cord_b = 0
_TesseractScreenCapture(0, "", 1, 1, $cord_l, $cord_t, $cord_r, $cord_b, 1)

My current desktop screen size is


The attached image shows the output. Even though I have my top indent set at 1080 it is cropping only about 1/2 of the screen. Funny part is the left, right and bottom seem to work like expected. Also the graphic looks like it is stretched.

Am I missing something?


Link to comment
Share on other sites

I found 2 problems with the sdk...they only show up when you are cropping to a small area one a large screen.

Line 968: I changed to:

$hBMP = _WinAPI_CreateCompatibleBitmap($hDC, (($pos[2]-$right_indent)* $scale), (($pos[3] -$bottom_indent)* $scale))

Line 973: I changed to:

_GDIPlus_GraphicsDrawImageRect($hGraphic, $hImage2, 0 - ($left_indent * $scale), 0 - ($top_indent * $scale), $pos[2]* $scale, $pos[3] * $scale)

Not sure if this will cause other problems, but it solves my problem.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...