SOUND4 IMPACT FM.CL Library [2.0.3]
Loading...
Searching...
No Matches
Process creation/destruction

Create and destroy a process instance. More...

Classes

struct  impactfm_CInstance
struct  impactfm_CParameters

Functions

struct impactfm_CParameters * impactfm_NewParameters ()
void impactfm_FreeParameters (struct impactfm_CParameters *params)
void impactfm_SetParameter (struct impactfm_CParameters *params, const char *name, const char *value)
const char * impactfm_GetParameter (struct impactfm_CParameters *params, const char *name)
void impactfm_FreeParameterValue (const char *value)
struct impactfm_CInstance * impactfm_InitProcess (const char *LoginKey, const char *RadioName, const char *Access_Key_ID, const char *Access_Key_Secret, const char *save_path)
struct impactfm_CInstance * impactfm_InitProcess2 (const char *LoginKey, const char *RadioName, const char *Access_Key_ID, const char *Access_Key_Secret, const char *save_path, const struct impactfm_CParameters *parameters)
struct impactfm_CInstance * impactfm_InitProcess3 (const char *LoginKey, const char *RadioName, const char *Access_Key_ID, const char *Access_Key_Secret, const char *save_path, const struct impactfm_CParameters *parameters, unsigned int frames_per_chunk)
unsigned int impactfm_GetProcessChunkFrames (struct impactfm_CInstance *instance)
int impactfm_TerminateProcess (struct impactfm_CInstance *instance)
void impactfm_ExitProcess (struct impactfm_CInstance *instance)

Detailed Description

Create and destroy a process instance, and retrieve some general information about the process.

Function Documentation

◆ impactfm_ExitProcess()

void impactfm_ExitProcess ( struct impactfm_CInstance * instance)

Quit and destroy the instance

Parameters
instancethe instance to destroy

◆ impactfm_FreeParameters()

void impactfm_FreeParameters ( struct impactfm_CParameters * params)

Free the parameters created with impactfm_NewParameters.

◆ impactfm_FreeParameterValue()

void impactfm_FreeParameterValue ( const char * value)

Free a parameter value returned by impactfm_GetParameter

Parameters
valuethe returned value

◆ impactfm_GetParameter()

const char * impactfm_GetParameter ( struct impactfm_CParameters * params,
const char * name )

Get current parameter value.

Returned value must be freed with impactfm_FreeParameterValue

◆ impactfm_GetProcessChunkFrames()

unsigned int impactfm_GetProcessChunkFrames ( struct impactfm_CInstance * instance)

Get the number of audio frames in each chunk of processing.

The value reflects the frames_per_chunk parameter passed to impactfm_InitProcess3

Parameters
instancethe instance to destroy
Returns
the number of audio frames in each chunk of processing
Note
A Frame is a set of impactfm_GetChannelCount samples

◆ impactfm_InitProcess()

struct impactfm_CInstance * impactfm_InitProcess ( const char * LoginKey,
const char * RadioName,
const char * Access_Key_ID,
const char * Access_Key_Secret,
const char * save_path )

Create a process instance with default parameters (from env)

Same as impactfm_InitProcess2, but with default parameters (from env)

Deprecated
Use impactfm_InitProcess3

◆ impactfm_InitProcess2()

struct impactfm_CInstance * impactfm_InitProcess2 ( const char * LoginKey,
const char * RadioName,
const char * Access_Key_ID,
const char * Access_Key_Secret,
const char * save_path,
const struct impactfm_CParameters * parameters )

Create a process instance with default frames_per_chunk (64)

Same as impactfm_InitProcess3, but with default frames_per_chunk

Deprecated
Use impactfm_InitProcess3

◆ impactfm_InitProcess3()

struct impactfm_CInstance * impactfm_InitProcess3 ( const char * LoginKey,
const char * RadioName,
const char * Access_Key_ID,
const char * Access_Key_Secret,
const char * save_path,
const struct impactfm_CParameters * parameters,
unsigned int frames_per_chunk )

Create a process instance

The output will have to be freed with impactfm_ExitProcess

Attention
The save_path must be an existing folder with R/W access, or be NULL (then it uses volatile memory storage)

If the save_path is NULL or the folder is empty, a default configuration with a default preset will be loaded, unless using Custom preset managagement.

If used in a container, we recommend to put a volume for this path, so it will survive updates.

License access
The licenses are retrieved via Internet and access some servers. You may use an alternate server by changing LICENSE_SERVER in the parameters.

See also Environment variables and parameters

Parameters
LoginKeySOUND4 Login key (was User ID)
RadioNameSOUND4 RadioName
Access_Key_IDSOUND4 AWS access ID
Access_Key_SecretSOUND4 AWS access Secret
save_pathPath where we can load/save the configuration. If NULL, memory storage will be used.
parametersParameters
frames_per_chunkThe number of audio frames in each chunk of processing. Must be in the list returned by impactfm_GetPossibleChunkSizeInFrames
Returns
A new process instance

◆ impactfm_NewParameters()

struct impactfm_CParameters * impactfm_NewParameters ( )

Create parameters to use with impactfm_InitProcess2.

The output will have to be freed with impactfm_FreeParameters

The default values are taken from environment (for compatibility).

◆ impactfm_SetParameter()

void impactfm_SetParameter ( struct impactfm_CParameters * params,
const char * name,
const char * value )

Set a new parameter.

Some values are in taken from env, so see Environment variables and parameters for usable variables

See also Custom preset managagement

◆ impactfm_TerminateProcess()

int impactfm_TerminateProcess ( struct impactfm_CInstance * instance)

Terminate the processing

This is useful only with file processing, to get the final status. For some plugins, this is mandatory

Parameters
instancethe instance to terminate
Returns
0 is success, <0 if error, >0 if some status