input_host_callbacks 구조체 참조

input_host_callbacks 구조체 참조

#include < input.h >

데이터 필드

input_device_identifier_t *(* create_device_identifier )( input_host_t *host, const char *name, int32_t product_id, int32_t vendor_id, input_bus_t 버스, const char *unique_id)
input_device_definition_t *(* create_device_definition )( input_host_t *호스트)
input_report_definition_t *(* create_input_report_definition )( input_host_t *호스트)
input_report_definition_t *(* create_output_report_definition )( input_host_t *호스트)
무효의(* free_report_definition )( input_host_t *호스트, input_report_definition_t *report_def)
무효의(* input_device_definition_add_report )( input_host_t *호스트, input_device_definition_t *d, input_report_definition_t *r)
무효의(* input_report_definition_add_collection )( input_host_t *host, input_report_definition_t *report, input_collection_id_t id, int32_t arity)
무효의(* input_report_definition_declare_usage_int )( input_host_t *host, input_report_definition_t *report, input_collection_id_t id, input_usage_t 사용량, int32_t min, int32_t max, float 해상도)
무효의(* input_report_definition_declare_usages_bool )( input_host_t *host, input_report_definition_t *report, input_collection_id_t id, input_usage_t *usage, size_t usage_count)
input_device_handle_t *(* register_device )( input_host_t *호스트, input_device_identifier_t *id, input_device_definition_t *d)
무효의(* unregister_device )( input_host_t *호스트, input_device_handle_t *핸들)
input_report_t *(* input_allocate_report )( input_host_t *호스트, input_report_definition_t *r)
무효의(* input_report_set_usage_int )( input_host_t *host, input_report_t *r, input_collection_id_t id, input_usage_t 사용량, int32_t 값, int32_t arity_index)
무효의(* input_report_set_usage_bool )( input_host_t *host, input_report_t *r, input_collection_id_t id, input_usage_t 사용량, 부울 값, int32_t arity_index)
무효의(* report_event )( input_host_t *호스트, input_device_handle_t *d, input_report_t *보고서)
input_property_map_t *(* input_get_device_property_map )( input_host_t *호스트, input_device_identifier_t *id)
input_property_t *(* input_get_device_property )( input_host_t *호스트, input_property_map_t *맵, const char *키)
상수 문자 *(* input_get_property_key )( input_host_t *호스트, input_property_t *속성)
상수 문자 *(* input_get_property_value )( input_host_t *호스트, input_property_t *속성)
무효의(* input_free_device_property )( input_host_t *호스트, input_property_t *속성)
무효의(* input_free_device_property_map )( input_host_t *호스트, input_property_map_t *맵)

상세 설명

파일 input.h409 행 정의.

현장 문서

input_device_definition_t *(* create_device_definition)( input_host_t *호스트)

장치의 입력 기능을 설명하는 장치 정의를 할당합니다. 장치 정의를 사용하여 원하는 만큼 장치를 등록할 수 있습니다.

파일 input.h424 행에 있는 정의입니다.

input_device_identifier_t *(* create_device_identifier)( input_host_t *host, const char *name, int32_t product_id, int32_t vendor_id, input_bus_t 버스, const char *unique_id)

주어진 속성으로 장치 식별자를 만듭니다. 고유 ID는 주어진 하드웨어를 정확하게 식별하는 문자열이어야 합니다. 예를 들어 Bluetooth를 통해 연결된 입력 장치는 MAC 주소를 고유 ID로 사용할 수 있습니다.

파일 input.h416 행에 있는 정의입니다.

input_report_definition_t *(* create_input_report_definition)( input_host_t *호스트)

HAL이 호스트에게 들어오는 입력 이벤트를 알리는 데 사용할 입력 보고서를 할당하거나 호스트가 HAL에 원하는 상태 변경(예: LED 설정)을 알리는 데 사용할 출력 보고서를 할당합니다.

파일 input.h431 행에 있는 정의입니다.

input_report_definition_t *(* create_output_report_definition)( input_host_t *호스트)

파일 input.h432 행에 있는 정의입니다.

무효(* free_report_definition)( input_host_t *호스트, input_report_definition_t *report_def)

보고서 정의를 해제합니다.

파일 input.h437 행에 있는 정의입니다.

input_report_t *(* input_allocate_report)( input_host_t *호스트, input_report_definition_t *r)

주어진 보고서에 설명된 대로 모든 상태를 포함할 보고서를 할당합니다.

파일 input.h488 행 정의.

무효(* input_device_definition_add_report)( input_host_t *호스트, input_device_definition_t *d, input_report_definition_t *r)

주어진 입력 장치에 보고서를 추가합니다.

파일 input.h442 행에 있는 정의입니다.

무효(* input_free_device_property)( input_host_t *호스트, input_property_t *속성)

input_property_t*를 해제합니다.

파일 input.h535 행에 있는 정의입니다.

무효(* input_free_device_property_map)( input_host_t *호스트, input_property_map_t *맵)

input_property_map_t*를 해제합니다.

파일 input.h540 행 정의.

input_property_t *(* input_get_device_property)( input_host_t *host, input_property_map_t *map, const char *key)

주어진 키로 장치의 속성을 검색합니다. 키가 없으면 NULL을 반환하거나 input_free_device_property() 를 사용하여 해제해야 하는 input_property_t*를 반환합니다. 해당 input_property_map_t가 해제된 후 input_property_t를 사용하는 것은 정의되지 않습니다.

파일 input.h517 행에 있는 정의입니다.

input_property_map_t *(* input_get_device_property_map)( input_host_t *호스트, input_device_identifier_t *id)

장치의 속성 집합을 검색합니다. 반환된 input_property_map_t*는 input_get_device_property 콜백을 통해 특정 속성을 쿼리하는 데 사용할 수 있습니다.

파일 input.h509 행에 있는 정의입니다.

const char*(* input_get_property_key)( input_host_t *호스트, input_property_t *속성)

입력 속성의 키를 가져옵니다. 속성이 NULL이면 NULL을 반환합니다. 반환된 const char*는 input_property_t가 소유합니다.

파일 input.h524 번째 줄에 있는 정의입니다.

const char*(* input_get_property_value)( input_host_t *호스트, input_property_t *속성)

입력 속성의 값을 가져옵니다. 속성이 NULL이면 NULL을 반환합니다. 반환된 const char*는 input_property_t가 소유합니다.

파일 input.h530 행에 정의

무효(* input_report_definition_add_collection)( input_host_t *host, input_report_definition_t *report, input_collection_id_t id, int32_t arity)

주어진 arity와 ID로 컬렉션을 추가합니다. 컬렉션은 한 손가락 터치의 X 및 Y 좌표 또는 키보드의 키 집합과 같이 논리적으로 그룹화된 속성 집합을 설명합니다. arity는 이 컬렉션이 첨부된 보고서에 얼마나 많은 반복 인스턴스가 나타날 것인지를 선언합니다. ID는 컬렉션이 나타내는 그룹화 유형을 설명합니다. 예를 들어 최대 2개의 손가락을 동시에 보고할 수 있는 터치스크린에는 X 및 Y 좌표, arity 2, ID가 INPUT_COLLECTION_USAGE_TOUCHSCREEN인 컬렉션이 있을 수 있습니다. 주어진 ID는 주어진 보고서에 대해 한 번만 존재할 수 있습니다.

파일 input.h455 행에 있는 정의입니다.

void(* input_report_definition_declare_usage_int)( input_host_t *host, input_report_definition_t *report, input_collection_id_t id, input_usage_t 사용량, int32_t min, int32_t max, float resolution)

주어진 속성으로 int 사용법을 선언하십시오. 보고서 및 컬렉션은 사용이 선언되는 위치를 정의합니다.

파일 input.h462 번째 줄에 있는 정의.

무효(* input_report_definition_declare_usages_bool)( input_host_t *host, input_report_definition_t *report, input_collection_id_t id, input_usage_t *usage, size_t usage_count)

주어진 속성으로 부울 사용법 세트를 선언하십시오. 보고서 및 컬렉션은 용도가 선언되는 위치를 정의합니다.

파일 input.h470 번째 줄에 있는 정의입니다.

무효(* input_report_set_usage_bool)( input_host_t *host, input_report_t *r, input_collection_id_t id, input_usage_t 사용량, 부울 값, int32_t arity_index)

보고서에 부울 사용량 값을 추가합니다.

파일 input.h499 번째 줄에 있는 정의입니다.

무효(* input_report_set_usage_int)( input_host_t *host, input_report_t *r, input_collection_id_t id, input_usage_t 사용량, int32_t 값, int32_t arity_index)

보고서에 int 사용 값을 추가합니다.

파일 input.h493 행에 있는 정의입니다.

주어진 입력 장치 정의를 등록하십시오. 이것은 호스트에 입력 장치가 연결되었음을 알리고 모든 기능에 대한 설명을 제공합니다.

파일 input.h479 번째 줄에 있는 정의입니다.

무효(* report_event)( input_host_t *host, input_device_handle_t *d, input_report_t *report)

파일 input.h502 행 정의.

무효(* unregister_device)( input_host_t *호스트, input_device_handle_t *핸들)

지정된 장치 등록 취소

파일 input.h483 행에 정의


이 구조체에 대한 문서는 다음 파일에서 생성되었습니다.