#ifndef MP3TOWAV
#define MP3TOWAV

/*
 * @(#)MP3ToWAV.h
 *
 * This file is part of webCDwriter - Network CD Writing.
 *
 * Copyright (C) 2000-2003 Jörg P. M. Haeger
 *
 * webCDwriter is free software. See CDWserver.cpp for details.
 */

#include "AudioToWAV.h"

/**
 * Convert MP3 files to WAV.
 *
 * @version 20030204
 * @author Jörg P. M. Haeger
 */
class MP3ToWAV: public AudioToWAV {
public:
	MP3ToWAV(FILE *inStream = NULL): AudioToWAV(inStream) {
		converter = new Process(config.getActiveValue("mpg123Path"));
		converter->addArg("-q");
		converter->addArg("-r");
		converter->addArg("44100");
		converter->addArg("-s");
		converter->addArg("--stereo");
		converter->addArg("-");
		converter->start(NULL, 1);
	}
};

#endif
