@ -6,6 +6,24 @@ This is a DLL extension for [AutoHotkey](https://www.autohotkey.com/) that enabl
While most functions should already work as intended, there may still be some bugs. If you encounter some possibly wrong behaviour, please let us know!
While most functions should already work as intended, there may still be some bugs. If you encounter some possibly wrong behaviour, please let us know!
* OSC address wildcards are supported now but probably need some testing
* OSC address wildcards are supported now but probably need some testing
- [OSC2AHK](#osc2ahk)
- [Work in progress](#work-in-progress)
- [Installation](#installation)
- [Usage](#usage)
- [General concept](#general-concept)
- [Receive functions](#receive-functions)
- [Load DLL](#load-dll)
- [Open network port](#open-network-port)
- [Close network port](#close-network-port)
- [Add listener](#add-listener)
- [Remove listener](#remove-listener)
- [Get string data](#get-string-data)
- [Send functions](#send-functions)
- [Send integer message](#send-integer-message)
- [Send float message](#send-float-message)
- [Send string message](#send-string-message)
- [Credits](#credits)
## Installation
## Installation
Just download the latest version of OSC2AHK.dll from the [releases page](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK/releases) and place it in the same directory as your AutoHotkey scripts. Maybe you also want to check out the provided [usage examples](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK/src/branch/master/examples).
Just download the latest version of OSC2AHK.dll from the [releases page](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK/releases) and place it in the same directory as your AutoHotkey scripts. Maybe you also want to check out the provided [usage examples](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK/src/branch/master/examples).
@ -13,7 +31,8 @@ Just download the latest version of OSC2AHK.dll from the [releases page](https:/
### General concept
### General concept
After the DLL is loaded and a network port is opened with the [`open()`](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK#open-network-port) function, it receives all incoming OSC messages. To specify the messages that should be passed to the AutoHotkey (AHK) script, "listeners" are specified and created by the ['addListener()'](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK#add-listener) function. When a OSC message is received that matches a existing listener, a "system message" is sent to the AHK script. This happens via the Windows message queue and the system message ID is used to tell the script which OSC address was received. Therefore with [`addListener()`](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK#add-listener) a ID has to be passed to the DLL which then uses this ID to post the system message.
After the DLL is loaded and a network port is opened with the [`open()`](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK#open-network-port) function, it receives all incoming OSC messages. To specify the messages that should be passed to the AutoHotkey (AHK) script, "listeners" are specified and created by the ['addListener()'](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK#add-listener) function. When a OSC message is received that matches a existing listener, a "system message" is sent to the AHK script. This happens via the Windows message queue and the system message ID is used to tell the script which OSC address was received. Therefore with [`addListener()`](https://files.eleton-audio.de/gitea/Ludwig/OSC2AHK#add-listener) a ID has to be passed to the DLL which then uses this ID to post the system message.
### Functions
### Receive functions
These functions are the main functions used to receive OSC messages in AHK.
#### Load DLL
#### Load DLL
First the DLL should be loaded from within the AHK script by calling
First the DLL should be loaded from within the AHK script by calling