123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- function [azi,ele] = filename2azel(filename)
- %rechnet den Dateinamen in Azimut und Elevation um
- ele=[];
- azi=[];
- if findstr(filename,'erg.')
- start=length(filename)-7;
- else
- start=length(filename)-4;
- end
- for (counter=start:-1:1)
- letter=filename(counter);
- if letter=='N'
- negativele=1;
- break
- end
- if letter=='P'
- negativele=0;
- break;
- end
- ele=[letter ele ];
-
- %disp(letter);
- end
- ele=str2num(ele);
- if (negativele==1)
- ele=ele*(-1);
- end
- for (counter2=(counter-1):-1:1)
- letter=filename(counter2);
- if letter=='N'
- negativazi=1;
- break
- end
- if letter=='P'
- negativazi=0;
- break;
- end
- azi=[letter azi ];
- end
- azi=str2num(azi);
- if (negativazi==1)
- azi=azi*(-1);
- end
|