Search found 1426 matches

by iseahound
14 Mar 2024, 11:58
Forum: Ask for Help (v2)
Topic: Does anyone have a good OCR solution with V2?
Replies: 9
Views: 1547

Re: Does anyone have a good OCR solution with V2?

Yep. The fact is paid APIs offer a much more compelling OCR solution than what's possible on the local system. You could also create an esemble of APIs, where you use about 3 services, and mix those results up for a better truth model. If you're asking about integration, there's only 3 ways image da...
by iseahound
14 Mar 2024, 11:54
Forum: Ask for Help (v2)
Topic: Capslock doesn't work for a modifier key.
Replies: 7
Views: 145

Re: Capslock doesn't work for a modifier key.

Certain combinations of keys don't work for me on my Apple Magic Keyboard such as CapsLock + Control + /.

Try this CapsLock script:
viewtopic.php?f=96&t=125147
by iseahound
13 Mar 2024, 23:22
Forum: Ask for Help (v2)
Topic: String manipulation speed test -- Is this right? Topic is solved
Replies: 6
Views: 175

Re: String manipulation speed test -- Is this right? Topic is solved

arrays are structures and have a small amount of fixed overhead.

You could use a combination of STRPTR and rtlcomparememory for the absolute fastest string comparisons. SubStr will always create a copy of your string.
by iseahound
12 Mar 2024, 09:49
Forum: Scripts and Functions (v2)
Topic: ImagePut - A core library for images in AutoHotkey (Now supports HEIC & WEBP)
Replies: 82
Views: 27849

Re: ImagePut - A core library for images in AutoHotkey (Now supports HEIC & WEBP)

That's not me... WinExist() is case sensitive. Try ahk_class Notepad on Windows 11. I think before, it used to be lowercase on Windows 7 and I never changed the documentation.
by iseahound
08 Mar 2024, 12:11
Forum: Ask for Help (v2)
Topic: Does anyone have code to Change the DPI of the current monitor?
Replies: 3
Views: 170

Re: Does anyone have code to Change the DPI of the current monitor?

On that note, here's some code that connects the sourceID and adapterID to an hMonitor handle: #include <Windows.h> #include <stdio.h> #include <vector> #include <tuple> #include <string> int main() { // get all paths UINT pathCount; UINT modeCount; if (GetDisplayConfigBufferSizes(QDC_ONLY_ACTIVE_PA...
by iseahound
08 Mar 2024, 11:05
Forum: Ask for Help (v2)
Topic: Does anyone have code to Change the DPI of the current monitor?
Replies: 3
Views: 170

Re: Does anyone have code to Change the DPI of the current monitor?

It's close. I think the structures I'm showing are undocumented. Teadrinker uses only the publicly available API. Some issues I had were trying to convert the sourceID and adapterID into a simple hMonitor handle. If these two are connected, it should be able to do: A hotkey that sets the recommended...
by iseahound
07 Mar 2024, 18:30
Forum: Tutorials (v2)
Topic: Screen scaling, DPI, and making scripts work in different computers
Replies: 6
Views: 5780

Re: Screen scaling, DPI, and making scripts work in different computers

@Descolada Did you manage to figure out which function windows uses to scale with DPI? That would fix most of the DPI related imagesearch issues.
by iseahound
07 Mar 2024, 18:28
Forum: Ask for Help (v2)
Topic: Does anyone have code to Change the DPI of the current monitor?
Replies: 3
Views: 170

Does anyone have code to Change the DPI of the current monitor?

Was wondering if anyone had already written a utility to change the DPI of the monitor. image.png Here is some half finished work: ; struct DISPLAYCONFIG_DEVICE_INFO_HEADER NumPut( "uint", -3 ; DISPLAYCONFIG_DEVICE_INFO_GET_DPI_SCALE , "uint", 28 , "uint", adapterID , "uint", sourceID , "int", 0 ; m...
by iseahound
01 Mar 2024, 12:22
Forum: Ask for Help (v2)
Topic: Static methods in base class not accesssible in derived class via "this".
Replies: 11
Views: 320

Re: Static methods in base class not accesssible in derived class via "this".

No it's not directly possible. You'll have to play around with either making the method static and calling super/prototype or making it an instance method and calling it using class.prototype.

If you want to support both forms you'll need a simple helper function.
by iseahound
27 Feb 2024, 19:15
Forum: Suggestions on Documentation Improvements
Topic: RawRead()
Replies: 1
Views: 112

RawRead()

Please add a note that if a UTF-8 BOM file is encountered, the file pointer is set to 3. Therefore calls to RawRead() will read 3 less bytes.

The user should add

Code: Select all

f.pos := 0
before calls to rawread or they may get errors.

This may be a bug.
by iseahound
27 Feb 2024, 12:12
Forum: Scripts and Functions (v2)
Topic: ImagePut - A core library for images in AutoHotkey (Now supports HEIC & WEBP)
Replies: 82
Views: 27849

Re: ImagePut - A core library for images in AutoHotkey (Now supports HEIC & WEBP)

Nice to hear. In case anyone was wondering, the latest update searches the first few bytes of the buffer object ( ptr and size ) for magic numbers that might indicate if it was a png or a gif. If not, it then looks to see if the buffer object has a width or pitch/stride or height property, and it as...
by iseahound
25 Feb 2024, 16:41
Forum: Scripts and Functions (v2)
Topic: ImagePut - A core library for images in AutoHotkey (Now supports HEIC & WEBP)
Replies: 82
Views: 27849

Re: ImagePut - A core library for images in AutoHotkey (Now supports HEIC & WEBP)

william_ahk Can you experiment with the latest version using ImagePutEncodedBuffer ? You will obviously have to use buf.ptr on AutoHotkey v1, and it should operate like a normal buffer object on v2. Feel free to "construct" a buffer via {ptr: ptr, size: size} as well. https://github.com/iseahound/I...
by iseahound
24 Feb 2024, 15:54
Forum: Scripts and Functions (v2)
Topic: svgToHBITMAP.ah2 (AddPicture an SVG to Gui)
Replies: 7
Views: 841

Re: svgToHBITMAP.ah2 (AddPicture an SVG to Gui)

Thanks! I figure since I'm refactoring ImagePut anyways, I'd throw in as many features as possible. It should end up kind of like a unified library for images, kind of like pillow. I really appreciate your script, it's not something I could have done myself.
by iseahound
24 Feb 2024, 10:21
Forum: Scripts and Functions (v2)
Topic: svgToHBITMAP.ah2 (AddPicture an SVG to Gui)
Replies: 7
Views: 841

Re: svgToHBITMAP.ah2 (AddPicture an SVG to Gui)

@MrDoge Do you mind if I add your code to my project to ImagePut? There will be some modifications and I will give you credit.
by iseahound
23 Feb 2024, 12:47
Forum: AutoHotkey Development
Topic: Make Arrays Useful
Replies: 1
Views: 213

Make Arrays Useful

Arrays leave a lot to be desired in AutoHotkey and are at this point rather inferior to Map() . Issue #1: Allocate Arrays in a single line. It should be possible to do the following in a single line. Even Python allows this via 5*["default value"] a := [] a.length := 5 Issue #2: Add useful methods ....
by iseahound
18 Feb 2024, 21:34
Forum: Ask for Help (v2)
Topic: Literally write hex (binary) to a file Topic is solved
Replies: 3
Views: 138

Re: Literally write hex (binary) to a file Topic is solved

Something like this? assembly := " ( Join`s Comments 48 89 4c 24 08 ; mov [rsp+8], rcx 48 89 54 24 10 ; mov [rsp+16], rdx 4c 89 44 24 18 ; mov [rsp+24], r8 4c 89 4c 24 20 ; mov [rsp+32], r9 48 83 ec 28 ; sub rsp, 40 49 b9 00 00 00 00 00 00 00 00 ; mov r9, .. (lParam) 49 b8 00 00 00 00 00 00 00 00 ; ...
by iseahound
17 Feb 2024, 15:11
Forum: Ask for Help (v2)
Topic: map() is so slow? Topic is solved
Replies: 10
Views: 303

Re: map() is so slow? Topic is solved

I tested this using FileOpen and got the same exact results. Unfortunately, it's a tradeoff between the O(log n) access of a map vs the linear access of an array. Now if you wanted to do aaaa → 工 , you could use the file pointer and binary search as I do here: UnicodeData("🍅") UnicodeData(s, filepat...
by iseahound
17 Feb 2024, 11:45
Forum: Ask for Help (v2)
Topic: Is an AutoHotkey object address always below 0xFFFFFFFF?
Replies: 3
Views: 285

Re: Is an AutoHotkey object address always below 0xFFFFFFFF?

Thanks. I tested this myself, and only after 4 gigabytes of RAM is used does AutoHotkey start generating 64-bit addresses: After 1000000 runs, no change: 173746528, 1000000 After 1000000 runs, no change: 240471776, 2000000 After 1000000 runs, no change: 307193712, 3000000 After 1000000 runs, no chan...
by iseahound
15 Feb 2024, 16:35
Forum: Tutorials (v2)
Topic: A Starter Guide to Understanding GDI
Replies: 2
Views: 331

Re: A Starter Guide to Understanding GDI

reserved again

Go to advanced search