Touch Device

To be able to send touch events, the client sends a RegisterHIDDeviceMessage.

syntax = "proto2";

import "ProtocolMessage.proto";
import "VirtualTouchDeviceDescriptor.proto";

extend ProtocolMessage {
  optional RegisterHIDDeviceMessage registerHIDDeviceMessage = 11;
}

message RegisterHIDDeviceMessage {
  optional VirtualTouchDeviceDescriptor deviceDescriptor = 1;
}
syntax = "proto2";

message VirtualTouchDeviceDescriptor {
  optional bool absolute = 1;
  optional bool integratedDisplay = 2;
  optional float screenSizeWidth = 3;
  optional float screenSizeHeight = 4;
}

CLIENT -> SERVER

type: REGISTER_HID_DEVICE_MESSAGE
identifier: "B368593E-2BF9-4ECC-9016-11DEB3121FA6"
priority: 0
[registerHIDDeviceMessage] {
  deviceDescriptor {
    absolute: false
    integratedDisplay: false
    screenSizeWidth: 320
    screenSizeHeight: 282
  }
}

The Apple TV answers with a RegisterHIDDeviceResultMessage

syntax = "proto2";

import "ProtocolMessage.proto";

extend ProtocolMessage {
  optional RegisterHIDDeviceResultMessage registerHIDDeviceResultMessage = 12;
}

message RegisterHIDDeviceResultMessage {
  optional int32 errorCode = 1;
  optional int32 deviceIdentifier = 2;
}

SERVER -> CLIENT

type: REGISTER_HID_DEVICE_RESULT_MESSAGE
identifier: "B368593E-2BF9-4ECC-9016-11DEB3121FA6"
priority: 0
[registerHIDDeviceResultMessage] {
  errorCode: 0
  deviceIdentifier: 9
}

results matching ""

    No results matching ""