Submit your tutorial requests

tutorials

#30

Debugging/Profiling tutorial would be helpful.
As a noob took me far too long to realise how to see the DBG output in xcode, as for profiling I’m still clueless!


#31

How to do Single-Compilation-Units (or unity builds), aka how does the JUCE Module format work and why do we do it that way?

I’ve since figured that out, but it would be a great tutorial to have


#32

A tutorial on making menus of different types would be great.


#33

how many types of menus are there? popup and menubar? what else is there?


#34

Sure, but as far as I can tell there’s no tutorials for any kind of menus. Also how to tell a menu to update itself if an item becomes checked etc.


#35

Study the juceDemo, it has a very standard example of how to create menus, menu bars, and popup menus


#36

It’s not that I don’t know how to do it, I just think it would be a useful tutorial because it’s a pretty common feature to want in an app.


#37

I could be mistaken, but I’m sure they’re looking for tutorial ideas that the example projects included with the Juce git repo don’t already demonstrate. The source code for ProJucer and juceDemo are included in the repo and they both have awesome examples of 3D rendering, popup windows, menus, multi-threading, saving/loading, streaming from URLs, etc. If someone isn’t sure how to accomplish something on their own project, those source files should be the first place to look for an idea of how to proceed.


#38

Ok I guess you know better


#39

The code for ProJucer and JuceDemo are indeed full of examples. However, they are also packed full of code that often has nothing to do with what you are trying to learn.

To many, it is easier to learn from isolated, specific examples. So, I would vote for individual tutorials on any topic that will be helpful to the learning effort.


#40

https://docs.juce.com/master/classPopupMenu.html#details has a pretty excellent example for popup menu creation, which is what the MenuBarComponent displays when you click on a menu title. The popupMenu that the MenuBarComponent displays is provided by the MenuBarModel instance passed to the MenuBarComponent.

regarding ticks for individual menu items:

void PopupMenu::addItem ( int itemResultID,
   const String & 	itemText,
   bool 	isEnabled = true,
   bool 	isTicked = false 
)	

for the isTicked parameter, just do something like this:

myMenu.addItem( idNumber,  //itemResultID
   "menuItemDisplayText",  //itemText
   true, //isEnabled
   someConditional == desiredValueToShowTick ? true : false //isTicked
);

Hope that helps


#41

I’d love to see a tutorial on how to create a custom JUCE module


#42

it’s easy:

///myModule.h
BEGIN_JUCE_MODULE_DECLARATION
   ID:  MyModule
   vendor: MeMySelfAndI
   version:  1.0
   description: my custom juce module
   website:  https://mymodule.com
   license: MIT
   dependences: juce_core
   OSXFrameworks: Accelerate
   iOSFrameworks: Accelerate

END_JUCE_MODULE_DECLARATION
//define your header guard here

/*
include everything your module header files require here
*/
#include <juce_core/juce_core.h>
#include <array>
#include <algorithm>

//wrap your module in a namespace
namespace MyModule {
/*
now include each module header file
*/
#include "parts/PartA.h"
#include "parts/PartB.h"
} 
//#endif your header guard

and

///MyModule.cpp
#include MyModule.h
namespace MyModule
{
/*
now include every .cpp in your module. 
note that your .cpp files must NOT include anything themselves, as the includes at the top of MyModule.h take care of that
*/
#include "parts/PartA.cpp"
#include "parts/PartB.cpp"
}

that would work for a module with folder hierarchy:

./parts/PartA.h
./parts/PartA.cpp
./parts/PartB.h
./parts/PartB.cpp
./MyModule.h
./MyModule.cpp

#43

An example of a plugin that uses multiple programs / factory presets (including saving/restoring state of the different parameters) would be helpful to have in the examples folder. It would be handy to have this as a reference plugin (for testing reproducibility in case of issues), and then why not create a tutorial for it while at it?

PS
I know there is an tutorial on adding plugin parameters + one on saving/restoring plugin state, but I didn’t find a plugin example that uses a number of programs > 0.


#44

There’s a pretty detailed doc about it right there in the main repo:


#45

Tutorial(s) on best practices how to use threaded code together with GUI code. (Progress bars, cancellation, callbacks that should happen on the GUI thread when the worker thread has finished etc…)

Just telling people to use ThreadWithProgressWindow doesn’t really cut it. :wink:


#46

Seconded.


#47

Tutorials on how to effectively enter in a Custom PList in the Projucer. Nothing I put in there works. It gets rejected by XCode, so I have to enter it into XCode manually every time I archive my app.


#48

My strategy in regards to using threaded code with GUI code is for the threads to communicate with each other by leaving messages behind:

  1. Thread does processing. Sets flag
  2. Timer (GUI) component checks for flags
  3. Timer component continues processing. Updates graphics.

#49