﻿id	summary	reporter	owner	description	type	status	milestone	component	version	severity	resolution	keywords	cc
2329	_ScreenCapture_Capture Wrong output size	johnmcloud		"The finale image has 1 pixel more then the real desktop size, so if the desktop is 1024-768, the image is 1025x769

Example:

{{{
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <ScreenCapture.au3>

$hGUI = GUICreate("""", 200, 200, -1, -1)
$Button = GUICtrlCreateButton(""Click"", 64, 80, 105, 41)
GUISetState(@SW_SHOW)
While 1
 $nMsg = GUIGetMsg()
 Switch $nMsg
  Case $GUI_EVENT_CLOSE
   Exit
  Case $Button
   _ScreenCapture_Capture(@ScriptDir & ""\Test_1.jpg"", 0, 0, -1, -1, True)
   $hJpg = _ScreenCapture_Capture("""")
   _ScreenCapture_SaveImage(@ScriptDir & ""\Test_2.jpg"", $hJpg)
 EndSwitch
WEnd
}}}

The solution can be, on the UDF:
{{{
Local $iW = ($iRight - $iLeft) + 1
Local $iH = ($iBottom - $iTop) + 1
}}}
To
{{{
Local $iW = ($iRight - $iLeft)
Local $iH = ($iBottom - $iTop)
}}}

But i'm not an expert, so please check it out.
Thanks"	Bug	closed		AutoIt	3.3.8.1	None	Duplicate		
