Login / Register  0 items | $0.00 New What is KVR? Submit News Advertise
dskdskdsk
KVRist
 
31 posts since 13 Feb, 2011

Postby dskdskdsk; Wed Aug 10, 2011 6:35 am

CalabiYauGuy wrote:I picked it up with just college math (from Romania)


Salut! I lived in Oradea when I was a child... There must have been something in the water that gave us a knack for DSP. :) Edit: I haven't yet established that I have a knack for this, just to be clear.

And, on a serious note, I think the most important ingredient for learning anything is a desire. You have to want it.

I'm on hour 100 of 10,000.
Syrou
KVRist
 
54 posts since 20 Oct, 2010

Postby Syrou; Mon Apr 02, 2012 12:16 am

Borogove wrote:
WilliamK wrote:Also, when using strings, remember to leave some extra chars at the end as a string END will use extra char information. EG: char Msg[10] you can't do strcpy(Msg,"1234567890"); Is best to use strncpy(Msg,"1234567890",10); This avoid problems. Most times use the strncpy to avoid buffer-overrun.


If you do strncpy that way, you will avoid the immediate buffer overrun, but you now have a non-terminated string which won't print correctly (at best). I recommend that you never call strncpy directly, but instead make a function like:
Code: Select all
char* strncpy_safe( char* dest, char* src, char* length )
{
   char* result = strncpy( dest, src, length );
   dest[length-1] = 0;
   // good catch, stefan
   return result;
}


In its current form, strncpy() is one of the most dangerous functions in the C library simply because it lulls intermediate programmers into a false sense of security.


haha yes, that null terminator is dangerous!
HeavensOnEarth
Banned

Postby HeavensOnEarth; Thu Aug 09, 2012 1:31 am

Sad to say it, but it seems the most important part now, if you're not inside a corporation or indedendently wealthy, is to include a library for Internet authentication, with Internet=based deactivation too. It won't discourage the most determined, but it's enough to ensure people know it is intended to pay someone's bills.
HeavensOnEarth
Banned

Postby HeavensOnEarth; Thu Aug 09, 2012 11:02 pm

[quote="dskdskdsk"]

I'm on hour 100 of 10,000.[/quote]

I'm not sure I could be sure to understand everything in this thread, but I certainly understance that. Enjoy :)
User avatar
jobromedia
KVRAF
 
4918 posts since 10 Feb, 2006, from Stockholm, Sweden

Postby jobromedia; Mon Sep 10, 2012 12:04 pm

A bunch of really good advices in this topic.

Got an Ipad? Then there is a few C / C++ books in the iBook library, and this one is specially worth taking a look at:

I bought a book called Beginner C++ programming which was really cheap. It costed me 25 SEK ($3.78 USD). It's an illustrated book, and it's really simple to read and get a hang of things in it. Ofc I haven't had the chance yet to read it yet, since the download acted up a bit. It's IIRC based on Mac, but I think that the most examples can be converted to Windows / Linux.
Best regards from Johan Brodd.
JoBroMedia since 1996.
sweet_trip
KVRian
 
995 posts since 24 Apr, 2002

Postby sweet_trip; Fri Nov 02, 2012 9:20 pm

What do yo guys think of Java for audio programming? I ask in reference to Android programming...
agentile1990
KVRer
 
6 posts since 22 May, 2012, from Nashville, TN

Postby agentile1990; Tue Jan 08, 2013 8:35 am

I know this thread is old, but I stumbled upon it when I started my VST journey. It took me 2 semesters of C++ classes and about 8 months of tinkering with the DSP and the VST container, but I have my first original VST plugin.

It is a very rewarding experience and I hope that all beginners reading this will put forth the time and effort to make something really cool.

If you're interested in checking out my handy work, I am a designer at Gourmet Grooves. You can download demo versions of my plugin for MAC and PC here:

PC - http://cloud.gourmet-grooves.com/public.php?service=files&file=%2FLabs%2Ffiles%2FPC%20-%20LComp-P%20DEMO%20VERSION.zip
MAC - http://cloud.gourmet-grooves.com/public.php?service=files&file=%2FLabs%2Ffiles%2FMAC%20-%20LComp-P%20DEMO%20VERSION.zip

If you want to check out other cool stuff Gourmet Grooves is doing, see our website: http://www.gourmet-grooves.com

btw, the entire site is a DIY operation. Great things can be done with a few weeks and a computer.

Best of luck to all on their VST journey. Let's make something cool. [/url]
cpr
KVRist
 
139 posts since 8 May, 2007, from California

Postby cpr; Tue Jan 08, 2013 12:13 pm

Nice to see the Apollo on your front page.. :)
overhishead
KVRist
 
240 posts since 21 Jan, 2007

Postby overhishead; Mon Feb 17, 2014 12:38 pm Re: What are the most important parts of C++ for coding plug

What I didn't realize before was that the VST SDK 2.4 contained example projects for Microsoft Visual Studio that show you in plain easy to understand black and white, which are the most important parts of code for coding VST plugins.

Further, there are visual studio projects out there on the net that you can compile yourself.

the Juce framework is a toolkit that you can include.

hardly anybody codes every last line themselves anymore, it's a team effort.
User avatar
CarnivorousAmphibian
KVRer
 
22 posts since 18 Nov, 2014

Postby CarnivorousAmphibian; Sun Nov 30, 2014 11:33 am Re: What are the most important parts of C++ for coding plug-ins?

Math. functions that can shape a ramp signal, i.e. sample number 123456... into sines, triangles, sawtooths, pulses, etc.

lerp functions that can antialias oscillators so they dont jump -1 1 amplitude on your speaker in 1 44000ds of a second

Arrays that can read wavetables, i.e. pre recorded osc waves, and can read conversion tables like p2f.

if, else if, else if, else, conditions that can do multiplex/selector routing, so you use one button to select any number of configurations in the synth.

some randomisation functions

code some filters from musicdsp website, i managed the one from the cookbook reference, thanks to some help. filters are useful on sea anenomes and on synths.
doglios
KVRer
 
6 posts since 16 Jan, 2016

Postby doglios; Mon Jan 18, 2016 2:08 pm Re: What are the most important parts of C++ for coding plug-ins?

I'm on Mac 10.5.8 and I have to say, I haven't even been able to figure out how to get a f***ing sin wav output to my audio system using C++ after downloading like 5 different libraries and wasting a TON TON TON TON TON of time messing with Terminal and compilation issues.

It has been *extremely* disheartening, to say the least. I even got the BasicSynth book and can't get a f***ing thing to work on my computer with that, or with anything else. At this point I am packing it in and moving back to just messing with MIDI.

I honestly think if I could have just gotten a simple sin wav output up and running that would have been nice. It shouldn't be this hard - but I guess it is. I've got some updates in the mail and maybe, just maybe, they'll help.

But I have to say, I really am extremely frustrated.

That said I've only been programming for a few months, and only been using C++ for two weeks at this point.

Still... I can't help but feel sad. I have literally spent about a week straight trying and failing to get any libraries to work on my computer. I had a relatively complex program with a GUI and excellent features built in Python after picking up computer programming for the first time in my life - within a couple weeks!

You'd think there would just be a straightfoward guide to using built in stuff to make such a SIMPLE sin wav program without a f***ing library... but no.

I just want a god damn sin wav in real time, with some basic parameters, that doesn't use external libraries. I know that may sound stupid but I can't figure a f***ing thing out when every header file in any library (CoreAudio as well) has 1,000 things in it that have nothing to do with my problem.

I just don't get how it has to be this complicated to just build a sin wav with real time audio output in a single file without a header or ANYTHING overly complicated. I mean - that's literally the most basic level of audio output that there is. So yeah.

I had to rage somewhere.
Keith99
KVRian
 
1145 posts since 15 Mar, 2007, from Yorkshire, England

Postby Keith99; Mon Jan 18, 2016 2:44 pm Re: What are the most important parts of C++ for coding plug-ins?

I feel your pain! I have been programming c++ for 30+ years now and all I can say is it does get easier :) but you are in for a tough time to start with. Unlike other languages C++ relies very heavily on libraries so you need to understand how to work with them first.

For a simple sin wave plugin you couldtake the again example from the SDK and modify that as a starting point
ChrisNilson
KVRer
 
1 post since 2 Jan, 2016, from Las Vegas / Paris

Postby ChrisNilson; Sun Feb 07, 2016 10:15 am Re: What are the most important parts of C++ for coding plug-ins?

doglios wrote:I'm on Mac 10.5.8 and I have to say, I haven't even been able to figure out how to get a f***ing sin wav output to my audio system using C++ after downloading like 5 different libraries and wasting a TON TON TON TON TON of time messing with Terminal and compilation issues.

It has been *extremely* disheartening, to say the least. I even got the BasicSynth book and can't get a f***ing thing to work on my computer with that, or with anything else. At this point I am packing it in and moving back to just messing with MIDI.

I honestly think if I could have just gotten a simple sin wav output up and running that would have been nice. It shouldn't be this hard - but I guess it is. I've got some updates in the mail and maybe, just maybe, they'll help.

But I have to say, I really am extremely frustrated.

That said I've only been programming for a few months, and only been using C++ for two weeks at this point.

Still... I can't help but feel sad. I have literally spent about a week straight trying and failing to get any libraries to work on my computer. I had a relatively complex program with a GUI and excellent features built in Python after picking up computer programming for the first time in my life - within a couple weeks!

You'd think there would just be a straightfoward guide to using built in stuff to make such a SIMPLE sin wav program without a f***ing library... but no.

I just want a god damn sin wav in real time, with some basic parameters, that doesn't use external libraries. I know that may sound stupid but I can't figure a f***ing thing out when every header file in any library (CoreAudio as well) has 1,000 things in it that have nothing to do with my problem.

I just don't get how it has to be this complicated to just build a sin wav with real time audio output in a single file without a header or ANYTHING overly complicated. I mean - that's literally the most basic level of audio output that there is. So yeah.

I had to rage somewhere.



My advices if you want to code audio application would be:
1°) Be sure to be okay with the basics of audio signal processing (no need to be a math expert be knowing what is the math behind a sinus wave is good)
2°) Study the basics of the programmation
3°) Read book. I would recommend you this one "Learning Core Audio: A Hands-On Guide to Audio Programming for Mac and iOS" by Chris Adamson, Kevin Avila
4°) Enjoy
Signature blocked until 5 posts made
User avatar
nonnaci
KVRist
 
97 posts since 7 Feb, 2017

Postby nonnaci; Thu Feb 09, 2017 7:33 am Re: What are the most important parts of C++ for coding plug-ins?

In short, performance. DSP is one of those fields where real-time processing is a serious constraint which is why low-level languages such as C/C++/Assembly are used. Tackling the problem of performance can be done on several levels of abstraction from high-level algorithms (learn mathematics, complexity analysis, data structures, Fourier anything) to the low-level nitty gritty (bottlenecked code is often some inner loop that needs to be optimized via assembly/SIMD operations). Between these poles are all the computer-science related background from knowing how the OS works, memory management, caching, instruction parallelism/branching, etc etc.
Previous

Moderator: Moderators (Main)

Return to DSP and Plug-in Development