![]() |
vitasdk
Documentation of the vitasdk
|
Exports for User. More...
Data Structures | |
| struct | SceNgsBufferInfo |
| Buffer owned by the caller and used by NGS in place. More... | |
| struct | SceNgsSystemInitParams |
| System sizing and processing configuration. More... | |
| struct | SceNgsRackDescription |
| Description used to size and create a rack. More... | |
| struct | SceNgsPatchSetupInfo |
| Endpoints used to create one voice-to-voice patch. More... | |
| struct | SceNgsVoicePreset |
| Voice preset header. More... | |
| struct | SceNgsCallbackInfo |
| Information delivered to an NGS callback. More... | |
| struct | SceNgsParamsDescriptor |
| Header shared by every module-specific parameter structure. More... | |
| struct | SceNgsAT9SkipBufferInfo |
| Byte range and samples to skip at each end when decoding an ATRAC9 sample interval. More... | |
| struct | SceNgsModuleParamHeader |
| Header of one record accepted by sceNgsVoiceSetParamsBlock. More... | |
| struct | SceNgsVolumeMatrix |
Gain matrix indexed as matrix[outputChannel][inputChannel]. More... | |
| struct | SceNgsPatchRouteInfo |
| Current route and gain information returned by sceNgsPatchGetInfo. More... | |
| struct | SceNgsVoiceInfo |
| Current voice and voice-definition information. More... | |
| struct | SceSulphaNgsConfig |
| Sulpha NGS trace-agent capacities. More... | |
Macros | |
| #define | SCE_NGS_MAX_SYSTEM_CHANNELS 2 |
Typedefs | |
| typedef struct SceNgsVoiceDefinition | SceNgsVoiceDefinition |
| Opaque immutable voice definition. | |
Functions | |
| VITASDK_BUILD_ASSERT_EQ (0x8, SceNgsBufferInfo) | |
| VITASDK_BUILD_ASSERT_EQ (0x14, SceNgsSystemInitParams) | |
| VITASDK_BUILD_ASSERT_EQ (0x18, SceNgsRackDescription) | |
| VITASDK_BUILD_ASSERT_EQ (0x14, SceNgsPatchSetupInfo) | |
| VITASDK_BUILD_ASSERT_EQ (0x18, SceNgsVoicePreset) | |
| VITASDK_BUILD_ASSERT_EQ (0x1C, SceNgsCallbackInfo) | |
| VITASDK_BUILD_ASSERT_EQ (0x8, SceNgsParamsDescriptor) | |
| VITASDK_BUILD_ASSERT_EQ (0x10, SceNgsAT9SkipBufferInfo) | |
| VITASDK_BUILD_ASSERT_EQ (0x8, SceNgsModuleParamHeader) | |
| VITASDK_BUILD_ASSERT_EQ (0x10, SceNgsVolumeMatrix) | |
| VITASDK_BUILD_ASSERT_EQ (0x18, SceNgsPatchRouteInfo) | |
| VITASDK_BUILD_ASSERT_EQ (0x18, SceNgsVoiceInfo) | |
| VITASDK_BUILD_ASSERT_EQ (0x8, SceSulphaNgsConfig) | |
| SceInt32 | sceNgsAT9GetSectionDetails (SceInt32 start_sample_offset, SceInt32 num_samples, SceInt32 config_data, SceNgsAT9SkipBufferInfo *at9_info_buffer) |
| Compute the encoded byte range and samples to skip at each end for an ATRAC9 sample range. | |
| SceInt32 | sceNgsModuleGetNumPresets (SceNgsHSynSystem system_handle, SceNgsModuleID module_id, SceUInt32 *num_presets) |
| Return the number of built-in presets provided by a module type. | |
| SceInt32 | sceNgsModuleGetPreset (SceNgsHSynSystem system_handle, SceNgsModuleID module_id, SceUInt32 preset_index, SceNgsBufferInfo *params_buffer) |
| Copy one built-in module preset into a caller-owned buffer. | |
| SceInt32 | sceNgsPatchCreateRouting (const SceNgsPatchSetupInfo *patch_info, SceNgsHPatch *patch_handle) |
| Create a route from one voice output to one voice input. | |
| SceInt32 | sceNgsPatchGetInfo (SceNgsHPatch patch_handle, SceNgsPatchRouteInfo *route_info, SceNgsPatchSetupInfo *setup) |
| Get the current source/destination channel counts and gains of a patch. | |
| SceInt32 | sceNgsPatchRemoveRouting (SceNgsHPatch patch_handle) |
| Remove a voice-to-voice patch and release its source output slot. | |
| SceInt32 | sceNgsRackGetRequiredMemorySize (SceNgsHSynSystem system_handle, const SceNgsRackDescription *rack_desc, SceSize *size) |
| Compute the rack-buffer size required for a description. | |
| SceInt32 | sceNgsRackGetVoiceHandle (SceNgsHRack rack_handle, SceUInt32 index, SceNgsHVoice *voice_handle) |
| Return one voice allocated by a rack. | |
| SceInt32 | sceNgsRackInit (SceNgsHSynSystem system_handle, const SceNgsBufferInfo *rack_buffer, const SceNgsRackDescription *rack_desc, SceNgsHRack *rack_handle) |
| Create a rack and all of its voices in caller-owned memory. | |
| SceInt32 | sceNgsRackRelease (SceNgsHRack rack_handle, SceNgsRackReleaseCallbackFunc callback_func_ptr) |
| Stop every voice, remove every connected patch, and release a rack. | |
| SceInt32 | sceNgsRackSetParamErrorCallback (SceNgsHRack rack_handle, SceNgsParamsErrorCallbackFunc callback_func_ptr) |
| Set the parameter-range callback for one rack. | |
| SceInt32 | sceNgsSystemGetRequiredMemorySize (const SceNgsSystemInitParams *synth_params, SceSize *size) |
| Compute the system-buffer size required by an initialization configuration. | |
| SceInt32 | sceNgsSystemInit (void *synth_sys_memory, SceSize mem_size, const SceNgsSystemInitParams *synth_params, SceNgsHSynSystem *system_handle) |
| Initialize an NGS system in caller-owned memory. | |
| SceInt32 | sceNgsSystemLock (SceNgsHSynSystem system_handle) |
| Lock the system's internal update state. | |
| SceInt32 | sceNgsSystemRelease (SceNgsHSynSystem system_handle) |
| Release a system after all of its racks have been released. | |
| SceInt32 | sceNgsSystemSetFlags (SceNgsHSynSystem system_handle, SceUInt32 system_flags) |
| Replace the system flags used by subsequent parameter operations. | |
| SceInt32 | sceNgsSystemSetParamErrorCallback (SceNgsHSynSystem system_handle, SceNgsParamsErrorCallbackFunc callback_func_ptr) |
| Set the fallback parameter-range callback for a system. | |
| SceInt32 | sceNgsSystemUnlock (SceNgsHSynSystem system_handle) |
| Unlock a system previously locked with sceNgsSystemLock. | |
| SceInt32 | sceNgsSystemUpdate (SceNgsHSynSystem system_handle) |
| Process one audio grain and run every queued callback. | |
| SceInt32 | sceNgsVoiceBypassModule (SceNgsHVoice voice_handle, SceUInt32 module, SceUInt32 bypass_flag) |
| Set the bypass state of one module in a voice definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetAtrac9Voice (void) |
| Return the complex ATRAC9 playback voice definition with four sends. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetCompressorBuss (void) |
| Return an input-mix, compressor, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetCompressorSideChainBuss (void) |
| Return a two-input side-chain compressor bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetDelayBuss (void) |
| Return an input-mix, modulated-delay, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetDistortionBuss (void) |
| Return an input-mix, distortion, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetEnvelopeBuss (void) |
| Return an input-mix, amplitude-envelope, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetEqBuss (void) |
| Return an input-mix, four-band parametric-EQ, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetMasterBuss (void) |
| Return the master bus definition that exposes PCM output to the caller. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetMixerBuss (void) |
| Return a bus definition that mixes multiple input voices. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetPauserBuss (void) |
| Return an input-mix, click-free pauser, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetPitchShiftBuss (void) |
| Return an input-mix, pitch-shift, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetReverbBuss (void) |
| Return an input-mix, environmental-reverb, and output bus definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetSasEmuVoice (void) |
| Return the libSas-emulation voice definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetScreamAtrac9Voice (void) |
| Return the Scream ATRAC9 playback voice definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetScreamVoice (void) |
| Return the Scream waveform playback voice definition. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetSimpleAtrac9Voice (void) |
| Return the basic ATRAC9 playback voice definition with two sends. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetSimpleVoice (void) |
| Return the basic PCM/VAG playback voice definition with two sends. | |
| const SceNgsVoiceDefinition * | sceNgsVoiceDefGetTemplate1 (void) |
| Return the complex waveform playback template with signal generation and four sends. | |
| SceInt32 | sceNgsVoiceGetInfo (SceNgsHVoice voice_handle, SceNgsVoiceInfo *info) |
| Get one voice's current key state, module counts, and routing information. | |
| SceInt32 | sceNgsVoiceGetModuleBypass (SceNgsHVoice voice_handle, SceUInt32 module, SceUInt32 *bypass_flag) |
| Get the bypass state of one module. | |
| SceInt32 | sceNgsVoiceGetModuleType (SceNgsHVoice voice_handle, SceUInt32 module, SceNgsModuleID *module_type) |
| Map a zero-based module index to its module type ID. | |
| SceInt32 | sceNgsVoiceGetOutputPatch (SceNgsHVoice voice_handle, SceInt32 output_index, SceInt32 sub_index, SceNgsHPatch *patch_handle) |
| Return the patch occupying one voice output slot. | |
| SceInt32 | sceNgsVoiceGetParamsOutOfRange (SceNgsHVoice voice_handle, SceUInt32 module, char *message_buffer) |
| Format the most recent parameter-range result for one module. | |
| SceInt32 | sceNgsVoiceGetStateData (SceNgsHVoice voice_handle, SceUInt32 module, void *memory, SceSize mem_size) |
| Copy one module's runtime state snapshot. | |
| SceInt32 | sceNgsVoiceInit (SceNgsHVoice voice_handle, const SceNgsVoicePreset *preset, SceUInt32 init_flags) |
| Reinitialize a stopped voice and optionally reset patches, preset, or callbacks. | |
| SceInt32 | sceNgsVoiceKeyOff (SceNgsHVoice voice_handle) |
| Request release/envelope processing for a playing voice. | |
| SceInt32 | sceNgsVoiceKill (SceNgsHVoice voice_handle) |
| Immediately stop a playing or keyed-off voice and return it to the stopped state. | |
| SceInt32 | sceNgsVoiceLockParams (SceNgsHVoice voice_handle, SceUInt32 module, SceNgsParamsID params_interface_id, SceNgsBufferInfo *params_buffer) |
| Lock and expose one module's live parameter block. | |
| SceInt32 | sceNgsVoicePatchSetVolume (SceNgsHPatch patch_handle, SceInt32 output_channel, SceInt32 input_channel, SceFloat32 volume) |
Set one gain in a patch's [output][input] matrix. | |
| SceInt32 | sceNgsVoicePatchSetVolumes (SceNgsHPatch patch_handle, SceInt32 output_channel, const SceFloat32 *volumes, SceInt32 volume_count) |
| Set the one or two input-channel gains for a patch output. | |
| SceInt32 | sceNgsVoicePatchSetVolumesMatrix (SceNgsHPatch patch_handle, const SceNgsVolumeMatrix *matrix) |
| Replace a patch's complete 2x2 output-to-input gain matrix. | |
| SceInt32 | sceNgsVoicePause (SceNgsHVoice voice_handle) |
| Pause voice processing without changing whether the voice is playing or keyed off. | |
| SceInt32 | sceNgsVoicePlay (SceNgsHVoice voice_handle) |
| Start a stopped voice. | |
| SceInt32 | sceNgsVoiceResume (SceNgsHVoice voice_handle) |
| Resume a paused voice without changing its play/key-off state. | |
| SceInt32 | sceNgsVoiceSetFinishedCallback (SceNgsHVoice voice_handle, SceNgsCallbackFunc callback_func_ptr, void *user_data) |
| Set the callback queued when a voice reaches its finished state. | |
| SceInt32 | sceNgsVoiceSetModuleCallback (SceNgsHVoice voice_handle, SceUInt32 module, SceNgsModuleCallbackFunc callback_func_ptr, void *user_data) |
| Set the callback for events from the module at a given index. | |
| SceInt32 | sceNgsVoiceSetParamsBlock (SceNgsHVoice voice_handle, const SceNgsModuleParamHeader *param_data, SceSize size, SceInt32 *error_count) |
| Apply a packed sequence of module parameter records. | |
| SceInt32 | sceNgsVoiceSetPreset (SceNgsHVoice voice_handle, const SceNgsVoicePreset *voice_preset) |
| Restore module defaults, then apply an optional voice preset. | |
| SceInt32 | sceNgsVoiceUnlockParams (SceNgsHVoice voice_handle, SceUInt32 module) |
| Commit and unlock a module parameter block returned by sceNgsVoiceLockParams. | |
| SceInt32 | sceSulphaNgsGetDefaultConfig (SceSulphaNgsConfig *config) |
| Fill a Sulpha NGS configuration with the FW 3.60 defaults. | |
| SceInt32 | sceSulphaNgsGetNeededMemory (const SceSulphaNgsConfig *config, SceSize *size_in_bytes) |
| Compute all memory needed by the Sulpha NGS agent and its fixed NGS pools. | |
| SceInt32 | sceSulphaNgsInit (const SceSulphaNgsConfig *config, void *buffer, SceSize size_in_bytes) |
| Initialize Sulpha NGS tracing for the calling process. | |
| SceInt32 | sceSulphaNgsSetRackName (SceNgsHRack rack_handle, const char *name) |
| Assign a diagnostic Sulpha name to an initialized rack. | |
| SceInt32 | sceSulphaNgsSetSampleName (const void *location, SceSize length, const char *name) |
| Associate a diagnostic name with a sample-memory range. | |
| SceInt32 | sceSulphaNgsSetSynthName (SceNgsHSynSystem synth_handle, const char *name) |
| Assign a diagnostic Sulpha name to an initialized NGS system. | |
| SceInt32 | sceSulphaNgsSetVoiceName (SceNgsHVoice voice_handle, const char *name) |
| Assign a diagnostic Sulpha name to an initialized voice. | |
| SceInt32 | sceSulphaNgsShutdown (void) |
| Unregister the Sulpha NGS agent shared by all threads in the process and release its registrations. | |
| SceInt32 | sceSulphaNgsTrace (const char *message) |
Emit message as a Sulpha trace event in the Ngs category. | |
Variables | |
| void * | SceNgsBufferInfo::data |
| Buffer base address. | |
| SceSize | SceNgsBufferInfo::size |
| Buffer size in bytes. | |
| SceInt32 | SceNgsSystemInitParams::max_racks |
| Maximum number of racks; must be from 1 through 64. | |
| SceInt32 | SceNgsSystemInitParams::max_voices |
| Maximum number of voices; must be from 1 through 256. | |
| SceInt32 | SceNgsSystemInitParams::granularity |
| Number of samples processed per update; a multiple of 64 from 64 through 512. | |
| SceInt32 | SceNgsSystemInitParams::sample_rate |
| System sample rate; must be 48000 on FW 3.60. | |
| SceInt32 | SceNgsSystemInitParams::reserved |
| Must be at least zero; otherwise ignored on FW 3.60. | |
| const SceNgsVoiceDefinition * | SceNgsRackDescription::voice_definition |
| Immutable definition returned by a sceNgsVoiceDefGet* function. | |
| SceInt32 | SceNgsRackDescription::voice_count |
| Number of voices to allocate; must be greater than zero. | |
| SceInt32 | SceNgsRackDescription::channels_per_voice |
| Audio channels per voice; must be 1 or 2. | |
| SceInt32 | SceNgsRackDescription::max_patches_per_input |
| Patch slots for each dynamic input. Input/mixer racks require a nonzero value. | |
| SceInt32 | SceNgsRackDescription::patches_per_output |
| Patch slots allocated for each voice output. | |
| void * | SceNgsRackDescription::user_data |
| Value delivered to the callback passed to sceNgsRackRelease. | |
| SceNgsHVoice | SceNgsPatchSetupInfo::source_voice |
| Source voice. | |
| SceInt32 | SceNgsPatchSetupInfo::source_output_index |
| Source voice output index. | |
| SceInt32 | SceNgsPatchSetupInfo::source_output_sub_index |
| Source output patch slot, or -1 to use the first free slot. | |
| SceNgsHVoice | SceNgsPatchSetupInfo::destination_voice |
| Destination voice; it must belong to the same system as the source. | |
| SceInt32 | SceNgsPatchSetupInfo::destination_input_index |
| Destination voice input index. | |
| SceInt32 | SceNgsVoicePreset::name_offset |
| Offset of the preset name. Ignored when applying the preset on FW 3.60. | |
| SceUInt32 | SceNgsVoicePreset::name_length |
| Preset-name length. Ignored when applying the preset on FW 3.60. | |
| SceInt32 | SceNgsVoicePreset::preset_data_offset |
| Offset of the variable-length module parameter records, or zero. | |
| SceUInt32 | SceNgsVoicePreset::preset_data_size |
| Size of the module parameter records in bytes. | |
| SceInt32 | SceNgsVoicePreset::bypass_flags_offset |
| Offset of an array of module indices to bypass, or zero. | |
| SceUInt32 | SceNgsVoicePreset::bypass_flags_count |
| Number of module indices in the bypass array. | |
| SceNgsHVoice | SceNgsCallbackInfo::voice_handle |
| Voice associated with the event, or zero for a rack-release event. | |
| SceNgsHRack | SceNgsCallbackInfo::rack_handle |
| Rack associated with the event. | |
| SceNgsModuleID | SceNgsCallbackInfo::module_id |
| Module type associated with a module or parameter event. | |
| SceUInt32 | SceNgsCallbackInfo::callback_reason |
| First module-defined reason value. | |
| SceUInt32 | SceNgsCallbackInfo::callback_reason2 |
| Second module-defined reason value. | |
| void * | SceNgsCallbackInfo::callback_ptr |
| Optional module-defined pointer; valid for the duration of the callback. | |
| void * | SceNgsCallbackInfo::user_data |
| User value registered with the callback or rack description. | |
| SceNgsParamsID | SceNgsParamsDescriptor::id |
| SceSize | SceNgsParamsDescriptor::size |
| Size beginning at id, including this field and the module-specific data. | |
| SceInt32 | SceNgsAT9SkipBufferInfo::start_byte_offset |
| Byte offset of the first required ATRAC9 packet. | |
| SceInt32 | SceNgsAT9SkipBufferInfo::num_bytes |
| Number of bytes to make available to the decoder. | |
| SceInt16 | SceNgsAT9SkipBufferInfo::start_skip |
| Samples to discard at the start of the first decoded packet. | |
| SceInt16 | SceNgsAT9SkipBufferInfo::end_skip |
| Samples to discard at the end of the last decoded packet. | |
| SceInt32 | SceNgsAT9SkipBufferInfo::is_super_packet |
| 1 for the four-frame packet layout, otherwise 0. | |
| SceInt32 | SceNgsModuleParamHeader::module_index |
| Zero-based index in the voice definition. | |
| SceInt32 | SceNgsModuleParamHeader::channel_index |
| Channel to update, or -1 to update every channel represented by the following parameter descriptor. | |
| SceFloat32 | SceNgsVolumeMatrix::matrix [SCE_NGS_MAX_SYSTEM_CHANNELS][SCE_NGS_MAX_SYSTEM_CHANNELS] |
| SceInt32 | SceNgsPatchRouteInfo::output_channels |
| Source-rack channel count. | |
| SceInt32 | SceNgsPatchRouteInfo::input_channels |
| Destination-rack channel count. | |
| SceNgsVolumeMatrix | SceNgsPatchRouteInfo::volume_matrix |
| Current output-to-input gain matrix. | |
| SceUInt32 | SceNgsVoiceInfo::voice_state |
| Bitwise OR of SceNgsVoiceState values. | |
| SceUInt32 | SceNgsVoiceInfo::num_modules |
| Number of modules in the voice definition. | |
| SceUInt32 | SceNgsVoiceInfo::num_inputs |
| Number of dynamic input modules in the voice definition. | |
| SceUInt32 | SceNgsVoiceInfo::num_outputs |
| Number of outputs exposed by the voice definition. | |
| SceUInt32 | SceNgsVoiceInfo::num_patches_per_output |
| Patch slots allocated for each output. | |
| SceUInt32 | SceNgsVoiceInfo::update_passed |
| Number of processing updates completed for this voice since its most recent initialization or play. | |
| SceUInt32 | SceSulphaNgsConfig::max_named_samples |
| Maximum sample-memory ranges that can be named; the FW 3.60 default is 1024. | |
| SceUInt32 | SceSulphaNgsConfig::api_trace_buffer_size |
| NGS API-call trace buffer size in bytes; only complete 16-byte records are used. The FW 3.60 default is 4096. | |
Exports for User.
Include the header file in your project:
Link the library to the executable:
| struct SceNgsBufferInfo |
Buffer owned by the caller and used by NGS in place.
| Data Fields | ||
|---|---|---|
| void * | data | Buffer base address. |
| SceSize | size | Buffer size in bytes. |
| struct SceNgsSystemInitParams |
System sizing and processing configuration.
| Data Fields | ||
|---|---|---|
| SceInt32 | max_racks | Maximum number of racks; must be from 1 through 64. |
| SceInt32 | max_voices | Maximum number of voices; must be from 1 through 256. |
| SceInt32 | granularity | Number of samples processed per update; a multiple of 64 from 64 through 512. |
| SceInt32 | sample_rate | System sample rate; must be 48000 on FW 3.60. |
| SceInt32 | reserved | Must be at least zero; otherwise ignored on FW 3.60. |
| struct SceNgsRackDescription |
Description used to size and create a rack.
| Data Fields | ||
|---|---|---|
| const SceNgsVoiceDefinition * | voice_definition | Immutable definition returned by a sceNgsVoiceDefGet* function. |
| SceInt32 | voice_count | Number of voices to allocate; must be greater than zero. |
| SceInt32 | channels_per_voice | Audio channels per voice; must be 1 or 2. |
| SceInt32 | max_patches_per_input | Patch slots for each dynamic input. Input/mixer racks require a nonzero value. |
| SceInt32 | patches_per_output | Patch slots allocated for each voice output. |
| void * | user_data | Value delivered to the callback passed to sceNgsRackRelease. |
| struct SceNgsPatchSetupInfo |
Endpoints used to create one voice-to-voice patch.
| Data Fields | ||
|---|---|---|
| SceNgsHVoice | source_voice | Source voice. |
| SceInt32 | source_output_index | Source voice output index. |
| SceInt32 | source_output_sub_index | Source output patch slot, or -1 to use the first free slot. |
| SceNgsHVoice | destination_voice | Destination voice; it must belong to the same system as the source. |
| SceInt32 | destination_input_index | Destination voice input index. |
| struct SceNgsVoicePreset |
Voice preset header.
Offsets are relative to the start of this structure.
| Data Fields | ||
|---|---|---|
| SceInt32 | name_offset | Offset of the preset name. Ignored when applying the preset on FW 3.60. |
| SceUInt32 | name_length | Preset-name length. Ignored when applying the preset on FW 3.60. |
| SceInt32 | preset_data_offset | Offset of the variable-length module parameter records, or zero. |
| SceUInt32 | preset_data_size | Size of the module parameter records in bytes. |
| SceInt32 | bypass_flags_offset | Offset of an array of module indices to bypass, or zero. |
| SceUInt32 | bypass_flags_count | Number of module indices in the bypass array. |
| struct SceNgsCallbackInfo |
Information delivered to an NGS callback.
A voice-finished callback receives the voice, rack, and user-data fields. A rack-release callback receives the rack and user-data fields. A module callback additionally receives the module ID, two module-defined reason values, and an optional module-defined pointer. Parameter-range callbacks receive the voice, rack, and module ID; the remaining fields are zero on FW 3.60.
| Data Fields | ||
|---|---|---|
| SceNgsHVoice | voice_handle | Voice associated with the event, or zero for a rack-release event. |
| SceNgsHRack | rack_handle | Rack associated with the event. |
| SceNgsModuleID | module_id | Module type associated with a module or parameter event. |
| SceUInt32 | callback_reason | First module-defined reason value. |
| SceUInt32 | callback_reason2 | Second module-defined reason value. |
| void * | callback_ptr | Optional module-defined pointer; valid for the duration of the callback. |
| void * | user_data | User value registered with the callback or rack description. |
| struct SceNgsParamsDescriptor |
Header shared by every module-specific parameter structure.
| Data Fields | ||
|---|---|---|
| SceNgsParamsID | id | |
| SceSize | size | Size beginning at id, including this field and the module-specific data. |
| struct SceNgsAT9SkipBufferInfo |
Byte range and samples to skip at each end when decoding an ATRAC9 sample interval.
| Data Fields | ||
|---|---|---|
| SceInt32 | start_byte_offset | Byte offset of the first required ATRAC9 packet. |
| SceInt32 | num_bytes | Number of bytes to make available to the decoder. |
| SceInt16 | start_skip | Samples to discard at the start of the first decoded packet. |
| SceInt16 | end_skip | Samples to discard at the end of the last decoded packet. |
| SceInt32 | is_super_packet | 1 for the four-frame packet layout, otherwise 0. |
| struct SceNgsModuleParamHeader |
Header of one record accepted by sceNgsVoiceSetParamsBlock.
| Data Fields | ||
|---|---|---|
| SceInt32 | module_index | Zero-based index in the voice definition. |
| SceInt32 | channel_index | Channel to update, or -1 to update every channel represented by the following parameter descriptor. |
| struct SceNgsVolumeMatrix |
Gain matrix indexed as matrix[outputChannel][inputChannel].
| Data Fields | ||
|---|---|---|
| SceFloat32 | matrix[SCE_NGS_MAX_SYSTEM_CHANNELS][SCE_NGS_MAX_SYSTEM_CHANNELS] | |
| struct SceNgsPatchRouteInfo |
Current route and gain information returned by sceNgsPatchGetInfo.
| Data Fields | ||
|---|---|---|
| SceInt32 | output_channels | Source-rack channel count. |
| SceInt32 | input_channels | Destination-rack channel count. |
| SceNgsVolumeMatrix | volume_matrix | Current output-to-input gain matrix. |
| struct SceNgsVoiceInfo |
Current voice and voice-definition information.
| Data Fields | ||
|---|---|---|
| SceUInt32 | voice_state | Bitwise OR of SceNgsVoiceState values. |
| SceUInt32 | num_modules | Number of modules in the voice definition. |
| SceUInt32 | num_inputs | Number of dynamic input modules in the voice definition. |
| SceUInt32 | num_outputs | Number of outputs exposed by the voice definition. |
| SceUInt32 | num_patches_per_output | Patch slots allocated for each output. |
| SceUInt32 | update_passed | Number of processing updates completed for this voice since its most recent initialization or play. |
| struct SceSulphaNgsConfig |
| #define SCE_NGS_MAX_SYSTEM_CHANNELS 2 |
| typedef struct SceNgsVoiceDefinition SceNgsVoiceDefinition |
Opaque immutable voice definition.
On FW 3.60, this pointer holds an encoded value, not an address. Do not dereference it; store it in SceNgsRackDescription::voice_definition.
| enum SceNgsErrorCode |
Error codes returned by the FW 3.60 NGS implementation.
| enum SceNgsSystemFlag |
Flags accepted by sceNgsSystemSetFlags.
| Enumerator | |
|---|---|
| SCE_NGS_SYSTEM_FLAG_CHECK_PARAMS | Validate parameter ranges when parameter blocks are unlocked or applied. |
| enum SceNgsVoiceInitFlag |
Reset operations selected by sceNgsVoiceInit.
| enum SceNgsVoiceState |
Bitfield reported by SceNgsVoiceInfo::voice_state.
| VITASDK_BUILD_ASSERT_EQ | ( | 0x8 | , |
| SceNgsBufferInfo | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x14 | , |
| SceNgsSystemInitParams | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x18 | , |
| SceNgsRackDescription | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x14 | , |
| SceNgsPatchSetupInfo | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x18 | , |
| SceNgsVoicePreset | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x1C | , |
| SceNgsCallbackInfo | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x8 | , |
| SceNgsParamsDescriptor | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x10 | , |
| SceNgsAT9SkipBufferInfo | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x8 | , |
| SceNgsModuleParamHeader | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x10 | , |
| SceNgsVolumeMatrix | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x18 | , |
| SceNgsPatchRouteInfo | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x18 | , |
| SceNgsVoiceInfo | |||
| ) |
| VITASDK_BUILD_ASSERT_EQ | ( | 0x8 | , |
| SceSulphaNgsConfig | |||
| ) |
| SceInt32 sceNgsAT9GetSectionDetails | ( | SceInt32 | start_sample_offset, |
| SceInt32 | num_samples, | ||
| SceInt32 | config_data, | ||
| SceNgsAT9SkipBufferInfo * | at9_info_buffer | ||
| ) |
Compute the encoded byte range and samples to skip at each end for an ATRAC9 sample range.
The output is cleared before validation. FW 3.60 accepts ATRAC9 frame-duration codes 1, 4, and 7 and requires the low byte of config_data to be 0xFE. Bit 31 of start_sample_offset requests one frame of decoder preroll; the remaining 31 bits contain the sample offset and are backed up by 64, 128, or 256 samples according to the frame-duration code, clamped at zero.
| [in] | start_sample_offset | - First requested decoded sample. |
| [in] | num_samples | - Number of requested samples; must be at least zero. |
| [in] | config_data | - Packed ATRAC9 configuration word. |
| [out] | at9_info_buffer | - Receives the required byte range and sample skips. |
| SceInt32 sceNgsModuleGetNumPresets | ( | SceNgsHSynSystem | system_handle, |
| SceNgsModuleID | module_id, | ||
| SceUInt32 * | num_presets | ||
| ) |
Return the number of built-in presets provided by a module type.
| [in] | system_handle | - Initialized system handle. |
| [in] | module_id | - Module type ID, not a module index in a voice. |
| [out] | num_presets | - Receives the preset count. |
| SceInt32 sceNgsModuleGetPreset | ( | SceNgsHSynSystem | system_handle, |
| SceNgsModuleID | module_id, | ||
| SceUInt32 | preset_index, | ||
| SceNgsBufferInfo * | params_buffer | ||
| ) |
Copy one built-in module preset into a caller-owned buffer.
Initialize both members of params_buffer before the call. Its data buffer must be large enough for the selected preset; the function does not allocate memory or change the buffer-size member.
| [in] | system_handle | - Initialized system handle. |
| [in] | module_id | - Module type ID, not a module index in a voice. |
| [in] | preset_index | - Zero-based preset index. |
| [in,out] | params_buffer | - Destination pointer and capacity in bytes. |
| SceInt32 sceNgsPatchCreateRouting | ( | const SceNgsPatchSetupInfo * | patch_info, |
| SceNgsHPatch * | patch_handle | ||
| ) |
Create a route from one voice output to one voice input.
Both voices must belong to the same system. A source sub-index of -1 selects the first free patch slot. The route is initialized with zero gains. NGS rejects a route that would create a dependency cycle it cannot process.
| [in] | patch_info | - Source and destination endpoints. |
| [out] | patch_handle | - Receives the new patch handle. |
| SceInt32 sceNgsPatchGetInfo | ( | SceNgsHPatch | patch_handle, |
| SceNgsPatchRouteInfo * | route_info, | ||
| SceNgsPatchSetupInfo * | setup | ||
| ) |
Get the current source/destination channel counts and gains of a patch.
| [in] | patch_handle | - Patch handle. |
| [out] | route_info | - Receives current channel counts and matrix information. |
| [out] | setup | - Optional destination for the original patch setup. |
| SceInt32 sceNgsPatchRemoveRouting | ( | SceNgsHPatch | patch_handle | ) |
Remove a voice-to-voice patch and release its source output slot.
| [in] | patch_handle | - Patch handle to remove. |
| SceInt32 sceNgsRackGetRequiredMemorySize | ( | SceNgsHSynSystem | system_handle, |
| const SceNgsRackDescription * | rack_desc, | ||
| SceSize * | size | ||
| ) |
Compute the rack-buffer size required for a description.
| [in] | system_handle | - System that will own the rack. |
| [in] | rack_desc | - Rack description. |
| [out] | size | - Receives the required number of bytes. |
| SceInt32 sceNgsRackGetVoiceHandle | ( | SceNgsHRack | rack_handle, |
| SceUInt32 | index, | ||
| SceNgsHVoice * | voice_handle | ||
| ) |
Return one voice allocated by a rack.
| [in] | rack_handle | - Initialized rack handle. |
| [in] | index | - Zero-based voice index, less than the rack's voice count. |
| [out] | voice_handle | - Receives the voice handle. |
| SceInt32 sceNgsRackInit | ( | SceNgsHSynSystem | system_handle, |
| const SceNgsBufferInfo * | rack_buffer, | ||
| const SceNgsRackDescription * | rack_desc, | ||
| SceNgsHRack * | rack_handle | ||
| ) |
Create a rack and all of its voices in caller-owned memory.
The buffer base must be 16-byte aligned and its capacity must be at least the value returned by sceNgsRackGetRequiredMemorySize. NGS retains and modifies this memory until the rack has been released. Initialization uses one rack slot and SceNgsRackDescription::voice_count voice slots from the system limits.
| [in] | system_handle | - Owning system handle. |
| [in] | rack_buffer | - Rack buffer pointer and capacity. |
| [in] | rack_desc | - Rack configuration and allocation limits. |
| [out] | rack_handle | - Receives the rack handle. |
| SceInt32 sceNgsRackRelease | ( | SceNgsHRack | rack_handle, |
| SceNgsRackReleaseCallbackFunc | callback_func_ptr | ||
| ) |
Stop every voice, remove every connected patch, and release a rack.
With a NULL callback, the rack is released before this function returns. With a callback, a later sceNgsSystemUpdate completes the release, and the callback receives the rack and SceNgsRackDescription::user_data.
| [in] | rack_handle | - Rack to release. |
| [in] | callback_func_ptr | - Optional asynchronous completion callback. |
| SceInt32 sceNgsRackSetParamErrorCallback | ( | SceNgsHRack | rack_handle, |
| SceNgsParamsErrorCallbackFunc | callback_func_ptr | ||
| ) |
Set the parameter-range callback for one rack.
This callback takes precedence over the system-wide callback and is invoked by sceNgsSystemUpdate on the thread that calls it.
| [in] | rack_handle | - Rack handle. |
| [in] | callback_func_ptr | - Callback, or NULL to clear it. |
| SceInt32 sceNgsSystemGetRequiredMemorySize | ( | const SceNgsSystemInitParams * | synth_params, |
| SceSize * | size | ||
| ) |
Compute the system-buffer size required by an initialization configuration.
| [in] | synth_params | - System limits and processing configuration. |
| [out] | size | - Receives the required number of bytes. |
| SceInt32 sceNgsSystemInit | ( | void * | synth_sys_memory, |
| SceSize | mem_size, | ||
| const SceNgsSystemInitParams * | synth_params, | ||
| SceNgsHSynSystem * | system_handle | ||
| ) |
Initialize an NGS system in caller-owned memory.
The memory base must be 16-byte aligned and the size must be at least the result of sceNgsSystemGetRequiredMemorySize. FW 3.60 permits at most eight simultaneous systems in one process and initializes each system with SCE_NGS_SYSTEM_FLAG_CHECK_PARAMS enabled.
| [in,out] | synth_sys_memory | - Memory retained and modified by NGS until release. |
| [in] | mem_size | - Available bytes at synth_sys_memory. |
| [in] | synth_params | - System limits and processing configuration. |
| [out] | system_handle | - Receives the initialized system handle. |
| SceInt32 sceNgsSystemLock | ( | SceNgsHSynSystem | system_handle | ) |
Lock the system's internal update state.
Pair each call with a call to sceNgsSystemUnlock.
| [in] | system_handle | - System to lock. |
| SceInt32 sceNgsSystemRelease | ( | SceNgsHSynSystem | system_handle | ) |
Release a system after all of its racks have been released.
| [in] | system_handle | - System to release. |
| SceInt32 sceNgsSystemSetFlags | ( | SceNgsHSynSystem | system_handle, |
| SceUInt32 | system_flags | ||
| ) |
Replace the system flags used by subsequent parameter operations.
| [in] | system_handle | - System handle. |
| [in] | system_flags | - Bitwise OR of SceNgsSystemFlag values. |
| SceInt32 sceNgsSystemSetParamErrorCallback | ( | SceNgsHSynSystem | system_handle, |
| SceNgsParamsErrorCallbackFunc | callback_func_ptr | ||
| ) |
Set the fallback parameter-range callback for a system.
| [in] | system_handle | - System handle. |
| [in] | callback_func_ptr | - Callback, or NULL to clear it. |
| SceInt32 sceNgsSystemUnlock | ( | SceNgsHSynSystem | system_handle | ) |
Unlock a system previously locked with sceNgsSystemLock.
| [in] | system_handle | - System to unlock. |
| SceInt32 sceNgsSystemUpdate | ( | SceNgsHSynSystem | system_handle | ) |
Process one audio grain and run every queued callback.
Callback functions execute synchronously on the thread calling this function, after the kernel-side processing update has completed.
| [in] | system_handle | - System to update. |
| SceInt32 sceNgsVoiceBypassModule | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module, | ||
| SceUInt32 | bypass_flag | ||
| ) |
Set the bypass state of one module in a voice definition.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index, not a SceNgsModuleID. |
| [in] | bypass_flag | - One of SceNgsModuleBypassFlag. |
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetAtrac9Voice | ( | void | ) |
Return the complex ATRAC9 playback voice definition with four sends.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetCompressorBuss | ( | void | ) |
Return an input-mix, compressor, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetCompressorSideChainBuss | ( | void | ) |
Return a two-input side-chain compressor bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetDelayBuss | ( | void | ) |
Return an input-mix, modulated-delay, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetDistortionBuss | ( | void | ) |
Return an input-mix, distortion, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetEnvelopeBuss | ( | void | ) |
Return an input-mix, amplitude-envelope, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetEqBuss | ( | void | ) |
Return an input-mix, four-band parametric-EQ, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetMasterBuss | ( | void | ) |
Return the master bus definition that exposes PCM output to the caller.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetMixerBuss | ( | void | ) |
Return a bus definition that mixes multiple input voices.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetPauserBuss | ( | void | ) |
Return an input-mix, click-free pauser, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetPitchShiftBuss | ( | void | ) |
Return an input-mix, pitch-shift, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetReverbBuss | ( | void | ) |
Return an input-mix, environmental-reverb, and output bus definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetSasEmuVoice | ( | void | ) |
Return the libSas-emulation voice definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetScreamAtrac9Voice | ( | void | ) |
Return the Scream ATRAC9 playback voice definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetScreamVoice | ( | void | ) |
Return the Scream waveform playback voice definition.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetSimpleAtrac9Voice | ( | void | ) |
Return the basic ATRAC9 playback voice definition with two sends.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetSimpleVoice | ( | void | ) |
Return the basic PCM/VAG playback voice definition with two sends.
| const SceNgsVoiceDefinition * sceNgsVoiceDefGetTemplate1 | ( | void | ) |
Return the complex waveform playback template with signal generation and four sends.
| SceInt32 sceNgsVoiceGetInfo | ( | SceNgsHVoice | voice_handle, |
| SceNgsVoiceInfo * | info | ||
| ) |
Get one voice's current key state, module counts, and routing information.
| [in] | voice_handle | - Voice handle. |
| [out] | info | - Receives the voice snapshot. |
| SceInt32 sceNgsVoiceGetModuleBypass | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module, | ||
| SceUInt32 * | bypass_flag | ||
| ) |
Get the bypass state of one module.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index. |
| [out] | bypass_flag | - Receives one of SceNgsModuleBypassFlag. |
| SceInt32 sceNgsVoiceGetModuleType | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module, | ||
| SceNgsModuleID * | module_type | ||
| ) |
Map a zero-based module index to its module type ID.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index. |
| [out] | module_type | - Receives the SceNgsModuleID. |
| SceInt32 sceNgsVoiceGetOutputPatch | ( | SceNgsHVoice | voice_handle, |
| SceInt32 | output_index, | ||
| SceInt32 | sub_index, | ||
| SceNgsHPatch * | patch_handle | ||
| ) |
Return the patch occupying one voice output slot.
| [in] | voice_handle | - Source voice handle. |
| [in] | output_index | - Zero-based output index. |
| [in] | sub_index | - Zero-based patch slot within that output. |
| [out] | patch_handle | - Receives the patch handle, or zero when the slot is empty. |
| SceInt32 sceNgsVoiceGetParamsOutOfRange | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module, | ||
| char * | message_buffer | ||
| ) |
Format the most recent parameter-range result for one module.
The destination must provide at least 128 bytes. The resulting string is either a module mismatch/range diagnostic or No value was out of range\n.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index. |
| [out] | message_buffer | - Writable 128-byte string buffer. |
| SceInt32 sceNgsVoiceGetStateData | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module, | ||
| void * | memory, | ||
| SceSize | mem_size | ||
| ) |
Copy one module's runtime state snapshot.
The requested size must exactly match that module's state-data size; otherwise SCE_NGS_ERROR_SIZE_MISMATCH is returned.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index. |
| [out] | memory | - Destination buffer. |
| [in] | mem_size | - Exact module state-data size in bytes. |
| SceInt32 sceNgsVoiceInit | ( | SceNgsHVoice | voice_handle, |
| const SceNgsVoicePreset * | preset, | ||
| SceUInt32 | init_flags | ||
| ) |
Reinitialize a stopped voice and optionally reset patches, preset, or callbacks.
The voice must not be playing or keyed off. Bits outside SceNgsVoiceInitFlag are ignored on FW 3.60.
| [in] | voice_handle | - Voice to initialize. |
| [in] | preset | - Optional preset selected by SCE_NGS_VOICE_INIT_PRESET. |
| [in] | init_flags | - Bitwise OR of SceNgsVoiceInitFlag values. |
| SceInt32 sceNgsVoiceKeyOff | ( | SceNgsHVoice | voice_handle | ) |
Request release/envelope processing for a playing voice.
This changes the key state from playing to keyed off; processing continues until the voice finishes or is killed.
| [in] | voice_handle | - Playing voice to key off. |
| SceInt32 sceNgsVoiceKill | ( | SceNgsHVoice | voice_handle | ) |
Immediately stop a playing or keyed-off voice and return it to the stopped state.
| [in] | voice_handle | - Voice to stop. |
| SceInt32 sceNgsVoiceLockParams | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module, | ||
| SceNgsParamsID | params_interface_id, | ||
| SceNgsBufferInfo * | params_buffer | ||
| ) |
Lock and expose one module's live parameter block.
Only one lock for a module may be active at a time. The returned pointer refers directly to the rack buffer and remains valid until the rack is released, but changes are committed by sceNgsVoiceUnlockParams.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index. |
| [in] | params_interface_id | - Expected parameter-interface ID; FW 3.60 compares its low 16 bits. |
| [out] | params_buffer | - Receives the live parameter pointer and size. |
| SceInt32 sceNgsVoicePatchSetVolume | ( | SceNgsHPatch | patch_handle, |
| SceInt32 | output_channel, | ||
| SceInt32 | input_channel, | ||
| SceFloat32 | volume | ||
| ) |
Set one gain in a patch's [output][input] matrix.
| [in] | patch_handle | - Patch handle. |
| [in] | output_channel | - Output channel, less than the source channel count. |
| [in] | input_channel | - Destination input channel; must be 0 or 1. |
| [in] | volume | - Linear gain stored without clamping on FW 3.60. |
| SceInt32 sceNgsVoicePatchSetVolumes | ( | SceNgsHPatch | patch_handle, |
| SceInt32 | output_channel, | ||
| const SceFloat32 * | volumes, | ||
| SceInt32 | volume_count | ||
| ) |
Set the one or two input-channel gains for a patch output.
| [in] | patch_handle | - Patch handle. |
| [in] | output_channel | - Output row to replace. |
| [in] | volumes | - Array containing volume_count gains. |
| [in] | volume_count | - Number of gains; valid callers use 1 or 2. |
| SceInt32 sceNgsVoicePatchSetVolumesMatrix | ( | SceNgsHPatch | patch_handle, |
| const SceNgsVolumeMatrix * | matrix | ||
| ) |
Replace a patch's complete 2x2 output-to-input gain matrix.
A mono source uses only the first row; a stereo source uses all four values.
| [in] | patch_handle | - Patch handle. |
| [in] | matrix | - Replacement gain matrix. |
| SceInt32 sceNgsVoicePause | ( | SceNgsHVoice | voice_handle | ) |
Pause voice processing without changing whether the voice is playing or keyed off.
| [in] | voice_handle | - Voice to pause. |
| SceInt32 sceNgsVoicePlay | ( | SceNgsHVoice | voice_handle | ) |
Start a stopped voice.
A voice must be initialized before it can be played.
| [in] | voice_handle | - Voice to start. |
| SceInt32 sceNgsVoiceResume | ( | SceNgsHVoice | voice_handle | ) |
Resume a paused voice without changing its play/key-off state.
| [in] | voice_handle | - Voice to resume. |
| SceInt32 sceNgsVoiceSetFinishedCallback | ( | SceNgsHVoice | voice_handle, |
| SceNgsCallbackFunc | callback_func_ptr, | ||
| void * | user_data | ||
| ) |
Set the callback queued when a voice reaches its finished state.
The callback runs from sceNgsSystemUpdate and receives user_data through SceNgsCallbackInfo::user_data.
| [in] | voice_handle | - Voice handle. |
| [in] | callback_func_ptr | - Callback, or NULL to clear it. |
| [in] | user_data | - Opaque value returned to the callback. |
| SceInt32 sceNgsVoiceSetModuleCallback | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module, | ||
| SceNgsModuleCallbackFunc | callback_func_ptr, | ||
| void * | user_data | ||
| ) |
Set the callback for events from the module at a given index.
The callback runs from sceNgsSystemUpdate. Its reason and data fields are defined by the selected module type.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index. |
| [in] | callback_func_ptr | - Callback, or NULL to clear it. |
| [in] | user_data | - Opaque value returned to the callback. |
| SceInt32 sceNgsVoiceSetParamsBlock | ( | SceNgsHVoice | voice_handle, |
| const SceNgsModuleParamHeader * | param_data, | ||
| SceSize | size, | ||
| SceInt32 * | error_count | ||
| ) |
Apply a packed sequence of module parameter records.
Valid records are applied even when another record fails. If non-NULL, error_count receives the number of rejected records.
| [in] | voice_handle | - Voice handle. |
| [in] | param_data | - First packed record header. Each header is followed by a SceNgsParamsDescriptor and its module-specific data. |
| [in] | size | - Total byte size of the record sequence. |
| [out] | error_count | - Optional rejected-record count. |
| SceInt32 sceNgsVoiceSetPreset | ( | SceNgsHVoice | voice_handle, |
| const SceNgsVoicePreset * | voice_preset | ||
| ) |
Restore module defaults, then apply an optional voice preset.
A NULL preset restores the definition's module defaults and clears the preset bypass list. The voice does not have to be stopped, but locked parameter interfaces cause SCE_NGS_ERROR_RESOURCE_LOCKED.
| [in] | voice_handle | - Voice handle. |
| [in] | voice_preset | - Preset to apply, or NULL for module defaults. |
| SceInt32 sceNgsVoiceUnlockParams | ( | SceNgsHVoice | voice_handle, |
| SceUInt32 | module | ||
| ) |
Commit and unlock a module parameter block returned by sceNgsVoiceLockParams.
When SCE_NGS_SYSTEM_FLAG_CHECK_PARAMS is set, invalid values are rejected and the module is not marked as changed for processing.
| [in] | voice_handle | - Voice handle. |
| [in] | module | - Zero-based module index previously locked. |
| SceInt32 sceSulphaNgsGetDefaultConfig | ( | SceSulphaNgsConfig * | config | ) |
Fill a Sulpha NGS configuration with the FW 3.60 defaults.
| [out] | config | - Receives limits of 1024 named sample-memory ranges and a 4096-byte API-call trace buffer. |
| SceInt32 sceSulphaNgsGetNeededMemory | ( | const SceSulphaNgsConfig * | config, |
| SceSize * | size_in_bytes | ||
| ) |
Compute all memory needed by the Sulpha NGS agent and its fixed NGS pools.
| [in] | config | - Sulpha NGS capacities. |
| [out] | size_in_bytes | - Receives the required byte count. |
| SceInt32 sceSulphaNgsInit | ( | const SceSulphaNgsConfig * | config, |
| void * | buffer, | ||
| SceSize | size_in_bytes | ||
| ) |
Initialize Sulpha NGS tracing for the calling process.
All threads in the process share this tracing agent. The supplied memory must remain valid until sceSulphaNgsShutdown. Use sceSulphaNgsGetNeededMemory rather than relying on the implementation's check, which accepts a smaller minimum size.
| [in] | config | - Sulpha NGS capacities. |
| [in,out] | buffer | - Caller-owned tracing memory. |
| [in] | size_in_bytes | - Available bytes in buffer. |
| SceInt32 sceSulphaNgsSetRackName | ( | SceNgsHRack | rack_handle, |
| const char * | name | ||
| ) |
Assign a diagnostic Sulpha name to an initialized rack.
| [in] | rack_handle | - Rack handle. |
| [in] | name | - Diagnostic name forwarded to Sulpha. |
Associate a diagnostic name with a sample-memory range.
| [in] | location | - Non-NULL sample-data address. |
| [in] | length | - Nonzero sample-data size in bytes. |
| [in] | name | - Diagnostic name forwarded to Sulpha. |
| SceInt32 sceSulphaNgsSetSynthName | ( | SceNgsHSynSystem | synth_handle, |
| const char * | name | ||
| ) |
Assign a diagnostic Sulpha name to an initialized NGS system.
| [in] | synth_handle | - System handle. |
| [in] | name | - Diagnostic name forwarded to Sulpha. |
| SceInt32 sceSulphaNgsSetVoiceName | ( | SceNgsHVoice | voice_handle, |
| const char * | name | ||
| ) |
Assign a diagnostic Sulpha name to an initialized voice.
| [in] | voice_handle | - Voice handle. |
| [in] | name | - Diagnostic name forwarded to Sulpha. |
| SceInt32 sceSulphaNgsShutdown | ( | void | ) |
Unregister the Sulpha NGS agent shared by all threads in the process and release its registrations.
| SceInt32 sceSulphaNgsTrace | ( | const char * | message | ) |
Emit message as a Sulpha trace event in the Ngs category.
| [in] | message | - Literal message; it is passed through a s format. |
| void* SceNgsBufferInfo::data |
Buffer base address.
| SceSize SceNgsBufferInfo::size |
Buffer size in bytes.
| SceInt32 SceNgsSystemInitParams::max_racks |
Maximum number of racks; must be from 1 through 64.
| SceInt32 SceNgsSystemInitParams::max_voices |
Maximum number of voices; must be from 1 through 256.
| SceInt32 SceNgsSystemInitParams::granularity |
Number of samples processed per update; a multiple of 64 from 64 through 512.
| SceInt32 SceNgsSystemInitParams::sample_rate |
System sample rate; must be 48000 on FW 3.60.
| SceInt32 SceNgsSystemInitParams::reserved |
Must be at least zero; otherwise ignored on FW 3.60.
| const SceNgsVoiceDefinition* SceNgsRackDescription::voice_definition |
Immutable definition returned by a sceNgsVoiceDefGet* function.
| SceInt32 SceNgsRackDescription::voice_count |
Number of voices to allocate; must be greater than zero.
| SceInt32 SceNgsRackDescription::channels_per_voice |
Audio channels per voice; must be 1 or 2.
| SceInt32 SceNgsRackDescription::max_patches_per_input |
Patch slots for each dynamic input. Input/mixer racks require a nonzero value.
| SceInt32 SceNgsRackDescription::patches_per_output |
Patch slots allocated for each voice output.
| void* SceNgsRackDescription::user_data |
Value delivered to the callback passed to sceNgsRackRelease.
| SceNgsHVoice SceNgsPatchSetupInfo::source_voice |
Source voice.
| SceInt32 SceNgsPatchSetupInfo::source_output_index |
Source voice output index.
| SceInt32 SceNgsPatchSetupInfo::source_output_sub_index |
Source output patch slot, or -1 to use the first free slot.
| SceNgsHVoice SceNgsPatchSetupInfo::destination_voice |
Destination voice; it must belong to the same system as the source.
| SceInt32 SceNgsPatchSetupInfo::destination_input_index |
Destination voice input index.
| SceInt32 SceNgsVoicePreset::name_offset |
Offset of the preset name. Ignored when applying the preset on FW 3.60.
| SceUInt32 SceNgsVoicePreset::name_length |
Preset-name length. Ignored when applying the preset on FW 3.60.
| SceInt32 SceNgsVoicePreset::preset_data_offset |
Offset of the variable-length module parameter records, or zero.
| SceUInt32 SceNgsVoicePreset::preset_data_size |
Size of the module parameter records in bytes.
| SceInt32 SceNgsVoicePreset::bypass_flags_offset |
Offset of an array of module indices to bypass, or zero.
| SceUInt32 SceNgsVoicePreset::bypass_flags_count |
Number of module indices in the bypass array.
| SceNgsHVoice SceNgsCallbackInfo::voice_handle |
Voice associated with the event, or zero for a rack-release event.
| SceNgsHRack SceNgsCallbackInfo::rack_handle |
Rack associated with the event.
| SceNgsModuleID SceNgsCallbackInfo::module_id |
Module type associated with a module or parameter event.
| SceUInt32 SceNgsCallbackInfo::callback_reason |
First module-defined reason value.
| SceUInt32 SceNgsCallbackInfo::callback_reason2 |
Second module-defined reason value.
| void* SceNgsCallbackInfo::callback_ptr |
Optional module-defined pointer; valid for the duration of the callback.
| void* SceNgsCallbackInfo::user_data |
User value registered with the callback or rack description.
| SceNgsParamsID SceNgsParamsDescriptor::id |
| SceSize SceNgsParamsDescriptor::size |
Size beginning at id, including this field and the module-specific data.
| SceInt32 SceNgsAT9SkipBufferInfo::start_byte_offset |
Byte offset of the first required ATRAC9 packet.
| SceInt32 SceNgsAT9SkipBufferInfo::num_bytes |
Number of bytes to make available to the decoder.
| SceInt16 SceNgsAT9SkipBufferInfo::start_skip |
Samples to discard at the start of the first decoded packet.
| SceInt16 SceNgsAT9SkipBufferInfo::end_skip |
Samples to discard at the end of the last decoded packet.
| SceInt32 SceNgsAT9SkipBufferInfo::is_super_packet |
1 for the four-frame packet layout, otherwise 0.
| SceInt32 SceNgsModuleParamHeader::module_index |
Zero-based index in the voice definition.
| SceInt32 SceNgsModuleParamHeader::channel_index |
Channel to update, or -1 to update every channel represented by the following parameter descriptor.
| SceFloat32 SceNgsVolumeMatrix::matrix[SCE_NGS_MAX_SYSTEM_CHANNELS][SCE_NGS_MAX_SYSTEM_CHANNELS] |
| SceInt32 SceNgsPatchRouteInfo::output_channels |
Source-rack channel count.
| SceInt32 SceNgsPatchRouteInfo::input_channels |
Destination-rack channel count.
| SceNgsVolumeMatrix SceNgsPatchRouteInfo::volume_matrix |
Current output-to-input gain matrix.
| SceUInt32 SceNgsVoiceInfo::voice_state |
Bitwise OR of SceNgsVoiceState values.
| SceUInt32 SceNgsVoiceInfo::num_modules |
Number of modules in the voice definition.
| SceUInt32 SceNgsVoiceInfo::num_inputs |
Number of dynamic input modules in the voice definition.
| SceUInt32 SceNgsVoiceInfo::num_outputs |
Number of outputs exposed by the voice definition.
| SceUInt32 SceNgsVoiceInfo::num_patches_per_output |
Patch slots allocated for each output.
| SceUInt32 SceNgsVoiceInfo::update_passed |
Number of processing updates completed for this voice since its most recent initialization or play.
| SceUInt32 SceSulphaNgsConfig::max_named_samples |
Maximum sample-memory ranges that can be named; the FW 3.60 default is 1024.
| SceUInt32 SceSulphaNgsConfig::api_trace_buffer_size |
NGS API-call trace buffer size in bytes; only complete 16-byte records are used. The FW 3.60 default is 4096.