Mercurial > hg > camir-aes2014
comparison toolboxes/bioakustik_tools/visualisation/filespecgram.m @ 0:e9a9cd732c1e tip
first hg version after svn
author | wolffd |
---|---|
date | Tue, 10 Feb 2015 15:05:51 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:e9a9cd732c1e |
---|---|
1 function out=filespecgram(working_file, varargin) | |
2 | |
3 [starts,stops, unused]=process_options(varargin,'starts',0,'stops',-1); | |
4 | |
5 | |
6 filesize=wavread(working_file,'size'); | |
7 audiodatalen=filesize(1); | |
8 num_channels=filesize(2); | |
9 [src,sr,bits] = wavread(working_file,[1 2]); | |
10 | |
11 | |
12 startspl=max(1,starts*sr); | |
13 if stops =-1, | |
14 stopspl=audiodatalen; | |
15 else | |
16 stopspl=max(1,starts*sr); | |
17 end | |
18 | |
19 sgram=dataspecgram(src(startspl:stopspl,1),'sr',sr); |