docs.unity3d.com
    Show / Hide Table of Contents

    Struct HID.HIDDeviceDescriptorBuilder

    Helper to quickly build descriptors for arbitrary HIDs.

    Namespace: UnityEngine.InputSystem.HID
    Syntax
    public struct HIDDeviceDescriptorBuilder

    Constructors

    HIDDeviceDescriptorBuilder(HID.GenericDesktop)

    Declaration
    public HIDDeviceDescriptorBuilder(HID.GenericDesktop usage)
    Parameters
    Type Name Description
    HID.GenericDesktop usage

    HIDDeviceDescriptorBuilder(HID.UsagePage, Int32)

    Declaration
    public HIDDeviceDescriptorBuilder(HID.UsagePage usagePage, int usage)
    Parameters
    Type Name Description
    HID.UsagePage usagePage
    Int32 usage

    Fields

    usage

    Declaration
    public int usage
    Field Value
    Type Description
    Int32

    usagePage

    Declaration
    public HID.UsagePage usagePage
    Field Value
    Type Description
    HID.UsagePage

    Methods

    AddElement(HID.GenericDesktop, Int32)

    Declaration
    public HID.HIDDeviceDescriptorBuilder AddElement(HID.GenericDesktop usage, int sizeInBits)
    Parameters
    Type Name Description
    HID.GenericDesktop usage
    Int32 sizeInBits
    Returns
    Type Description
    HID.HIDDeviceDescriptorBuilder

    AddElement(HID.UsagePage, Int32, Int32)

    Declaration
    public HID.HIDDeviceDescriptorBuilder AddElement(HID.UsagePage usagePage, int usage, int sizeInBits)
    Parameters
    Type Name Description
    HID.UsagePage usagePage
    Int32 usage
    Int32 sizeInBits
    Returns
    Type Description
    HID.HIDDeviceDescriptorBuilder

    Finish()

    Declaration
    public HID.HIDDeviceDescriptor Finish()
    Returns
    Type Description
    HID.HIDDeviceDescriptor

    StartReport(HID.HIDReportType, Int32)

    Declaration
    public HID.HIDDeviceDescriptorBuilder StartReport(HID.HIDReportType reportType, int reportId = 1)
    Parameters
    Type Name Description
    HID.HIDReportType reportType
    Int32 reportId
    Returns
    Type Description
    HID.HIDDeviceDescriptorBuilder

    WithLogicalMinMax(Int32, Int32)

    Declaration
    public HID.HIDDeviceDescriptorBuilder WithLogicalMinMax(int min, int max)
    Parameters
    Type Name Description
    Int32 min
    Int32 max
    Returns
    Type Description
    HID.HIDDeviceDescriptorBuilder

    WithPhysicalMinMax(Int32, Int32)

    Declaration
    public HID.HIDDeviceDescriptorBuilder WithPhysicalMinMax(int min, int max)
    Parameters
    Type Name Description
    Int32 min
    Int32 max
    Returns
    Type Description
    HID.HIDDeviceDescriptorBuilder
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023