<!--
{
  "availability" : [
    "driverkit: 19.0.0 -",
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "HIDDriverKit",
  "identifier" : "/documentation/HIDDriverKit/IOUserHIDEventDriver/createEventForDigitizerCollection",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "HIDDriverKit"
    ],
    "preciseIdentifier" : "c:@S@IOUserHIDEventDriver@F@createEventForDigitizerCollection#*$@S@IOHIDDigitizerCollection#k#i#"
  },
  "title" : "createEventForDigitizerCollection"
}
-->

# createEventForDigitizerCollection

Creates a HID event object that represents a digitizer collection.

```
IOHIDEvent * createEventForDigitizerCollection(IOHIDDigitizerCollection *collection, uint64_t timestamp, uint32_t reportID);
```

## Parameters

`collection`

A collection of [`IOHIDElement`](/documentation/HIDDriverKit/IOHIDElement) objects, each of which contains digitizer information to include in the event object.

`timestamp`

The timestamp of the input report.

`reportID`

The report ID.

## Return Value

An `IOHIDEvent` object containing the digitizer-related data. This method returns `NULL` if it encounters an error or if no elements in the collection contain updated values.

## Discussion

This method creates an `IOHIDEvent` object with any updated digitizer values that it finds. The [`handleDigitizerReport`](/documentation/HIDDriverKit/IOUserHIDEventDriver/handleDigitizerReport) calls this method when processing an input report; don’t call this method directly.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)