本文整理汇总了Java中javazoom.jl.decoder.OutputChannels类的典型用法代码示例。如果您正苦于以下问题:Java OutputChannels类的具体用法?Java OutputChannels怎么用?Java OutputChannels使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
OutputChannels类属于javazoom.jl.decoder包,在下文中一共展示了OutputChannels类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: jlcArgs
import javazoom.jl.decoder.OutputChannels; //导入依赖的package包/类
public jlcArgs()
{
which_c = OutputChannels.BOTH_CHANNELS;
use_own_scalefactor = false;
scalefactor = (float) 32768.0;
//stdout_mode = false;
verbose_mode = false;
}
示例2: jlcArgs
import javazoom.jl.decoder.OutputChannels; //导入依赖的package包/类
public jlcArgs()
{
which_c = OutputChannels.BOTH_CHANNELS;
use_own_scalefactor = false;
scalefactor = (float) 32768.0;
//stdout_mode = false;
verbose_mode = false;
}
示例3: processArgs
import javazoom.jl.decoder.OutputChannels; //导入依赖的package包/类
/**
* Process user arguments.
*
* Returns true if successful.
*/
public boolean processArgs(String[] argv)
{
filename = null;
Crc16[] crc;
crc = new Crc16[1];
int i;
int argc = argv.length;
//stdout_mode = false;
verbose_mode = false;
output_mode = OutputChannels.BOTH_CHANNELS;
output_filename = "";
if (argc < 2 || argv[1].equals("-h"))
return Usage();
i = 1;
while (i < argc)
{
/* System.out.println("Option = "+argv[i]);*/
if (argv[i].charAt(0) == '-')
{
if (argv[i].startsWith("-v"))
{
verbose_mode = true;
if (argv[i].length()>2)
{
try
{
String level = argv[i].substring(2);
verbose_level = Integer.parseInt(level);
}
catch (NumberFormatException ex)
{
System.err.println("Invalid verbose level. Using default.");
}
}
System.out.println("Verbose Activated (level "+verbose_level+")");
}
/* else if (argv[i].equals("-s"))
ma.stdout_mode = true; */
else if (argv[i].equals("-p"))
{
if (++i == argc)
{
System.out.println("Please specify an output filename after the -p option!");
System.exit (1);
}
//output_mode = O_WAVEFILE;
output_filename = argv[i];
}
/*else if (argv[i].equals("-f"))
{
if (++i == argc)
{
System.out.println("Please specify a new scalefactor after the -f option!");
System.exit(1);
}
ma.use_own_scalefactor = true;
// ma.scalefactor = argv[i];
}*/
else return Usage();
}
else
{
filename = argv[i];
System.out.println("FileName = "+argv[i]);
if (filename == null) return Usage();
}
i++;
}
if (filename == null)
return Usage();
return true;
}
示例4: processArgs
import javazoom.jl.decoder.OutputChannels; //导入依赖的package包/类
/**
* Process user arguments.
*
* Returns true if successful.
*/
public boolean processArgs(String[] argv)
{
filename = null;
Crc16[] crc;
crc = new Crc16[1];
int i;
int argc = argv.length;
//stdout_mode = false;
verbose_mode = false;
output_mode = OutputChannels.BOTH_CHANNELS;
output_filename = "";
if (argc < 2 || argv[1].equals("-h"))
return Usage();
i = 1;
while (i < argc)
{
/* System.out.println("Option = "+argv[i]);*/
if (argv[i].charAt(0) == '-')
{
if (argv[i].startsWith("-v"))
{
verbose_mode = true;
if (argv[i].length() > 2)
{
try
{
String level = argv[i].substring(2);
verbose_level = Integer.parseInt(level);
} catch (NumberFormatException ex)
{
System.err.println("Invalid verbose level. Using default.");
}
}
System.out.println("Verbose Activated (level " + verbose_level + ")");
}
/* else if (argv[i].equals("-s"))
ma.stdout_mode = true; */
else if (argv[i].equals("-p"))
{
if (++i == argc)
{
System.out.println("Please specify an output filename after the -p option!");
System.exit(1);
}
//output_mode = O_WAVEFILE;
output_filename = argv[i];
}
/*else if (argv[i].equals("-f"))
{
if (++i == argc)
{
System.out.println("Please specify a new scalefactor after the -f option!");
System.exit(1);
}
ma.use_own_scalefactor = true;
// ma.scalefactor = argv[i];
}*/
else
return Usage();
}
else
{
filename = argv[i];
System.out.println("FileName = " + argv[i]);
if (filename == null)
return Usage();
}
i++;
}
if (filename == null)
return Usage();
return true;
}