![]() |
vitasdk
Documentation of the vitasdk
|
Exports for User. More...
Data Structures | |
| struct | SceVoiceEventPortDataReady |
| struct | SceVoiceEventAudioInputOwnershipChanged |
| struct | SceVoiceEvent |
| struct | SceVoiceInitParam |
| struct | SceVoiceStartParam |
| struct | SceVoicePortParam |
| struct | SceVoiceResourceInfo |
| struct | SceVoicePortInfo |
| union | SceVoiceEvent.event_payload |
| union | SceVoicePortParam.data |
Macros | |
| #define | SCE_VOICE_VERSION 100 |
| #define | SCE_VOICE_WORKING_MEMORY_SIZE 0x40000 |
| #define | SCE_VOICE_MAX_EVENT_PORTS 7 |
Typedefs | |
| typedef SceUInt32 | SceVoicePortId |
| typedef void(* | SceVoiceEventCallback) (const SceVoiceEvent *event) |
| Voice event callback. | |
Functions | |
| VITASDK_BUILD_ASSERT_EQ (0x10, SceVoiceEventPortDataReady) | |
| VITASDK_BUILD_ASSERT_EQ (0x10, SceVoiceEventAudioInputOwnershipChanged) | |
| VITASDK_BUILD_ASSERT_EQ (0x18, SceVoiceEvent) | |
| VITASDK_BUILD_ASSERT_EQ (0x20, SceVoiceInitParam) | |
| VITASDK_BUILD_ASSERT_EQ (0x20, SceVoiceStartParam) | |
| VITASDK_BUILD_ASSERT_EQ (0x18, SceVoicePortParam) | |
| VITASDK_BUILD_ASSERT_EQ (0xA, SceVoiceResourceInfo) | |
| VITASDK_BUILD_ASSERT_EQ (0x18, SceVoicePortInfo) | |
| int | sceVoiceInit (const SceVoiceInitParam *param, SceUInt32 version) |
| Initialize Voice for the calling process. | |
| int | sceVoiceEnd (void) |
| Shut down Voice for the calling process and release its ports. | |
| int | sceVoiceStart (const SceVoiceStartParam *param) |
| Attach the Voice instance to its working-memory block and start processing. | |
| int | sceVoiceStop (void) |
| Stop Voice processing and detach the working-memory block. | |
| int | sceVoiceGetResourceInfo (SceVoiceResourceInfo *info) |
| Get the port limits assigned to this Voice instance. | |
| int | sceVoiceCheckTopology (void) |
| Check whether the current port connections are valid. | |
| int | sceVoiceSetMuteFlagAll (SceBool mute) |
| Set the process-wide mute-reporting override. | |
| int | sceVoiceSetMuteFlag (SceVoicePortId port_id, SceBool mute) |
| Set one port's mute flag. | |
| int | sceVoiceGetMuteFlag (SceVoicePortId port_id, SceUInt16 *mute) |
| Get one port's reported mute flag. | |
| int | sceVoiceSetVolume (SceVoicePortId port_id, float volume) |
| Set one port's linear volume. | |
| int | sceVoiceGetVolume (SceVoicePortId port_id, float *volume) |
| Get one port's linear volume. | |
| int | sceVoiceSetBitRate (SceVoicePortId port_id, SceUInt32 bit_rate) |
| Change the bitrate of an encoded input or output port. | |
| int | sceVoiceGetBitRate (SceVoicePortId port_id, SceUInt32 *bit_rate) |
| Get the bitrate of an encoded input or output port. | |
| int | sceVoiceSetPortAttr (SceVoicePortId port_id, SceVoicePortAttr attr, const SceInt32 *value) |
| Set a port attribute. | |
| int | sceVoiceGetPortAttr (SceVoicePortId port_id, SceVoicePortAttr attr, SceInt32 *value) |
| Get a port attribute. | |
| int | sceVoiceCreatePort (SceVoicePortId *port_id, const SceVoicePortParam *param) |
| Create a Voice port. | |
| int | sceVoiceUpdatePort (SceVoicePortId port_id, const SceVoicePortParam *param) |
| Update an existing port's configuration. | |
| int | sceVoiceConnectIPortToOPort (SceVoicePortId input_port_id, SceVoicePortId output_port_id) |
| Connect an input port to an output port. | |
| int | sceVoiceDisconnectIPortFromOPort (SceVoicePortId input_port_id, SceVoicePortId output_port_id) |
| Disconnect an input port from an output port. | |
| int | sceVoiceDeletePort (SceVoicePortId port_id) |
| Delete a Voice port and remove its connections. | |
| int | sceVoiceWriteToIPort (SceVoicePortId port_id, const void *data, SceSize *size, SceInt16 frame_gap) |
| Write application data to a PCM or encoded input port. | |
| int | sceVoiceReadFromOPort (SceVoicePortId port_id, void *data, SceSize *size) |
| Read application data from a PCM or encoded output port. | |
| int | sceVoiceGetPortInfo (SceVoicePortId port_id, SceVoicePortInfo *info) |
| Get one port's type, processing state, available data, and frame size. | |
| int | sceVoiceResetPort (SceVoicePortId port_id) |
| Clear one port's buffered data and reset its processing state. | |
| int | sceVoicePausePort (SceVoicePortId port_id) |
| Pause processing for one port. | |
| int | sceVoiceResumePort (SceVoicePortId port_id) |
| Resume processing for one port. | |
| int | sceVoicePausePortAll (void) |
| Pause processing for every Voice port in the calling process. | |
| int | sceVoiceResumePortAll (void) |
| Resume processing for every Voice port in the calling process. | |
Exports for User.
Include the header file in your project:
Link the library to the executable:
| struct SceVoiceEventPortDataReady |
| Data Fields | ||
|---|---|---|
| SceInt16 | port_count |
Number of valid entries in port_ids. |
| SceUInt16 | port_ids[SCE_VOICE_MAX_EVENT_PORTS] | Output-voice ports with encoded data available. |
| struct SceVoiceEventAudioInputOwnershipChanged |
| struct SceVoiceEvent |
| Data Fields | ||
|---|---|---|
| SceUInt32 | event_type | One of SceVoiceEventType. |
| void * | user_data | Value supplied to sceVoiceInit. |
| union SceVoiceEvent.event_payload | event_payload | |
| struct SceVoiceInitParam |
| Data Fields | ||
|---|---|---|
| SceUInt32 | application_type | One of SceVoiceApplicationType. |
| SceVoiceEventCallback | event_callback | Optional event callback, or NULL to disable events. |
| void * | user_data | Copied to SceVoiceEvent::user_data. |
| SceUInt32 | reserved[5] | Ignored on FW 3.60. |
| struct SceVoiceStartParam |
| Data Fields | ||
|---|---|---|
| SceUID | mem_block_id | Memory block providing at least SCE_VOICE_WORKING_MEMORY_SIZE bytes. |
| SceUInt32 | reserved[7] | Ignored on FW 3.60. |
| struct SceVoicePortParam |
| Data Fields | ||
|---|---|---|
| SceUInt32 | port_type | One of SceVoicePortType. |
| SceUInt16 | threshold | Buffering threshold for application input, in milliseconds; at least two frame durations are used. |
| SceUInt16 | mute_flag | Nonzero to create the port muted. |
| float | volume | Linear volume; 1.0 is unity gain. |
| union SceVoicePortParam.data | data | |
| SceUInt32 | pcm_data_type | One of SceVoicePcmDataType for PCMAUDIO ports. |
| SceUInt32 | sampling_rate | One of SceVoiceSamplingRate for PCMAUDIO ports. |
| struct SceVoiceResourceInfo |
| Data Fields | ||
|---|---|---|
| SceUInt16 | max_voice_input_ports | Maximum number of IN_VOICE ports. |
| SceUInt16 | max_voice_output_ports | Maximum number of OUT_VOICE ports. |
| SceUInt16 | max_device_input_ports | Maximum number of IN_DEVICE ports. |
| SceUInt16 | max_device_output_ports | Maximum number of OUT_DEVICE ports. |
| SceUInt16 | max_ports | Maximum number of ports of all types. |
| struct SceVoicePortInfo |
| Data Fields | ||
|---|---|---|
| SceUInt32 | port_type | One of SceVoicePortType. |
| SceUInt32 | state | One of SceVoicePortState. |
| SceUInt32 | reserved0 | Not written on FW 3.60. |
| SceSize | data_size | Free bytes in the input ring buffer or queued bytes in the output ring buffer. |
| SceSize | frame_size | Encoded or PCM processing-frame size in bytes. |
| SceUInt32 | reserved1 | Not written on FW 3.60. |
| union SceVoiceEvent.event_payload |
| Data Fields | ||
|---|---|---|
| SceVoiceEventPortDataReady | port_data_ready | |
| SceVoiceEventAudioInputOwnershipChanged | audio_input_ownership_changed | |
| union SceVoicePortParam.data |
| Data Fields | ||
|---|---|---|
| SceSize | buffer_size | PCM byte capacity for PCMAUDIO ports. |
| SceUInt32 | bit_rate | One of SceVoiceBitRate for VOICE ports. |
| #define SCE_VOICE_VERSION 100 |
| #define SCE_VOICE_WORKING_MEMORY_SIZE 0x40000 |
| #define SCE_VOICE_MAX_EVENT_PORTS 7 |
| typedef SceUInt32 SceVoicePortId |
| typedef void(* SceVoiceEventCallback) (const SceVoiceEvent *event) |
Voice event callback.
Callbacks run one at a time on SceVoice's private event thread. The event is stored on that thread's stack and is valid only until the callback returns. Other SceVoice functions may be called from the callback, but sceVoiceEnd must not be called because it waits for the event thread.
| [in] | event | - Event record valid for the duration of the callback. |
| enum SceVoiceErrorCode |
| Enumerator | |
|---|---|
| SCE_VOICE_ERROR_NOT_INITIALIZED | sceVoiceInit has not succeeded. |
| SCE_VOICE_ERROR_ALREADY_INITIALIZED | Voice is already initialized for this process. |
| SCE_VOICE_ERROR_INTERNAL | An internal backend operation failed. |
| SCE_VOICE_ERROR_INVALID_PORT_ID | The port ID is out of range or not allocated for the operation. |
| SCE_VOICE_ERROR_INVALID_ARGUMENT | An argument, format, or port type is invalid. |
| SCE_VOICE_ERROR_INVALID_MEMBLOCK | The working-memory UID could not be resolved to a memory block. |
| SCE_VOICE_ERROR_INVALID_PORT | The port does not exist or is unsuitable for the operation. |
| SCE_VOICE_ERROR_RESOURCE_LIMIT | A port, connection, codec, or memory limit was reached. |
| SCE_VOICE_ERROR_NOT_STARTED | sceVoiceStart has not attached working memory. |
Voice application profiles accepted by sceVoiceInit.
FW 3.60 treats both values identically: they select the same port and working-memory limits. SceParty and SceVoiceQoS use 0x20000000; no FW 3.60 system module uses 0x80000000.
| Enumerator | |
|---|---|
| SCE_VOICE_APPLICATION_TYPE_UNK_0x20000000 | |
| SCE_VOICE_APPLICATION_TYPE_UNK_0x80000000 | |
| enum SceVoicePortType |
| enum SceVoicePortState |
Port processing states reported by sceVoiceGetPortInfo on FW 3.60.
| enum SceVoiceBitRate |
8 kHz CELP bitrates supported by the FW 3.60 Voice codec.
| enum SceVoicePcmDataType |
| enum SceVoiceSamplingRate |
| enum SceVoicePortAttr |
| enum SceVoiceEventType |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x10 | , |
| SceVoiceEventPortDataReady | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x10 | , |
| SceVoiceEventAudioInputOwnershipChanged | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x18 | , |
| SceVoiceEvent | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x20 | , |
| SceVoiceInitParam | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x20 | , |
| SceVoiceStartParam | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x18 | , |
| SceVoicePortParam | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0xA | , |
| SceVoiceResourceInfo | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x18 | , |
| SceVoicePortInfo | |||
| ) |
| int sceVoiceInit | ( | const SceVoiceInitParam * | param, |
| SceUInt32 | version | ||
| ) |
Initialize Voice for the calling process.
| [in] | param | - Initialization parameters. The callback may be NULL. |
| [in] | version | - Must be SCE_VOICE_VERSION on FW 3.60. |
| int sceVoiceEnd | ( | void | ) |
Shut down Voice for the calling process and release its ports.
If Voice is started, this function stops all audio processing and detaches the working-memory block before destroying the ports and event thread. The caller remains responsible for freeing the working-memory block.
| int sceVoiceStart | ( | const SceVoiceStartParam * | param | ) |
Attach the Voice instance to its working-memory block and start processing.
FW 3.60 uses 0x28000 bytes as private memory followed by 0x18000 bytes as shared memory. It does not validate the memory-block size, so the supplied block must contain at least SCE_VOICE_WORKING_MEMORY_SIZE bytes. SceVoice does not take ownership of the block; it must remain allocated until sceVoiceStop or sceVoiceEnd returns.
Calling this function for an already started instance succeeds without changing the current working-memory block. A non-NULL param is still required in that case.
| [in] | param | - Start parameters. |
| int sceVoiceStop | ( | void | ) |
Stop Voice processing and detach the working-memory block.
Port configurations and connections are retained, but their audio-processing resources and buffered data are discarded. A later sceVoiceStart recreates the processing resources. SceVoice does not free the caller-owned memory block.
Calling this function when Voice is initialized but already stopped succeeds.
| int sceVoiceGetResourceInfo | ( | SceVoiceResourceInfo * | info | ) |
Get the port limits assigned to this Voice instance.
On FW 3.60 the returned limits are seven encoded input ports, seven encoded output ports, one device input port, one device output port, and 64 ports in total.
| [out] | info | - Receives the resource limits. |
| int sceVoiceCheckTopology | ( | void | ) |
Check whether the current port connections are valid.
FW 3.60 checks that every created port has at least one connection. It also requires each adjacent pair of OUT_VOICE ports in the internal output list to use the same bitrate, the same per-port mute state (zero or nonzero), and exactly equal volume values. When both IN_DEVICE and IN_PCMAUDIO ports exist, it also rejects an OUT_VOICE port connected from IN_PCMAUDIO while that output's encoder has not been assigned, as occurs before Voice is started.
| int sceVoiceSetMuteFlagAll | ( | SceBool | mute | ) |
Set the process-wide mute-reporting override.
A nonzero value forces sceVoiceGetMuteFlag to report every port as muted. FW 3.60 audio processing reads each port's individual mute flag directly, so this function does not itself silence the ports.
| [in] | mute | - Nonzero to force the reported mute state to one, or zero to report each port's individual mute flag. |
| int sceVoiceSetMuteFlag | ( | SceVoicePortId | port_id, |
| SceBool | mute | ||
| ) |
Set one port's mute flag.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| [in] | mute | - Nonzero to mute the port, or zero to unmute it. |
| int sceVoiceGetMuteFlag | ( | SceVoicePortId | port_id, |
| SceUInt16 * | mute | ||
| ) |
Get one port's reported mute flag.
The process-wide flag set by sceVoiceSetMuteFlagAll overrides the individual flag returned by this function. On FW 3.60 that process-wide flag does not affect audio processing.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| [out] | mute | - Receives 1 when muted or 0 when unmuted. |
| int sceVoiceSetVolume | ( | SceVoicePortId | port_id, |
| float | volume | ||
| ) |
Set one port's linear volume.
FW 3.60 stores the value without limiting its range. During PCM processing, scaled samples are clamped to the signed 16-bit range.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| [in] | volume | - Linear volume; 1.0 is unity gain. |
| int sceVoiceGetVolume | ( | SceVoicePortId | port_id, |
| float * | volume | ||
| ) |
Get one port's linear volume.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| [out] | volume | - Receives the stored volume. |
| int sceVoiceSetBitRate | ( | SceVoicePortId | port_id, |
| SceUInt32 | bit_rate | ||
| ) |
Change the bitrate of an encoded input or output port.
Changing the bitrate creates a new encoder or decoder for the port and discards its buffered data.
| [in] | port_id | - Encoded input or output port identifier. |
| [in] | bit_rate | - New codec bitrate; one of SceVoiceBitRate. |
| int sceVoiceGetBitRate | ( | SceVoicePortId | port_id, |
| SceUInt32 * | bit_rate | ||
| ) |
Get the bitrate of an encoded input or output port.
| [in] | port_id | - Encoded input or output port identifier. |
| [out] | bit_rate | - Receives the configured codec bitrate; one of SceVoiceBitRate. |
| int sceVoiceSetPortAttr | ( | SceVoicePortId | port_id, |
| SceVoicePortAttr | attr, | ||
| const SceInt32 * | value | ||
| ) |
Set a port attribute.
This function is exported, but FW 3.60 rejects every attribute for an existing port with SCE_VOICE_ERROR_INVALID_ARGUMENT. For a port ID within the valid range that does not identify an existing port, it returns SCE_VOICE_ERROR_INVALID_PORT_ID.
| [in] | port_id | - Port identifier. |
| [in] | attr | - Attribute selector. |
| [in] | value | - Attribute value. |
| int sceVoiceGetPortAttr | ( | SceVoicePortId | port_id, |
| SceVoicePortAttr | attr, | ||
| SceInt32 * | value | ||
| ) |
Get a port attribute.
On FW 3.60, querying SCE_VOICE_PORT_ATTR_AUDIO_INPUT_OWNERSHIP writes a defined value only for a SCE_VOICE_PORT_TYPE_IN_DEVICE port. Other port types return success without modifying value.
| [in] | port_id | - Port identifier. |
| [in] | attr | - Attribute selector. |
| [out] | value | - Receives the attribute value. |
| int sceVoiceCreatePort | ( | SceVoicePortId * | port_id, |
| const SceVoicePortParam * | param | ||
| ) |
Create a Voice port.
PCMAUDIO ports accept signed 16-bit little-endian PCM at 16000 Hz. Their effective byte capacity is rounded down to a multiple of 512 and must be from 1024 through 64512 bytes. VOICE ports use one of SceVoiceBitRate. FW 3.60 truncates the rounded PCM capacity to 16 bits before validating it; callers should pass a value in the documented range rather than relying on that wraparound.
For application-fed input ports, SceVoicePortParam::threshold must be shorter than the duration represented by the port's buffer. The type-specific union member must be zero for a device port.
| [out] | port_id | - Receives a port identifier from 0 through 63. |
| [in] | param | - Port configuration. |
FW 3.60 writes 0xFF to port_id before validation. If immediate startup of the port's audio processing fails, the function returns that error after creating the port and replacing 0xFF with its valid port ID.
| int sceVoiceUpdatePort | ( | SceVoicePortId | port_id, |
| const SceVoicePortParam * | param | ||
| ) |
Update an existing port's configuration.
The port type cannot be changed. Changing an encoded bitrate creates a new encoder or decoder for the port and discards its buffered data.
Do not change a PCMAUDIO port's data.buffer_size on FW 3.60. The function never reallocates or reinitializes the PCM ring buffers. The first update stores the new requested size but keeps the old size used for resource accounting. A later update recalculates the accounting size from that stored value. Deleting the port then releases resources according to the changed accounting size, not the capacity originally allocated. This function does not check SceVoicePortParam::threshold again against the queue duration.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| [in] | param | - Replacement configuration with the same port type. |
| int sceVoiceConnectIPortToOPort | ( | SceVoicePortId | input_port_id, |
| SceVoicePortId | output_port_id | ||
| ) |
Connect an input port to an output port.
Input types 0 through 2 can connect to output types 3 through 5. FW 3.60 rejects a direct IN_VOICE to OUT_VOICE connection and duplicate connections. An instance can contain at most 128 connections.
| [in] | input_port_id | - Device, PCM, or encoded input port. |
| [in] | output_port_id | - PCM, encoded, or device output port. |
| int sceVoiceDisconnectIPortFromOPort | ( | SceVoicePortId | input_port_id, |
| SceVoicePortId | output_port_id | ||
| ) |
Disconnect an input port from an output port.
| [in] | input_port_id | - Connected input port. |
| [in] | output_port_id | - Connected output port. |
| int sceVoiceDeletePort | ( | SceVoicePortId | port_id | ) |
Delete a Voice port and remove its connections.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| int sceVoiceWriteToIPort | ( | SceVoicePortId | port_id, |
| const void * | data, | ||
| SceSize * | size, | ||
| SceInt16 | frame_gap | ||
| ) |
Write application data to a PCM or encoded input port.
On return, size contains the number of bytes accepted. PCM writes ignore frame_gap. For encoded input, a nonnegative frame gap inserts that many missing frames before the supplied data. A negative value begins backfilling previously marked missing frames at that relative frame offset behind the current stream write point.
| [in] | port_id | - SCE_VOICE_PORT_TYPE_IN_PCMAUDIO or SCE_VOICE_PORT_TYPE_IN_VOICE port. |
| [in] | data | - Data to write. |
| [in,out] | size | - Requested byte count and resulting accepted byte count. |
| [in] | frame_gap | - Encoded-stream frame gap or negative backfill offset; ignored for PCM input. |
When the operation fails after argument validation, FW 3.60 sets size to zero.
| int sceVoiceReadFromOPort | ( | SceVoicePortId | port_id, |
| void * | data, | ||
| SceSize * | size | ||
| ) |
Read application data from a PCM or encoded output port.
On return, size contains the number of bytes copied. Encoded reads are rounded down to complete codec frames; PCM reads are rounded down to an even byte count.
| [in] | port_id | - SCE_VOICE_PORT_TYPE_OUT_PCMAUDIO or SCE_VOICE_PORT_TYPE_OUT_VOICE port. |
| [out] | data | - Destination buffer. |
| [in,out] | size | - Destination capacity and resulting byte count. |
When the operation fails after argument validation, FW 3.60 sets size to zero.
| int sceVoiceGetPortInfo | ( | SceVoicePortId | port_id, |
| SceVoicePortInfo * | info | ||
| ) |
Get one port's type, processing state, available data, and frame size.
If Voice has not been started, FW 3.60 clears the complete output structure and returns SCE_VOICE_ERROR_NOT_STARTED. On success, it writes only port_type, state, data_size, and frame_size; the two reserved members are unchanged.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| [out] | info | - Receives the port information. |
| int sceVoiceResetPort | ( | SceVoicePortId | port_id | ) |
Clear one port's buffered data and reset its processing state.
An ACTIVE port becomes IDLE. INACTIVE, IDLE, and BUFFERING ports retain their current internal state. The state visible through sceVoiceGetPortInfo is updated by a later processing synchronization.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| int sceVoicePausePort | ( | SceVoicePortId | port_id | ) |
Pause processing for one port.
Pausing retains buffered data. Application-fed input ports retain their internal processing state; device and output ports change their internal state to INACTIVE. FW 3.60 does not update the reported state while a port is paused, so sceVoiceGetPortInfo can continue reporting the state from before the pause until processing resumes.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| int sceVoiceResumePort | ( | SceVoicePortId | port_id | ) |
Resume processing for one port.
| [in] | port_id | - Port identifier returned by sceVoiceCreatePort. |
| int sceVoicePausePortAll | ( | void | ) |
Pause processing for every Voice port in the calling process.
Pausing retains buffered data and each port's internal processing state. FW 3.60 also retains the previously reported state, so sceVoiceGetPortInfo can continue reporting that state while all ports are paused.
| int sceVoiceResumePortAll | ( | void | ) |
Resume processing for every Voice port in the calling process.
| SceInt16 SceVoiceEventPortDataReady::port_count |
Number of valid entries in port_ids.
| SceUInt16 SceVoiceEventPortDataReady::port_ids[SCE_VOICE_MAX_EVENT_PORTS] |
Output-voice ports with encoded data available.
| SceUInt8 SceVoiceEventAudioInputOwnershipChanged::owned |
Nonzero when this process owns the adopted audio-input port.
| SceUInt8 SceVoiceEventAudioInputOwnershipChanged::reserved[0xF] |
| SceUInt32 SceVoiceEvent::event_type |
One of SceVoiceEventType.
| void* SceVoiceEvent::user_data |
Value supplied to sceVoiceInit.
| SceVoiceEventPortDataReady { ... } ::port_data_ready |
| SceVoiceEventAudioInputOwnershipChanged { ... } ::audio_input_ownership_changed |
| union { ... } SceVoiceEvent::event_payload |
| SceUInt32 SceVoiceInitParam::application_type |
One of SceVoiceApplicationType.
| SceVoiceEventCallback SceVoiceInitParam::event_callback |
Optional event callback, or NULL to disable events.
| void* SceVoiceInitParam::user_data |
Copied to SceVoiceEvent::user_data.
| SceUInt32 SceVoiceInitParam::reserved[5] |
Ignored on FW 3.60.
| SceUID SceVoiceStartParam::mem_block_id |
Memory block providing at least SCE_VOICE_WORKING_MEMORY_SIZE bytes.
| SceUInt32 SceVoiceStartParam::reserved[7] |
Ignored on FW 3.60.
| SceUInt32 SceVoicePortParam::port_type |
One of SceVoicePortType.
| SceUInt16 SceVoicePortParam::threshold |
Buffering threshold for application input, in milliseconds; at least two frame durations are used.
| SceUInt16 SceVoicePortParam::mute_flag |
Nonzero to create the port muted.
| float SceVoicePortParam::volume |
Linear volume; 1.0 is unity gain.
| SceSize { ... } ::buffer_size |
PCM byte capacity for PCMAUDIO ports.
| SceUInt32 { ... } ::bit_rate |
One of SceVoiceBitRate for VOICE ports.
| union { ... } SceVoicePortParam::data |
| SceUInt32 SceVoicePortParam::pcm_data_type |
One of SceVoicePcmDataType for PCMAUDIO ports.
| SceUInt32 SceVoicePortParam::sampling_rate |
One of SceVoiceSamplingRate for PCMAUDIO ports.
| SceUInt16 SceVoiceResourceInfo::max_voice_input_ports |
Maximum number of IN_VOICE ports.
| SceUInt16 SceVoiceResourceInfo::max_voice_output_ports |
Maximum number of OUT_VOICE ports.
| SceUInt16 SceVoiceResourceInfo::max_device_input_ports |
Maximum number of IN_DEVICE ports.
| SceUInt16 SceVoiceResourceInfo::max_device_output_ports |
Maximum number of OUT_DEVICE ports.
| SceUInt16 SceVoiceResourceInfo::max_ports |
Maximum number of ports of all types.
| SceUInt32 SceVoicePortInfo::port_type |
One of SceVoicePortType.
| SceUInt32 SceVoicePortInfo::state |
One of SceVoicePortState.
| SceUInt32 SceVoicePortInfo::reserved0 |
Not written on FW 3.60.
| SceSize SceVoicePortInfo::data_size |
Free bytes in the input ring buffer or queued bytes in the output ring buffer.
| SceSize SceVoicePortInfo::frame_size |
Encoded or PCM processing-frame size in bytes.
| SceUInt32 SceVoicePortInfo::reserved1 |
Not written on FW 3.60.