2024-04-14 16:17:19 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* lv2_utils.h */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* This file is part of Drummer. */
|
|
|
|
/* */
|
|
|
|
/* Drummer is free software: you can redistribute it and/or modify it */
|
|
|
|
/* under the terms of the GNU General Public License as published by */
|
|
|
|
/* the Free Software Foundation, either version 3 of the License, or */
|
|
|
|
/* (at your option) any later version. */
|
|
|
|
/* */
|
|
|
|
/* Drummer is distributed in the hope that it will be useful, */
|
|
|
|
/* but WITHOUT ANY WARRANTY; without even the implied warranty of */
|
|
|
|
/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the */
|
|
|
|
/* GNU General Public License for more details. */
|
|
|
|
/* */
|
|
|
|
/* You should have received a copy of the GNU General Public License */
|
|
|
|
/* along with Drummer. If not, see <https://www.gnu.org/licenses/>. */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
|
|
|
|
|
2024-04-14 16:17:19 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* Includes */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
#ifndef _LV2_UTILS_H_
|
|
|
|
#define _LV2_UTILS_H_
|
|
|
|
|
|
|
|
#include "lv2/atom/atom.h"
|
|
|
|
#include "lv2/atom/forge.h"
|
|
|
|
#include "lv2/atom/util.h"
|
|
|
|
#include "lv2/core/lv2.h"
|
|
|
|
#include "lv2/core/lv2_util.h"
|
|
|
|
#include "lv2/log/log.h"
|
|
|
|
#include "lv2/log/logger.h"
|
|
|
|
#include "lv2/midi/midi.h"
|
|
|
|
#include "lv2/urid/urid.h"
|
|
|
|
#include "lv2/state/state.h"
|
|
|
|
|
|
|
|
//#include "lv2/lv2plug.in/ns/ext/atom/forge.h"
|
|
|
|
// util includes atom.h
|
|
|
|
//#include "lv2/lv2plug.in/ns/ext/atom/util.h"
|
|
|
|
//#include "lv2/lv2plug.in/ns/lv2core/lv2.h"
|
|
|
|
//#include "lv2/lv2plug.in/ns/ext/urid/urid.h"
|
|
|
|
//#include "lv2/lv2plug.in/ns/ext/state/state.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* Global definitions */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
typedef struct DRT_Drummer_URIS
|
|
|
|
{
|
|
|
|
LV2_URID Atom_Object;
|
|
|
|
|
|
|
|
LV2_URID String_URId;
|
|
|
|
LV2_URID Bool_URId;
|
|
|
|
LV2_URID Int_URId;
|
|
|
|
LV2_URID Long_URId;
|
|
|
|
LV2_URID Tuple_URId;
|
|
|
|
|
|
|
|
LV2_URID Midi_Event;
|
|
|
|
|
|
|
|
LV2_URID Atom_EventTransfer;
|
|
|
|
|
|
|
|
LV2_URID UI_Msg;
|
|
|
|
|
|
|
|
LV2_URID UI_Enable;
|
|
|
|
LV2_URID UI_Disable;
|
|
|
|
|
|
|
|
LV2_URID Kit_Update_Request;
|
|
|
|
LV2_URID Kit_Update_Reply;
|
|
|
|
|
|
|
|
LV2_URID Velocity_Ignore_Flag_Toggle;
|
|
|
|
LV2_URID Note_Off_Ignore_Flag_Toggle;
|
|
|
|
|
|
|
|
|
|
|
|
// LV2_URID kit_path;
|
|
|
|
// LV2_URID get_state;
|
|
|
|
// LV2_URID midi_info;
|
|
|
|
// LV2_URID sample_trigger;
|
|
|
|
// LV2_URID channel_id;
|
|
|
|
// LV2_URID velocity_toggle;
|
|
|
|
// LV2_URID note_off_toggle;
|
|
|
|
// LV2_URID zero_position;
|
|
|
|
// LV2_URID sample_add;
|
|
|
|
// LV2_URID sample_remove;
|
|
|
|
} DRT_Drummer_URIS;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-21 20:16:18 +02:00
|
|
|
/* DRD DATA & API definition */
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
# ifdef _LV2_UTILS_C_
|
|
|
|
# define DRD_LVU_DATA
|
|
|
|
# define DRD_LVU_API
|
|
|
|
# else
|
|
|
|
# define DRD_LVU_DATA extern
|
|
|
|
# define DRD_LVU_API extern
|
|
|
|
# endif
|
|
|
|
|
|
|
|
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-21 20:16:18 +02:00
|
|
|
/* Public Data */
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-21 20:16:18 +02:00
|
|
|
/* DRT_Base */
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* Public Prototypes */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-14 16:17:19 +02:00
|
|
|
/* DR_LV2_Map_URIS */
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
DRD_LVU_API void DR_LV2_Map_URIS( LV2_URID_Map *, DRT_Drummer_URIS *);
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
# ifdef _LV2_UTILS_C_
|
|
|
|
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-21 20:16:18 +02:00
|
|
|
/* Private Definitions */
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
#define DRD_MODULE_NAME "lvu"
|
|
|
|
#define LGD_MODULE_NAME "lvu"
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* Private Prototypes */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-21 20:16:18 +02:00
|
|
|
/* DR_Log */
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
//DRT_Status DR_LV2_Log_Write( DRT_Log_Type_Id, char *, va_list);
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-04-10 23:53:45 +02:00
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* DR_LV2_Map_URIS */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
//void DR_LV2_Map_URIS( LV2_URID_Map *, DRT_Drummer_URIS *);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
/* Post Private Definitions */
|
|
|
|
/*----------------------------------------------------------------------------*/
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
# else // ifdef _LV2_UTILS_C_
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-04-21 20:16:18 +02:00
|
|
|
# endif // ifdef _LV2_UTILS_C_
|
2024-04-10 23:53:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
#endif // ifndef _LV2_UTILS_H_
|
|
|
|
|