Basic Audio 'Save As' dialog


#1

I think this is a basic type question, but I was wondering if someone could nudge me in the right direction regarding the creation of a ‘save’ dialog box that allows the user to select which audio format that want to save? I’m thinking a dialog box with a FilenameComponent, and a combobox that is populated with available types from information retrieved from AudioFormatManager. Or, is there another way? possibly even an existing component? Thanks.

-cpr


#2

as a follow up, I realize I would like the full FileChooser type dialog, with the extra controls in it. How is this done? Do I over-ride FileChooser and override paint in such a way that the base class does it’s painting, and then I do mine? But, then how do I make sure the window is big enough for my controls? Anyways, enough speculation, any pointers? :slight_smile:

-cpr


#3

If you need a really customised dialog, you can add your own component to the juce file browser classes. The juce demo has an example of using this to show an image preview panel.


#4

Thanks Jules. I took a quick peak at the demo’s usage of the FilePreviewCompoenent, but it is not immediately obvious how I can leverage the preview component for my desired purposes. But, I’ll contiinue to explore, as I assume there is a way, since you suggested it.

-cpr


#5

FileChooser::browseForFiletoSave() ?


#6

I suggested that because the image component could actually be any any component you like - but reading your post again, maybe that’s not what you’re looking for. I’ve not got currently done any code that would add a file type list to a normal box, though.


#7

ok… so, let me change the question. Using JUCE, what is the common way to allow someone to save different formats? Menu items for each audio format one can save? A dialog for selecting formats, then the actual save dialog? Complete custom dialog? Other?

-cpr


#8

TBH I don’t think I’ve ever written an app that needed to do that!


#9

I would have assumed Tracktion saved mixes to multiple formats? But maybe the path to that result is different from my needs. I think I should post this particular question to the forums and see what others have done. Thanks… :slight_smile:

-cpr


#10

cpr : you might modify the sources by yourself… should not be very complicated to add a listbox and other stuffs around…
jules : some applications allow you to save in multiple format, but im not sure you & cpr are understing the same trick.


#11

Hi at all,

I would like to know, if its possible to show only the Filename in the box, instead of the fullPathFilename?