개체 인스턴스를 초기화합니다.
구문
void initialize(
uint32_t maxChatUserCount,
float defaultAudioRenderVolume= 1.0f,
game_chat_communication_relationship_flags defaultLocalToRemoteCommunicationRelationship= game_chat_communication_relationship_flags none,
game_chat_shared_device_communication_relationship_resolution_mode sharedDeviceResolutionMode= game_chat_shared_device_communication_relationship_resolution_mode permissive,
game_chat_speech_to_text_conversion_mode speechToTextConversionMode= game_chat_speech_to_text_conversion_mode automatic,
game_chat_audio_manipulation_mode_flags audioManipulationMode= game_chat_audio_manipulation_mode_flags none
)
매개 변수
maxChatUserCount _In_
형식: uint32_t
언제라도 로컬 chat_manager 인스턴스에 추가될 로컬 및 원격 사용자 수의 최대 총합입니다. 게임 채팅에서는 사용자 수에 비례하여 메모리를 사전 할당합니다.
defaultAudioRenderVolume _In_range_(0,1)
형식: float
새 사용자가 사용할 오디오 렌더링 볼륨입니다.
defaultLocalToRemoteCommunicationRelationship _In_
형식: game_chat_communication_relationship_flags
로컬 및 원격 사용자 간에 사용되는 기본 통신 관계입니다. 예를 들어 원격 사용자가 참가할 때 모든 기존 로컬 사용자와 해당 원격 사용자 간에 사용되는 기본 관계가 됩니다. 로컬 사용자가 참가할 때 해당 로컬 사용자와 모든 기존 원격 사용자 간의 기본 관계가 됩니다.
sharedDeviceResolutionMode _In_
형식: game_chat_shared_device_communication_relationship_resolution_mode
통신 관계가 충돌하는 공유 장치의 사용자에 대해 사용되는 해결 모드입니다.
speechToTextConversionMode _In_
형식: game_chat_speech_to_text_conversion_mode
음성-텍스트 변환 모드를 구성합니다.
audioManipulationMode _In_
형식: game_chat_audio_manipulation_mode_flags
이 매개 변수를 game_chat_audio_manipulation_mode_flags::none으로 전달하면 오디오가 중단 없이 게임 채팅을 통해 전달됩니다. game_chat_audio_manipulation_mode_flags::pre_encode_stream_manipulation 비트 세트와 함께 이 매개 변수를 전달하면 보낸 사람 측의 처리 및 조작을 위한 채팅 사용자 오디오 데이터 액세스가 부여됩니다. 오디오 데이터 액세스는 pre_encode_audio_stream 개체 사용을 통해 활성화됩니다. 이러한 개체는 chat_manager::get_pre_encode_audio_streams 메서드를 사용하여 쿼리할 수 있습니다. 게임 채팅에서 pre_encode_audio_stream 개체를 생성, 닫기 및 제거할 때 해당 game_chat_stream_state_change 이벤트가 생성됩니다. game_chat_audio_manipulation_mode_flags::post_decode_stream_manipulation 비트 세트와 함께 이 매개 변수를 전달하면 받는 사람 측의 처리 및 조작을 위한 채팅 사용자 오디오 데이터 액세스가 부여됩니다. 오디오 데이터 액세스는 post_decode_audio_source_stream 및 post_decode_audio_sink_stream 개체 사용을 통해 활성화됩니다. 이러한 개체는 chat_manager::get_post_decode_audio_source_streams 및 chat_manager::get_post_decode_audio_sink_streams 메서드를 사용하여 쿼리할 수 있습니다. 게임 채팅에서 post_decode_audio_source_stream 및 post_decode_audio_sink_stream 개체를 생성, 닫기 및 제거할 때 해당 game_chat_stream_state_change 이벤트가 생성됩니다.
반환 값
형식: void
설명
정적 메서드인 chat_manager::singleton_instance(), chat_manager::set_memory_callbacks(), chat_manager::get_memory_callbacks(), chat_manager::set_thread_processor() 및 chat_manager::get_thread_processor()를 제외한 모든 메서드보다 먼저 호출해야 합니다. 후속 subsequent chat_manager::cleanup() 호출 없이 chat_manager::initialize()를 다시 호출할 수 없습니다.
모든 chat_manager::initialize() 호출에는 해당하는 chat_manager::cleanup() 호출이 있어야 합니다.
요구 사항
헤더: GameChat2.h
지원되는 플랫폼: Windows, Xbox One 패밀리 콘솔 및 Xbox Series 콘솔
참고 항목
chat_manager
chat_manager::cleanup
chat_manager::singleton_instance
chat_manager::set_memory_callbacks
chat_manager::get_memory_callbacks
chat_manager::set_thread_processor
chat_manager::get_thread_processor
pre_encode_audio_stream
post_decode_audio_source_stream
post_decode_audio_sink_stream