Eric Oulashin's C++ Audio Mixer 1.0
cmdLineApp.cpp File Reference
#include <iostream>
#include <string>
#include <fstream>
#include <vector>
#include <filesystem>
#include <memory>
#include "WAVFile.h"
#include "FLACFile.h"
#include "AudioFileTools.h"
#include "AudioFileResultType.h"
Include dependency graph for cmdLineApp.cpp:

Classes

struct  ProgOptions
struct  AudioFileMixOptions
class  WAVFile
class  FLACFile

Functions

void showProgramHelp ()
ProgOptions parseCommandLine (int argc, char *argv[])
AudioFileMixOptions readAudioFileList (const string &pFilename, vector< string > &pErrorMsgs, vector< string > &pNonexistentFiles)
int main (int argc, char *argv[])
std::shared_ptr< AudioFilecreateAudioFileObjForNewFile (const char *pFilename)
 Creates a shared pointer to an audioFile object for a new (non-existing) audio file - Creates the appropriate subclass object, depending on the filename extension. If the format isn't recognized, returns a null pointer.
AudioFileResultType mixAudioFiles (const std::vector< std::string > &pFilenames, const std::string &pOutputFilename)
 Mixes (merges) multiple audio files into a single file.

Function Documentation

◆ createAudioFileObjForNewFile()

shared_ptr< AudioFile > EOUtils::createAudioFileObjForNewFile ( const char * pFilename)

Creates a shared pointer to an audioFile object for a new (non-existing) audio file - Creates the appropriate subclass object, depending on the filename extension. If the format isn't recognized, returns a null pointer.

Parameters
[in]pFilenameThe name of the audio file
Returns
A shared pointer to an AudioFile object, which will be an instance of the appropriate subclass for the file, or a null pointer if it is not a recognized format.

Referenced by main().

◆ main()

◆ mixAudioFiles()

AudioFileResultType EOUtils::mixAudioFiles ( const std::vector< std::string > & pFilenames,
const std::string & pOutputFilename )

Mixes (merges) multiple audio files into a single file.

Parameters
[in]pFilenamesA collection of filenames of audio files to mix
[out]pOutputFilenameThe filename for the resulting mixed audio file
Returns
True on success, or false with error messages on failure

Referenced by main().

◆ parseCommandLine()

ProgOptions parseCommandLine ( int argc,
char * argv[] )

◆ readAudioFileList()

AudioFileMixOptions readAudioFileList ( const string & pFilename,
vector< string > & pErrorMsgs,
vector< string > & pNonexistentFiles )

◆ showProgramHelp()

void showProgramHelp ( )

Referenced by main(), and parseCommandLine().