Conectar :       Password :       Recuerdame

Forum: Virtual DJ Plugins - Topic: Hecules RMX Mapper

Post here comments on the Virtual DJ Plugins (Audio effects, Video effects, Video transitions, Devices mapper, Tools, ...).
We remind that plugins are downloadable by registered PRO users only.
VirtualDJ Foros
Virtual DJ Plugins
Hecules RMX Mapper


Autor - Tema: Hecules RMX Mapper -

looshus

Limited edition user
Mensajes Fri 04 Jul 08 @ 4:57 am
Hi all, I've started writing my first plugin, to customise some buttons on the RMX. What I want to do is make the effect buttons have 'momentary' behaviour, and make the track search buttons skip 32 beats instead of 16. I've made a start but need some feedback off someone to check I'm going in the right direction.

Quote :

#define WIN32_LEAN_AND_MEAN
#define _CRT_SECURE_NO_DEPRECATE

#include <windows.h>
#include "vdjPlugin.h"
#include "vdjDevice.h"
#include "DJCMapper.h"


//---------------------------------------------------------------------------
// Class definition
//---------------------------------------------------------------------------
class LOOSHYBRO : public IVdjPluginDevice
{
public:
HRESULT __stdcall OnLoad();
HRESULT __stdcall OnGetPluginInfo(TVdjPluginInfo *infos) ;
HRESULT __stdcall OnButton(int chan,int button,int down);
HRESULT __stdcall OnSlider(int chan,int slider,int absvalue,int relvalue);
HRESULT __stdcall OnTimer();
HRESULT __stdcall GetDeviceType(int *type);


int skip_32;
//int effect_mom;

private:
};
//---------------------------------------------------------------------------
// Initialisation
//---------------------------------------------------------------------------
HRESULT __stdcall DllGetClassObject(const GUID &rclsid,const GUID &riid,void** ppObject)
{
// You don't need to change anything here
// Just leave it like that
if(memcmp(&rclsid,&CLSID_VdjPlugin,sizeof(GUID)) != 0) return CLASS_E_CLASSNOTAVAILABLE;
if(memcmp(&riid,&IID_IVdjPluginDevice,sizeof(GUID))!=0) return CLASS_E_CLASSNOTAVAILABLE;
*ppObject=new LOOSHYBRO();
return NO_ERROR;
}
//---------------------------------------------------------------------------



char _strparam[128];
inline char *strparam(char* s, int v) {wsprintf(_strparam,s,v);return _strparam;};


HRESULT __stdcall LOOSHYBRO::OnLoad()
{
DeclareParameter(&skip_32,VDJPARAM_SWITCH,1,"Skip 32 beats with track search buttons",1);
//DeclareParameter(&effect_mom,VDJPARAM_SWITCH,2,"Make effect buttons momentarily active",1);
return S_OK;
}

HRESULT __stdcall LOOSHYBRO::OnGetPluginInfo(TVdjPluginInfo *infos)
{
infos->PluginName="RMX Looshus Skip 32";
infos->Author="Luke Davies";
infos->Description="Looshus RMX extentions";
// Replace the files "BITMAP.BMP" and "SELECTED.BMP" in your directory with your own.
infos->Bitmap=LoadBitmap(hInstance,MAKEINTRESOURCE(100));
infos->Flag=0;
return S_OK;
}



HRESULT __stdcall LOOSHYBRO::OnButton(int chan,int button,int down)
{
if (button=DJC_PREV_TRACK_A)
{
SendCommand(strparam("skip_beat",-32),0);
return S_OK;
}

return E_NOTIMPL;
}


HRESULT __stdcall LOOSHYBRO::OnSlider(int chan,int slider,int absvalue,int relvalue)
{
return E_NOTIMPL;
}



HRESULT __stdcall LOOSHYBRO::OnTimer()
{
return E_NOTIMPL;
}

HRESULT __stdcall LOOSHYBRO::GetDeviceType(int *type)
{
* type=PLUGINDEVICE_DJCONSOLE;
return S_OK;
}


I've only tried the one button so far, is my
Quote :

if (button=DJC_PREV_TRACK_A)
{
SendCommand(strparam("skip_beat",-32),0);
return S_OK;
}

bit OK?

Where do I go from here? do I need to compile the dll, call it DJC.dll and put it in the control device folder?

Any help greatly appreciated, Loosh.

djcel

Senior Team
Mensajes Sat 05 Jul 08 @ 6:54 am
You need the new "DJCMapper.h" file in order to write a mapper for the RMX

The dll has to be named : rmx.dll

looshus

Limited edition user
Mensajes Sun 06 Jul 08 @ 6:51 am
Thanks for getting back to me, where can I find the new DJCMapper header file? The one available on the developer page seems to be for the mk I and II controllers and not for the RMX.

djcel

Senior Team
Mensajes Sun 06 Jul 08 @ 5:07 pm
Currently, I'm the only one to have it and it's not yet online.

looshus

Limited edition user
Mensajes Sun 06 Jul 08 @ 5:36 pm
No chance I could get a sneak preview? ;->

What sorta timescale we lookin on????

Moramax must have it aswell?



Site map
(C)opyright Atomix Productions 2008

Programas
Hardware
VirtualDJ Pro
VirtualVinyl
Numark CUE
AtomixMP3
VDJ HomeEdition
DJC Edition
eJay DJMixStation
DJ-Box
Características
Pantallas
Versión de prueba
Plugins
Actualizaciones de Software
Material para la prensa
SDK para Desarrolladores
CD de Código de Tiempo
Skins (Pieles)
Efectos de Sonido
Efectos de Video
Samples
Idiomas
Grafx
Herramientas y Controladores
Foros
Usuarios en red
Wiki
Radio
Atomix Productions
DJs VIP
Condiciones de Uso
Haga una Pregunta
Vea sus tickets
Wiki