DISTRHO Plugin Framework
Public Member Functions | Public Attributes | List of all members
Parameter Struct Reference

#include <DistrhoDetails.hpp>

Public Member Functions

 Parameter () noexcept
 
 Parameter (uint32_t h, const char *n, const char *s, const char *u, float def, float min, float max) noexcept
 
void initDesignation (ParameterDesignation d) noexcept
 

Public Attributes

uint32_t hints
 
String name
 
String shortName
 
String symbol
 
String unit
 
String description
 
ParameterRanges ranges
 
ParameterEnumerationValues enumValues
 
ParameterDesignation designation
 
uint8_t midiCC
 
uint32_t groupId
 

Detailed Description

Parameter.

Constructor & Destructor Documentation

◆ Parameter() [1/2]

Parameter::Parameter ( )
inlinenoexcept

Default constructor for a null parameter.

◆ Parameter() [2/2]

Parameter::Parameter ( uint32_t  h,
const char *  n,
const char *  s,
const char *  u,
float  def,
float  min,
float  max 
)
inlinenoexcept

Constructor using custom values.

Member Function Documentation

◆ initDesignation()

void Parameter::initDesignation ( ParameterDesignation  d)
inlinenoexcept

Initialize a parameter for a specific designation.

Member Data Documentation

◆ hints

uint32_t Parameter::hints

Hints describing this parameter.

See also
Parameter Hints

◆ name

String Parameter::name

The name of this parameter.
A parameter name can contain any character, but hosts might have a hard time with non-ascii ones.
The name doesn't have to be unique within a plugin instance, but it's recommended.

◆ shortName

String Parameter::shortName

The short name of this parameter.
Used when displaying the parameter name in a very limited space.

Note
This value is optional, the full name is used when the short one is missing.

◆ symbol

String Parameter::symbol

The symbol of this parameter.
A parameter symbol is a short restricted name used as a machine and human readable identifier.
The first character must be one of _, a-z or A-Z and subsequent characters can be from _, a-z, A-Z and 0-9.

Note
Parameter symbols MUST be unique within a plugin instance.

◆ unit

String Parameter::unit

The unit of this parameter.
This means something like "dB", "kHz" and "ms".
Can be left blank if a unit does not apply to this parameter.

◆ description

String Parameter::description

An extensive description/comment about the parameter.

Note
This value is optional and only used for LV2.

◆ ranges

ParameterRanges Parameter::ranges

Ranges of this parameter.
The ranges describe the default, minimum and maximum values.

◆ enumValues

ParameterEnumerationValues Parameter::enumValues

Enumeration details.
Can be used to give meaning to parameter values, working as an enumeration.

◆ designation

ParameterDesignation Parameter::designation

Designation for this parameter.

◆ midiCC

uint8_t Parameter::midiCC

MIDI CC to use by default on this parameter.
A value of 0 or 32 (bank change) is considered invalid.
Must also be less or equal to 120.

Note
This value is only a hint! Hosts might map it automatically or completely ignore it.

◆ groupId

uint32_t Parameter::groupId

The group id that this parameter belongs to. No group is assigned by default.

You can use a group from PredefinedPortGroups or roll your own.
When rolling your own port groups, you MUST start their group ids from 0 and they MUST be sequential.

See also
PortGroup, Plugin::initPortGroup

The documentation for this struct was generated from the following file: