Go Back   Cockos Incorporated Forums > REAPER Forums > ReaScript, JSFX, REAPER Plug-in Extensions, Developer Forum

Reply
 
Thread Tools Display Modes
Old 11-23-2020, 04:04 AM   #1
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default new power programming language for easy build vst plugins

that you can find here
https://github.com/VisualCodeBase/CodeBase
it's compatible with cockos eel
in other words you can find there megababy and some more examples in VST!

to build them you need to download TDM-GCC and set its path in the enviroment
https://github.com/jmeubank/tdm-gcc/releases

Last edited by whats_up; 12-12-2022 at 04:16 PM.
whats_up is online now   Reply With Quote
Old 11-23-2020, 10:11 AM   #2
TonE
Human being with feelings
 
Join Date: Feb 2009
Location: Reaper HAS send control via midi !!!
Posts: 4,031
Default

Sounds interesting, are you the developer? Which jsfx did you test? Any example versions as vst? If this would work with any jsfx, that would be cool, and you could tell saike he can stop his vst development of Yutani.

And thanks for sharing!
TonE is offline   Reply With Quote
Old 11-24-2020, 03:42 PM   #3
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by TonE View Post
Sounds interesting, are you the developer? Which jsfx did you test? Any example versions as vst? If this would work with any jsfx, that would be cool, and you could tell saike he can stop his vst development of Yutani.

And thanks for sharing!
in the package on github there are 3 projects under source/examples

the eel namespace is uncomplete yet.
whats_up is online now   Reply With Quote
Old 11-28-2020, 03:56 PM   #4
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default megababy vst in action

small screen recording to show
that everything works as expected including resizing and switching between plugins

https://stash.reaper.fm/v/40687/megababy.gif

the blank area on the top is for future standard controls.

i updated github https://github.com/VisualCodeBase/CodeBase with the fixes
whats_up is online now   Reply With Quote
Old 03-05-2021, 05:40 AM   #5
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default major update

there is a major update on github
https://github.com/VisualCodeBase/CodeBase

one of the new features is Full Psedu Namespace support.

there are some screen captures in the stash:
https://stash.reaper.fm/v/41507/midi.png
https://stash.reaper.fm/v/41508/synthGUI.png
https://stash.reaper.fm/v/41509/Synth.png


https://stash.reaper.fm/v/40687/megababy.gif

the graphics support missing few functions.

the example provided is TALE monopoly_synth
it compiled perfectly good (with all the imported libs).

it for some reason doesn't work good, midi works, audio not.

it'll be fixed in the future.

note: i'm taking a break from this stuff for about 1-2 months.

enjoy.

Last edited by whats_up; 03-07-2021 at 04:32 AM.
whats_up is online now   Reply With Quote
Old 03-05-2021, 05:33 PM   #6
gxray
Human being with feelings
 
Join Date: Dec 2020
Location: Miami, FL USA
Posts: 396
Default

Wow. Let me see if I can unpack and understand all of what I am seeing here.

So you have several things it looks like.

One is this "CodeBase" language + compiler, which can compile and facilitate interop/FFI between multiple languages, to multiple different targets?



Code:
CodeBase
----------
Powerfull feature rich optimized, multi in multi out, modern compiler.
understand by default:

most of ansi C language,
different dialects of basic (especially vsBasic 6, powerbasic, freebasic),
some of pascal,
assembley.

with directives, can parse language specific of the above.

by default its output is C with minimal use of C++ features, so it needs C++ compiler.
in the future we hope to produce more output languages (mainly java and pascal).

G++ is the default backend compiler.
its goal is to implement large projects fast and easy, yet produce well optimized code.

comes with some libraries that includes hundreds of usefull functions/classes/gui controls.

current state quite stable as it the only compiler we use to compile all our many sources, so it is heavly tested all the time.
Another is this language called "Neutron", which is:
  • Fully backwards-compatible with Cockos EEL files/syntax
  • Can output either C++ or CodeBase source code
  • Supports a second alternative syntax for Eel, which looks more readable and is similar to Basic/Delphi?
  • Allows to tweak Eel scripts with special comments to call external functions or native libraries

Code:
if you want to write a plug with sources that eel doesn't support,
for example  types, external functions, windows API, ...,
you can enter it inside special comments like this:

function cc() {
  /*## myExternalFunction();
  ...
  return 0.5
  */
}
Code:
functions can be written also like this (no brackets, no semicolons, no ugly signs):

long sub mySub(int a, long b, double c)
  a := myCall(c)
  b = a+myCall(c)
end
And the last is "PVF" which is a VST compiler that's compatible with your Neutron language (and hence, Eel) and can convert it to VST C++.

With just one line, seems you can convert JSFX to C++ VST?



This seems pretty insane!!
__________________
Seasoned codemonkey
Dunno a thing about making music (here to learn!)
gxray is offline   Reply With Quote
Old 03-09-2021, 05:05 AM   #7
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by gxray View Post
Wow.
This seems pretty insane!!
it seems you got it perfectly right.
thank you very much for detailed explanation.

btw the single (@include) line is not required. original source can be built directly from the command line.

we just sorted it this way for better use.
whats_up is online now   Reply With Quote
Old 03-09-2021, 05:38 AM   #8
vitalker
Human being with feelings
 
vitalker's Avatar
 
Join Date: Dec 2012
Posts: 13,333
Default

Wow, this is amazing!
vitalker is offline   Reply With Quote
Old 03-22-2021, 03:35 PM   #9
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default important update

sorry for the little buggy previous release.
new update on github.
https://github.com/VisualCodeBase/CodeBase
Attached Images
File Type: png Untitled.png (30.9 KB, 219 views)
whats_up is online now   Reply With Quote
Old 03-22-2021, 05:06 PM   #10
gxray
Human being with feelings
 
Join Date: Dec 2020
Location: Miami, FL USA
Posts: 396
Default

Quote:
Originally Posted by whats_up View Post
sorry for the little buggy previous release.
new update on github.
https://github.com/VisualCodeBase/CodeBase
I tried to compile a few of Saike's JSFX with previous release to VST, because they are really good and many people outside of REAPER should appreciate them.

Was very cool =D
But did run into a few bugs:

Code:
File:C:/Users/rayga/Downloads/CodeBase/CodeBase/Source/Examples/Projects/PVF/Yutani/Yutani_Dependencies/Saike_Yutani_widgets.jsfx-inc 
                                                                                                             (As Int)(As UInt)(mouse_cap)  And% 1 == 0 ) ? (                                                                          Warning: Syntax Error                                                                                                        in 

File:C:/Users/rayga/Downloads/CodeBase/CodeBase/Source/Examples/Projects/PVF/Yutani/Yutani_Dependencies/Saike_Yutani_widgets.jsfx-inc       
                                                                                                       (As Int)(As UInt)(lmc_i_)  And% 1 == 0)) ? 1 : 0;


I think also some variables cannot be used because they conflict with keywords -- "end" appeared to be one of them:
Code:
Error: Syntax Error                                                                in File:C:/Users/rayga/Downloads/CodeBase/CodeBase/Source/Examples/Projects/PVF/Yutani/Yutani_Dependencies/Saike_Yutani_sample_delay_buffer.jsfx-inc

              e¯d, write_ptr, read_ptr)


And the final thing -- when assignments are made inside of JSFX "SliderAutomate()" function. I think this is not expected, because the compiler tries to translate these to automatable input VST params:



I think compiler is expecting a reference to the slider or a single mask value, to translate into a VST updateable param
__________________
Seasoned codemonkey
Dunno a thing about making music (here to learn!)
gxray is offline   Reply With Quote
Old 03-28-2021, 12:12 PM   #11
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by gxray View Post
I tried to compile a few of Saike's JSFX with previous release to VST, because they are really good and many people outside of REAPER should appreciate them.

Was very cool =D
But did run into a few bugs
thank you for try. the first is not bug is warning, that parts in the expression should be surrounded with parentheses

Quote:
I think also some variables cannot be used because they conflict with keywords -- "end" appeared to be one of them:
no, every variable name can be used.
but a better test on your side, is to to work with the new release.

'end' was a bug in the previous release, it was fixed.

'slider_automate' with variable index, is incomplete yet.

anyway saike plugs is sure on our test list.
so maybe give the plug name, and we'll start with it.

thanks again.
whats_up is online now   Reply With Quote
Old 03-29-2021, 01:57 AM   #12
sai'ke
Human being with feelings
 
sai'ke's Avatar
 
Join Date: Aug 2009
Location: NL
Posts: 1,453
Default

Hey man, cool project! Unfortunately, I don't have enough time on my hands to look into it in more detail personally at the moment.

But purely based on requests I've received, I think Swellotron and Filther have been the most requested ones. Personally, I would be most interested in Reflectosaurus, and whether there's any speedup there from this cross compilation. They're probably not the easiest ones to port though.

If you decide to do this, I'd be pretty interested in linking them wherever you store them.
__________________
[Tracker Plugin: Thread|Github|Reapack] | [Routing Plugin: Thread|Reapack] | [More JSFX: Thread|Descriptions|Reapack]
sai'ke is offline   Reply With Quote
Old 04-27-2021, 07:03 PM   #13
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default new update

the new update include more plugins examples
includes saike second most big plug - yutani

https://stash.reaper.fm/v/41912/Untitled.png

wdl/lice from Cockos is used for drawing by default.

all of the plugs compiled with no errors, and with no change to the original source.
some of them work completely fine, some not.

saike - thank you for the attention and for you plugs.

all the plugs are in the examples folder in the package on github
https://github.com/VisualCodeBase/CodeBase

Last edited by whats_up; 04-28-2021 at 12:01 AM.
whats_up is online now   Reply With Quote
Old 04-28-2021, 06:33 AM   #14
mschnell
Human being with feelings
 
mschnell's Avatar
 
Join Date: Jun 2013
Location: Krefeld, Germany
Posts: 14,690
Default

In several forums (virtual instruments) I regularly recommend to use Reaper for allowing for Midi preprocessing by JSFXes.

Is it viable to use this system to compile Midi Filter JSFXes to VSTs ?

-Michael

Last edited by mschnell; 04-28-2021 at 10:16 AM.
mschnell is offline   Reply With Quote
Old 04-28-2021, 07:54 AM   #15
gxray
Human being with feelings
 
Join Date: Dec 2020
Location: Miami, FL USA
Posts: 396
Default

Quote:
Originally Posted by whats_up View Post
the new update include more plugins examples
includes saike second most big plug - yutani

https://stash.reaper.fm/v/41912/Untitled.png

wdl/lice from Cockos is used for drawing by default.

all of the plugs compiled with no errors, and with no change to the original source.
some of them work completely fine, some not.

saike - thank you for the attention and for you plugs.

all the plugs are in the examples folder in the package on github
https://github.com/VisualCodeBase/CodeBase
That's incredible!!
__________________
Seasoned codemonkey
Dunno a thing about making music (here to learn!)
gxray is offline   Reply With Quote
Old 05-03-2021, 09:51 AM   #16
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by mschnell View Post

Is it viable to use this system to compile Midi Filter JSFXes to VSTs ?

-Michael
yes. more ever, currently these type of (midi) plugs work with no problems.
whats_up is online now   Reply With Quote
Old 05-03-2021, 09:53 AM   #17
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default a new update with important fix

audio only plugs (in eel mode) had missing code which prevent them from making sound.
whats_up is online now   Reply With Quote
Old 05-03-2021, 03:18 PM   #18
mschnell
Human being with feelings
 
mschnell's Avatar
 
Join Date: Jun 2013
Location: Krefeld, Germany
Posts: 14,690
Default

Quote:
Originally Posted by whats_up View Post
audio only plugs (in eel mode) had missing code which prevent them from making sound.
You might want to check this with the ReaRack suite.

Those plugins would be very viable to be used on other systems.

-Michael
mschnell is offline   Reply With Quote
Old 05-10-2021, 01:34 PM   #19
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by mschnell View Post
You might want to check this with the ReaRack suite.

Those plugins would be very viable to be used on other systems.

-Michael
thank you. do you have a link ? i did a search in google but didn't find a link.
whats_up is online now   Reply With Quote
Old 05-10-2021, 03:07 PM   #20
sai'ke
Human being with feelings
 
sai'ke's Avatar
 
Join Date: Aug 2009
Location: NL
Posts: 1,453
Default

I should play around with this on the weekend a bit.

I notice that font rendering and some of the GFX seem to be off. You mention in the readme that it doesn't function correctly yet?

Is there anything I should try and avoid using in JSFX to make the plugins easier to port like this?

I noticed in the readme that you mentioned the placeholder sliders. Unfortunately, they are there to work around an issue with the learn ability in REAPER. It seems that some functionalities break if you skip slider numbers. See also this: https://forum.cockos.com/showthread.php?t=239718. Should I give them unique names, for it to work in your transpiler?

You mentioned something about an open comment in the JSFX? Is it because of the listing that lists that the entire subdir should be included? I can probably remove that from the original by just explicitly listing the files:
Code:
provides:
  Yutani_Dependencies/*
I'm curious, have you noticed any performance gains or losses porting plugins like this?
__________________
[Tracker Plugin: Thread|Github|Reapack] | [Routing Plugin: Thread|Reapack] | [More JSFX: Thread|Descriptions|Reapack]
sai'ke is offline   Reply With Quote
Old 05-10-2021, 03:10 PM   #21
mschnell
Human being with feelings
 
mschnell's Avatar
 
Join Date: Jun 2013
Location: Krefeld, Germany
Posts: 14,690
Default

Quote:
Originally Posted by whats_up View Post
thank you. do you have a link ? i did a search in google but didn't find a link.
Of course it's in ReaPack and decently documented there. Otherwise I would not recommend it.

-Michael
mschnell is offline   Reply With Quote
Old 05-17-2021, 11:15 AM   #22
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by sai'ke View Post
I should play around with this on the weekend a bit.

I notice that font rendering and some of the GFX seem to be off. You mention in the readme that it doesn't function correctly yet?

Is there anything I should try and avoid using in JSFX to make the plugins easier to port like this?

I noticed in the readme that you mentioned the placeholder sliders. Unfortunately, they are there to work around an issue with the learn ability in REAPER. It seems that some functionalities break if you skip slider numbers. See also this: https://forum.cockos.com/showthread.php?t=239718. Should I give them unique names, for it to work in your transpiler?

You mentioned something about an open comment in the JSFX? Is it because of the listing that lists that the entire subdir should be included? I can probably remove that from the original by just explicitly listing the files:
Code:
provides:
  Yutani_Dependencies/*
I'm curious, have you noticed any performance gains or losses porting plugins like this?
thank you for reply.
thank you for your plugs. i like very much your last plugs yutani and seq
i don't remember i ever saw something like seq.
thank you for writing big complex plugs. they're very helpful in improving the compliers (pvf+neutron+codebase)

in short current version has two bugs and some issues with text draw.
that because lice is used for drawing except of text draw + font support.

hopefully in few days a new release come.

sliders have to have unique name.

long expressions are supported, but try to avoid too long,
i'm not sure but it might be a problem with the cpp backend compiler.

this is example for a long expression
Quote:
a =
c || d ? 1 :
c || d ? 1 :
c || d ? 1 :
c || d ? 1 :
...
the above can be written like this:
Quote:
c || d ? a = 1 :
c || d ? a = 1 :
c || d ? a = 1 :
c || d ? a = 1 :
c || d ? a = 1 :
...
as i said i reworked all the compilers to handle long expressions
(as long as they're no longer than 30KB).

i didn't see any difference in cpu usage but it's too early to tell.
i also use only basic optimization level,
but the user can change the setting, or compile him self.


open comment and auto folder scan (looking for import) fully supported
but not by default. you have to specify command line argument '-e'.

Last edited by whats_up; 05-23-2021 at 06:19 AM.
whats_up is online now   Reply With Quote
Old 07-22-2021, 09:04 PM   #23
MusoBob
Human being with feelings
 
MusoBob's Avatar
 
Join Date: Sep 2014
Posts: 2,643
Default

I was looking at Jeep-Geez and managed to get it working then got directed here to CodeBase but got a bit lost with it,
is there an easy step by step Dummies guide or video for this js to vst ?
If you could just do simple step by step guide to create megababy vst for example, installing mingw-w64, CodeBase etc..
Thanks.



__________________
ReaTrakStudio Chord Track for Reaper forum
www.reatrak.com
STASH Downloads https://stash.reaper.fm/u/ReaTrak
MusoBob is offline   Reply With Quote
Old 07-25-2021, 06:25 AM   #24
daxliniere
Human being with feelings
 
daxliniere's Avatar
 
Join Date: Nov 2008
Location: London, UK
Posts: 2,581
Default

Very cool!
__________________
Puzzle Factory Sound Studios, London [Website] [Instagram]
[AMD 5800X, 32Gb RAM, Win10x64, NVidia GTX1080ti, UAD2-OCTO, FireFaceUCX, REAPER x64]
[Feature request: More details in Undo History]
daxliniere is offline   Reply With Quote
Old 07-25-2021, 08:13 PM   #25
Time Waster
Human being with feelings
 
Time Waster's Avatar
 
Join Date: Aug 2013
Location: Bowral, Australia
Posts: 1,638
Default

For the latest version of the ReaRack JSFX's, best to use the version in the stash, as I'm not sure if I have kept the Repack version up to date (must check that). I would be very interested to know if they compile across to VST's. See my signature below for the link.
__________________
Mal, aka The Wasters of Time
Mal's JSFX: ReaRack2 Modular Synth
Time Waster is offline   Reply With Quote
Old 07-28-2021, 10:05 PM   #26
MusoBob
Human being with feelings
 
MusoBob's Avatar
 
Join Date: Sep 2014
Posts: 2,643
Default

Quote:
Originally Posted by MusoBob View Post
I was looking at Jeep-Geez and managed to get it working then got directed here to CodeBase but got a bit lost with it,
is there an easy step by step Dummies guide or video for this js to vst ?
If you could just do simple step by step guide to create megababy vst for example, installing mingw-w64, CodeBase etc..
Thanks.
BUMP
Anyone here that uses CodeBase JS to VST can make a guide ??
__________________
ReaTrakStudio Chord Track for Reaper forum
www.reatrak.com
STASH Downloads https://stash.reaper.fm/u/ReaTrak
MusoBob is offline   Reply With Quote
Old 07-29-2021, 12:12 PM   #27
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

coming soon fixed 32/64 bit version
i can tell that saike - yutani works perfectly now - except of one gfx function issue.

all the other examples work perfectly.

except of on gfx issue in TIME WASTER pluck - plug

stay tune. thanks for your interest.
whats_up is online now   Reply With Quote
Old 07-29-2021, 12:16 PM   #28
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by MusoBob View Post
BUMP
Anyone here that uses CodeBase JS to VST can make a guide ??
you can build the examples from the ide
recent projects, they were tested and work out of the box.

more ever if you get into the examples folder you will found batch files .
those are build files, were tested and work out of the box.


AS long AS - you have GCC already installed and its path can be found in the environment.
whats_up is online now   Reply With Quote
Old 07-29-2021, 05:25 PM   #29
MusoBob
Human being with feelings
 
MusoBob's Avatar
 
Join Date: Sep 2014
Posts: 2,643
Default

Code:
....
....
C:/mingw-w64/bin/../lib/gcc/x86_64-w64-mingw32/8.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lmsvcrt
collect2.exe: error: ld returned 1 exit status

***** Error *****


""""" Compilation Error """""
That is the first thing I tried.
It didn't work with the Jeep-Geez GCC so I downloaded the
https://sourceforge.net/projects/mingw-w64/files/
to C:\
that didn't work so I found the mingw-w64.exe installer and that installed to C:\Program Files, that didn't work running the *.bat because of the space in the path name.
I copied the folder from Program Files to C:\mingw-w64 and that gives the error above.

With the ReaTrak scripts I made I always give a guide for those that may be new to Reaper and scripting to make it easy for them.
We all had to learn Dos or Windows at one stage in our life, we had a guide or someone else showing us how to....
It may be from being in hospitals for years and years and years, on life support machines, close to death, out of my body into other dimensions, on medical drugs for 13 years that may have effected my brain I wonder ?? So, just a little guide would be really appreciated, you know ?
__________________
ReaTrakStudio Chord Track for Reaper forum
www.reatrak.com
STASH Downloads https://stash.reaper.fm/u/ReaTrak
MusoBob is offline   Reply With Quote
Old 07-31-2021, 11:45 PM   #30
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by MusoBob View Post
Code:
....
....
C:/mingw-w64/bin/../lib/gcc/x86_64-w64-mingw32/8.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lmsvcrt
collect2.exe: error: ld returned 1 exit status

***** Error *****


""""" Compilation Error """""
That is the first thing I tried.
It didn't work with the Jeep-Geez GCC so I downloaded the
https://sourceforge.net/projects/mingw-w64/files/
to C:\
that didn't work so I found the mingw-w64.exe installer and that installed to C:\Program Files, that didn't work running the *.bat because of the space in the path name.
I copied the folder from Program Files to C:\mingw-w64 and that gives the error above.

With the ReaTrak scripts I made I always give a guide for those that may be new to Reaper and scripting to make it easy for them.
We all had to learn Dos or Windows at one stage in our life, we had a guide or someone else showing us how to....
It may be from being in hospitals for years and years and years, on life support machines, close to death, out of my body into other dimensions, on medical drugs for 13 years that may have effected my brain I wonder ?? So, just a little guide would be really appreciated, you know ?
as you describe your problem is not with geep nor with codebase but with mingw.
first try to build (compile and link) small c file like this:
filename: t.cpp
Code:
#include <stdio.h>
#Include <stdlib.h>

int main (void) {
  printf(" success ...");
  fflush(stdout);
  return 0;
}
with this batch file
Code:
g++ t.cpp&pause
than tell us the result.

if the above doesn't work do from windows console
Code:
set&pause
and post here the output.

Last edited by whats_up; 08-01-2021 at 12:35 AM.
whats_up is online now   Reply With Quote
Old 08-01-2021, 07:41 AM   #31
MusoBob
Human being with feelings
 
MusoBob's Avatar
 
Join Date: Sep 2014
Posts: 2,643
Default

Quote:
Originally Posted by MusoBob View Post
...
If you could just do simple step by step guide to create megababy vst for example, installing mingw-w64, CodeBase etc..
That would help.
__________________
ReaTrakStudio Chord Track for Reaper forum
www.reatrak.com
STASH Downloads https://stash.reaper.fm/u/ReaTrak
MusoBob is offline   Reply With Quote
Old 11-10-2021, 01:44 PM   #32
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default new version

hey i've uploaded new version with some new plugs in the examples folder: Reflectosaurus, seqFX, reEQ

https://stash.reaper.fm/v/43264/Reaper.png
https://stash.reaper.fm/v/43265/ReEQ.png
https://stash.reaper.fm/v/43266/Saike.png
https://stash.reaper.fm/v/43267/TWang.png

twang with default sliders + reEQ + reflectosaurus hosted in fl studio 64 as vst 64 bits


yutani + reflectosaurus hosted in fl studio 64 as vst 64 bits


yutani + reEQ hosted in reaper 64 as vst 64 bits

Last edited by whats_up; 11-17-2021 at 06:08 AM.
whats_up is online now   Reply With Quote
Old 02-23-2022, 08:12 PM   #33
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default new release

with ide 64 bit
bug fixes
download link at top of the thread
whats_up is online now   Reply With Quote
Old 07-27-2022, 02:37 PM   #34
BirdBird
Human being with feelings
 
BirdBird's Avatar
 
Join Date: Mar 2019
Posts: 425
Default

Amazing work! Tried porting a JSFX plugin to VST with this today. Was able to get everything working after an hour or two.

A few things to mention:
Having slider_automate(slider(13)); in the source stopped the plugin from building without throwing any errors. However replacing the line with slider_automate(slider13); worked. There were other pieces of code that used the slider_automate(slider(id)); syntax inside functions, while they did not stop the plugin from building the slider_automate calls won't work with them, so the parameters are not reported to the host as last tweaked parameters. (or receive updates from code that uses it)


While troubleshooting I tried to get the minimal amount of source code I can have to get the plugin to build. This is what I found:
Code:
@init

@gfx
gfx_x;
gfx_y;
A single @init block without any other code will build. However if I add a @gfx block it won't build until I use the variables gfx_x and gfx_y somewhere.

One last thing to mention is JSFX plugins now have a flag to run their user interfaces in higher framerates using options:gfx_hz=60 syntax at the top. Currently PVF doesn't seem to do anything with it.
Thanks again for the amazing work and interested to see where this ends up!
-
BirdBird is offline   Reply With Quote
Old 07-29-2022, 02:25 PM   #35
Rockum
Human being with feelings
 
Join Date: Apr 2009
Location: Nashville
Posts: 178
Default

I am with Musobob... if you could post a guild or video walkthough, it would be greatly appreciated.
Rockum is offline   Reply With Quote
Old 08-01-2022, 07:32 AM   #36
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by BirdBird View Post
Amazing work! Tried porting a JSFX plugin to VST with this today. Was able to get everything working after an hour or two.

A few things to mention:
Having slider_automate(slider(13)); in the source stopped the plugin from building without throwing any errors. However replacing the line with slider_automate(slider13); worked. There were other pieces of code that used the slider_automate(slider(id)); syntax inside functions, while they did not stop the plugin from building the slider_automate calls won't work with them, so the parameters are not reported to the host as last tweaked parameters. (or receive updates from code that uses it)


While troubleshooting I tried to get the minimal amount of source code I can have to get the plugin to build. This is what I found:
Code:
@init

@gfx
gfx_x;
gfx_y;
A single @init block without any other code will build. However if I add a @gfx block it won't build until I use the variables gfx_x and gfx_y somewhere.

One last thing to mention is JSFX plugins now have a flag to run their user interfaces in higher framerates using options:gfx_hz=60 syntax at the top. Currently PVF doesn't seem to do anything with it.
Thanks again for the amazing work and interested to see where this ends up!
-
thank you very much for the report
i'll check

the new feature I only now hear about it
will check
__________________
Easy EEL to VST Building system
https://forum.cockos.com/showthread.php?t=245285
github: https://github.com/VisualCodeBase/CodeBase
whats_up is online now   Reply With Quote
Old 08-01-2022, 07:44 AM   #37
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by BirdBird View Post
slider_automate(slider(id));
i just checked my offline help
Quote:
slider(sliderindex) -- REAPER 3.11+
Context: available everywhere
If you wish to programmatically choose which slider to access, use this function (rather than sliderX). Valid syntaxes include:

val = slider(sliderindex);
slider(i) = 1;
it doesn't say that slider return a value.
more tests required.

EDIT: sorry now I notice that it does return the slider value, will check.
__________________
Easy EEL to VST Building system
https://forum.cockos.com/showthread.php?t=245285
github: https://github.com/VisualCodeBase/CodeBase

Last edited by whats_up; 08-01-2022 at 09:54 PM.
whats_up is online now   Reply With Quote
Old 08-03-2022, 04:43 AM   #38
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

I just checked the slider_automate issue.
I can fix the problem, but please note that it expects a slider index/mask
while slider(xxx) return slider value.

so this code:
Code:
slider_automate(slider(13))
looks like a bug
unless slider13 value is a slider index/mask
__________________
Easy EEL to VST Building system
https://forum.cockos.com/showthread.php?t=245285
github: https://github.com/VisualCodeBase/CodeBase
whats_up is online now   Reply With Quote
Old 08-03-2022, 05:18 AM   #39
BirdBird
Human being with feelings
 
BirdBird's Avatar
 
Join Date: Mar 2019
Posts: 425
Default

Quote:
Originally Posted by whats_up View Post
looks like a bug
unless slider13 value is a slider index/mask
Thanks, I think the JSFX docs don't actually make this super clear, slider_automate expects a slider mask, which slider(id) turns into compile time. (I think)
So slider_automate(13); does not work while slider_automate(slider(13)); does.
Here is a short example that moves a slider with the mouse position:
Code:
desc:Sliders

slider1:0<0,1,0.0001>slider 1
slider13:0<0,1,0.0001>slider 13

@gfx 80 400
v = max(min(mouse_x/gfx_w, 1), 0);
slider(13) = v;
slider_automate(13);
^^The code above will not report slider13 as being tweaked, while the following one will:

Code:
desc:Sliders

slider1:0<0,1,0.0001>slider 1
slider13:0<0,1,0.0001>slider 13

@gfx 80 400
v = max(min(mouse_x/gfx_w, 1), 0);
slider(13) = v;
slider_automate(slider(13));
Another difference I have found (tangentially related) was that REAPER seems to call @slider block when it receives automation for parameters, the VST plugins that come out PVF don't do it I believe, which can break automation for certain JSFX plugins.

Last edited by BirdBird; 08-03-2022 at 05:28 AM.
BirdBird is offline   Reply With Quote
Old 08-03-2022, 06:38 AM   #40
whats_up
Human being with feelings
 
Join Date: Nov 2020
Posts: 180
Default

Quote:
Originally Posted by BirdBird View Post
Thanks, I think the JSFX docs don't actually make this super clear, slider_automate expects a slider mask, which slider(id) turns into compile time. (I think)
So slider_automate(13); does not work while slider_automate(slider(13)); does.
Here is a short example that moves a slider with the mouse position:
Code:
desc:Sliders

slider1:0<0,1,0.0001>slider 1
slider13:0<0,1,0.0001>slider 13

@gfx 80 400
v = max(min(mouse_x/gfx_w, 1), 0);
slider(13) = v;
slider_automate(13);
^^The code above will not report slider13 as being tweaked, while the following one will:

Code:
desc:Sliders

slider1:0<0,1,0.0001>slider 1
slider13:0<0,1,0.0001>slider 13

@gfx 80 400
v = max(min(mouse_x/gfx_w, 1), 0);
slider(13) = v;
slider_automate(slider(13));
Another difference I have found (tangentially related) was that REAPER seems to call @slider block when it receives automation for parameters, the VST plugins that come out PVF don't do it I believe, which can break automation for certain JSFX plugins.
I did a short test with tHe debbuger
before i replied
i also will test your code later
__________________
Easy EEL to VST Building system
https://forum.cockos.com/showthread.php?t=245285
github: https://github.com/VisualCodeBase/CodeBase
whats_up is online now   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 06:06 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.