summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--epost.lps202
-rw-r--r--epostunit.pas33
-rw-r--r--werteunit.pas16
3 files changed, 142 insertions, 109 deletions
diff --git a/epost.lps b/epost.lps
index 37019d5..b7e57ee 100644
--- a/epost.lps
+++ b/epost.lps
@@ -3,12 +3,13 @@
<ProjectSession>
<Version Value="10"/>
<BuildModes Active="Default"/>
- <Units Count="23">
+ <Units Count="24">
<Unit0>
<Filename Value="epost.lpr"/>
<IsPartOfProject Value="True"/>
- <TopLine Value="358"/>
- <CursorPos Y="392"/>
+ <IsVisibleTab Value="True"/>
+ <TopLine Value="164"/>
+ <CursorPos Y="182"/>
<UsageCount Value="202"/>
<Loaded Value="True"/>
</Unit0>
@@ -22,10 +23,9 @@
<Unit2>
<Filename Value="epostunit.pas"/>
<IsPartOfProject Value="True"/>
- <IsVisibleTab Value="True"/>
<EditorIndex Value="1"/>
- <TopLine Value="8717"/>
- <CursorPos X="133" Y="8739"/>
+ <TopLine Value="2759"/>
+ <CursorPos X="40" Y="2781"/>
<UsageCount Value="201"/>
<Loaded Value="True"/>
</Unit2>
@@ -39,18 +39,18 @@
<Unit4>
<Filename Value="werteunit.pas"/>
<IsPartOfProject Value="True"/>
- <EditorIndex Value="8"/>
- <TopLine Value="1996"/>
- <CursorPos X="64" Y="2016"/>
+ <EditorIndex Value="9"/>
+ <TopLine Value="890"/>
+ <CursorPos X="55" Y="924"/>
<UsageCount Value="200"/>
<Loaded Value="True"/>
</Unit4>
<Unit5>
<Filename Value="typenunit.pas"/>
<IsPartOfProject Value="True"/>
- <EditorIndex Value="11"/>
- <TopLine Value="909"/>
- <CursorPos X="34" Y="917"/>
+ <EditorIndex Value="12"/>
+ <TopLine Value="249"/>
+ <CursorPos X="71" Y="269"/>
<UsageCount Value="200"/>
<Loaded Value="True"/>
</Unit5>
@@ -75,7 +75,7 @@
<Unit8>
<Filename Value="gauszFit.inc"/>
<IsPartOfProject Value="True"/>
- <EditorIndex Value="10"/>
+ <EditorIndex Value="11"/>
<CursorPos X="35" Y="10"/>
<UsageCount Value="201"/>
<Loaded Value="True"/>
@@ -83,33 +83,33 @@
<Unit9>
<Filename Value="werteunit.inc"/>
<IsPartOfProject Value="True"/>
- <EditorIndex Value="9"/>
- <TopLine Value="407"/>
- <CursorPos X="114" Y="425"/>
- <UsageCount Value="119"/>
+ <EditorIndex Value="10"/>
+ <TopLine Value="14"/>
+ <CursorPos X="41" Y="32"/>
+ <UsageCount Value="125"/>
<Loaded Value="True"/>
</Unit9>
<Unit10>
<Filename Value="../units/mystringlistunit.pas"/>
- <EditorIndex Value="7"/>
- <TopLine Value="542"/>
- <CursorPos X="49" Y="566"/>
- <UsageCount Value="60"/>
+ <EditorIndex Value="8"/>
+ <TopLine Value="498"/>
+ <CursorPos X="85" Y="515"/>
+ <UsageCount Value="63"/>
<Loaded Value="True"/>
</Unit10>
<Unit11>
<Filename Value="../units/lowlevelunit.pas"/>
- <EditorIndex Value="6"/>
- <TopLine Value="4"/>
- <CursorPos X="52" Y="33"/>
+ <EditorIndex Value="7"/>
+ <TopLine Value="590"/>
+ <CursorPos X="17" Y="619"/>
<UsageCount Value="100"/>
<Loaded Value="True"/>
</Unit11>
<Unit12>
<Filename Value="../units/matheunit.pas"/>
<EditorIndex Value="5"/>
- <TopLine Value="172"/>
- <CursorPos X="54" Y="187"/>
+ <TopLine Value="112"/>
+ <CursorPos X="11" Y="141"/>
<UsageCount Value="101"/>
<Loaded Value="True"/>
</Unit12>
@@ -118,49 +118,49 @@
<EditorIndex Value="2"/>
<TopLine Value="126"/>
<CursorPos X="7" Y="147"/>
- <UsageCount Value="74"/>
+ <UsageCount Value="77"/>
<Loaded Value="True"/>
</Unit13>
<Unit14>
<Filename Value="/usr/lib/fpc/src/rtl/inc/objpash.inc"/>
<EditorIndex Value="-1"/>
- <TopLine Value="177"/>
+ <TopLine Value="176"/>
<CursorPos X="23" Y="194"/>
- <UsageCount Value="9"/>
+ <UsageCount Value="10"/>
</Unit14>
<Unit15>
<Filename Value="/usr/lib/fpc/src/rtl/unix/bunxovlh.inc"/>
<EditorIndex Value="-1"/>
<TopLine Value="61"/>
<CursorPos X="10" Y="99"/>
- <UsageCount Value="6"/>
+ <UsageCount Value="5"/>
</Unit15>
<Unit16>
<Filename Value="/usr/lib/fpc/src/rtl/unix/baseunix.pp"/>
<UnitName Value="BaseUnix"/>
<EditorIndex Value="-1"/>
<TopLine Value="61"/>
- <UsageCount Value="6"/>
+ <UsageCount Value="5"/>
</Unit16>
<Unit17>
<Filename Value="/usr/lib/fpc/src/rtl/unix/bunxovl.inc"/>
<EditorIndex Value="-1"/>
<TopLine Value="414"/>
<CursorPos X="20" Y="434"/>
- <UsageCount Value="6"/>
+ <UsageCount Value="5"/>
</Unit17>
<Unit18>
<Filename Value="/usr/lib/fpc/src/rtl/linux/bunxsysc.inc"/>
<EditorIndex Value="-1"/>
<TopLine Value="16"/>
- <UsageCount Value="6"/>
+ <UsageCount Value="5"/>
</Unit18>
<Unit19>
<Filename Value="/usr/lib/fpc/src/rtl/unix/bunxh.inc"/>
<EditorIndex Value="-1"/>
<TopLine Value="74"/>
<CursorPos X="15" Y="102"/>
- <UsageCount Value="6"/>
+ <UsageCount Value="5"/>
</Unit19>
<Unit20>
<Filename Value="/usr/lib/fpc/src/packages/fcl-image/src/fpimage.pp"/>
@@ -168,138 +168,152 @@
<EditorIndex Value="-1"/>
<TopLine Value="10"/>
<CursorPos X="3" Y="30"/>
- <UsageCount Value="6"/>
+ <UsageCount Value="5"/>
</Unit20>
<Unit21>
<Filename Value="/usr/lib/fpc/src/rtl/objpas/math.pp"/>
<EditorIndex Value="-1"/>
<TopLine Value="351"/>
<CursorPos X="10" Y="368"/>
- <UsageCount Value="7"/>
+ <UsageCount Value="6"/>
</Unit21>
<Unit22>
<Filename Value="GTIWebServerTestAggActionHandlerUnit.pas"/>
<EditorIndex Value="-1"/>
<TopLine Value="53"/>
<CursorPos X="49" Y="82"/>
- <UsageCount Value="7"/>
+ <UsageCount Value="6"/>
</Unit22>
+ <Unit23>
+ <Filename Value="../units/protokollunit.pas"/>
+ <EditorIndex Value="6"/>
+ <TopLine Value="87"/>
+ <CursorPos X="3" Y="18"/>
+ <UsageCount Value="12"/>
+ <Loaded Value="True"/>
+ </Unit23>
</Units>
- <JumpHistory Count="29" HistoryIndex="28">
+ <JumpHistory Count="30" HistoryIndex="29">
<Position1>
- <Filename Value="epostunit.pas"/>
- <Caret Line="6212" Column="102" TopLine="6199"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="196" Column="136" TopLine="175"/>
</Position1>
<Position2>
- <Filename Value="epostunit.pas"/>
- <Caret Line="6209" Column="29" TopLine="6195"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="100" Column="41" TopLine="82"/>
</Position2>
<Position3>
- <Filename Value="epostunit.pas"/>
- <Caret Line="4581" Column="70" TopLine="4570"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="33" Column="24" TopLine="15"/>
</Position3>
<Position4>
- <Filename Value="epostunit.pas"/>
- <Caret Line="174" Column="22" TopLine="158"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="76" Column="14" TopLine="47"/>
</Position4>
<Position5>
- <Filename Value="epostunit.pas"/>
- <Caret Line="4607" Column="22" TopLine="4590"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="90" Column="14" TopLine="61"/>
</Position5>
<Position6>
- <Filename Value="typenunit.pas"/>
- <Caret Line="449" Column="38" TopLine="432"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="100" Column="27" TopLine="71"/>
</Position6>
<Position7>
- <Filename Value="typenunit.pas"/>
- <Caret Line="2488" Column="39" TopLine="2474"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="206" Column="45" TopLine="186"/>
</Position7>
<Position8>
- <Filename Value="typenunit.pas"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="260" Column="53" TopLine="228"/>
</Position8>
<Position9>
- <Filename Value="typenunit.pas"/>
- <Caret Line="450" Column="38" TopLine="429"/>
+ <Filename Value="epostunit.pas"/>
+ <Caret Line="157" Column="30" TopLine="140"/>
</Position9>
<Position10>
- <Filename Value="typenunit.pas"/>
- <Caret Line="2482" Column="39" TopLine="2471"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="250" Column="93" TopLine="228"/>
</Position10>
<Position11>
- <Filename Value="epostunit.pas"/>
- <Caret Line="4607" Column="22" TopLine="4590"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="397" Column="34" TopLine="368"/>
</Position11>
<Position12>
- <Filename Value="epostunit.pas"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="414" TopLine="391"/>
</Position12>
<Position13>
- <Filename Value="epostunit.pas"/>
- <Caret Line="1351" Column="57" TopLine="1323"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="182" TopLine="158"/>
</Position13>
<Position14>
- <Filename Value="epostunit.pas"/>
- <Caret Line="1807" Column="52" TopLine="1790"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="98" Column="39" TopLine="83"/>
</Position14>
<Position15>
- <Filename Value="typenunit.pas"/>
- <Caret Line="91" Column="23" TopLine="73"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="170" Column="28" TopLine="162"/>
</Position15>
<Position16>
- <Filename Value="typenunit.pas"/>
- <Caret Line="90" TopLine="73"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="256" TopLine="229"/>
</Position16>
<Position17>
- <Filename Value="typenunit.pas"/>
- <Caret Line="73" Column="4" TopLine="58"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="397" Column="34" TopLine="368"/>
</Position17>
<Position18>
- <Filename Value="typenunit.pas"/>
- <Caret Line="31" Column="23" TopLine="13"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="414" Column="80" TopLine="391"/>
</Position18>
<Position19>
- <Filename Value="typenunit.pas"/>
- <Caret Line="76" Column="16" TopLine="55"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="183" TopLine="158"/>
</Position19>
<Position20>
- <Filename Value="typenunit.pas"/>
- <Caret Line="73" Column="23" TopLine="55"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="370" Column="113" TopLine="363"/>
</Position20>
<Position21>
- <Filename Value="typenunit.pas"/>
- <Caret Line="132" Column="44" TopLine="104"/>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="437" Column="32" TopLine="409"/>
</Position21>
<Position22>
- <Filename Value="typenunit.pas"/>
- <Caret Line="868" Column="62" TopLine="838"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="99" Column="35" TopLine="78"/>
</Position22>
<Position23>
- <Filename Value="typenunit.pas"/>
- <Caret Line="891" Column="20" TopLine="857"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="27" Column="17" TopLine="9"/>
</Position23>
<Position24>
- <Filename Value="epostunit.pas"/>
- <Caret Line="1807" Column="52" TopLine="1790"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="26" Column="18" TopLine="9"/>
</Position24>
<Position25>
- <Filename Value="epostunit.pas"/>
- <Caret Line="1806" Column="46" TopLine="1787"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="27" Column="18" TopLine="9"/>
</Position25>
<Position26>
- <Filename Value="typenunit.pas"/>
- <Caret Line="73" Column="23" TopLine="55"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="73" Column="6" TopLine="44"/>
</Position26>
<Position27>
- <Filename Value="typenunit.pas"/>
- <Caret Line="128" Column="44" TopLine="100"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="88" Column="8" TopLine="59"/>
</Position27>
<Position28>
- <Filename Value="typenunit.pas"/>
- <Caret Line="927" Column="17" TopLine="909"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="99" Column="21" TopLine="70"/>
</Position28>
<Position29>
- <Filename Value="epostunit.pas"/>
- <Caret Line="1855" Column="57" TopLine="1838"/>
+ <Filename Value="../units/matheunit.pas"/>
+ <Caret Line="124" Column="27" TopLine="95"/>
</Position29>
+ <Position30>
+ <Filename Value="epost.lpr"/>
+ <Caret Line="184" Column="67" TopLine="164"/>
+ </Position30>
</JumpHistory>
</ProjectSession>
<Debugging>
diff --git a/epostunit.pas b/epostunit.pas
index b5c2be2..8df3e7a 100644
--- a/epostunit.pas
+++ b/epostunit.pas
@@ -187,7 +187,7 @@ type
procedure verschiebe(threads: longint; richtung: tInt64Point);
procedure ermittlePhasenWinkel(threads: longint);
procedure fft2dNachbearbeitung(threads: longint; nB: tFFTDatenordnung);
- procedure schreibeWert(var f: textfile; p: tExtPoint; var letzterWert: extended; entspringen: extended); inline;
+ procedure schreibeWert(var f: textfile; p: tExtPoint; var letzterWert: extended; entspringen: extended; skalierung: string); inline;
function exprToFloat(sT: boolean; s: string): extended;
function findeMaximum(sT: boolean; f: tMyStringList; threads: longint; warn: tWarnStufe): boolean;
function paramsDump: string;
@@ -5751,7 +5751,7 @@ end;
function tWerte.erzeugeLineout(sT: boolean; f: tMyStringList): boolean;
var
ab: t2x2Extended;
- datei,s: string;
+ datei,s,skalierung: string;
fOut: textfile;
bekannteBefehle: tMyStringList;
Zeit,entspringen,letzterWert: extended;
@@ -5769,6 +5769,7 @@ begin
ab['x']:=extPoint(0,0);
ab['y']:=extPoint(_xSteps-1,_tSiz-1);
+ skalierung:='1';
datei:='';
integriere:=false;
iWaag:=false;
@@ -5786,6 +5787,14 @@ begin
datei:=s;
continue;
end;
+ if istDasBefehl('Skalierung:',s,bekannteBefehle,true) then begin
+ if skalierung<>'1' then begin
+ gibAus('Ich soll den Lineout bereits mittels '''+skalierung+''' skalieren!',3);
+ exit;
+ end;
+ skalierung:=s;
+ continue;
+ end;
if istDasBefehl('integriere waagerecht',s,bekannteBefehle,false) then begin
if integriere then begin
gibAus('Ich kann bei einem Lineout nur in einer Richtung integrieren!',3);
@@ -5832,6 +5841,11 @@ begin
exit;
end;
+ if (skalierung<>'1') and integriere then begin
+ gibAus('Ich kann einen Lineout (noch) nicht gleichzeitig skalieren und integrieren!',3);
+ exit;
+ end;
+
if not sT then begin
assignFile(fOut,datei);
rewrite(fOut);
@@ -5872,8 +5886,11 @@ begin
exit;
end;
if not sT then
- for i:=0 to schritte do
- schreibeWert(fOut,ab['x']+(i/schritte)*(ab['y']-ab['x']),letzterWert,entspringen);
+ for i:=0 to schritte do begin
+ knownValues.add('x',ab['x','x']+(i/schritte)*(ab['y','x']-ab['x','x']));
+ knownValues.add('y',ab['x','y']+(i/schritte)*(ab['y','y']-ab['x','y']));
+ schreibeWert(fOut,ab['x']+(i/schritte)*(ab['y']-ab['x']),letzterWert,entspringen,skalierung);
+ end;
end;
if not sT then begin
closeFile(fOut);
@@ -5923,12 +5940,12 @@ begin
result:=true;
end;
-procedure tWerte.schreibeWert(var f: textfile; p: tExtPoint; var letzterWert: extended; entspringen: extended);
+procedure tWerte.schreibeWert(var f: textfile; p: tExtPoint; var letzterWert: extended; entspringen: extended; skalierung: string);
begin
case genauigkeit of
- gSingle: sWerte.schreibeWert(f,round(p['x']),round(p['y']),disk2kont(p),letzterWert,entspringen);
- gDouble: dWerte.schreibeWert(f,round(p['x']),round(p['y']),disk2kont(p),letzterWert,entspringen);
- gExtended: eWerte.schreibeWert(f,round(p['x']),round(p['y']),disk2kont(p),letzterWert,entspringen);
+ gSingle: sWerte.schreibeWert(f,round(p['x']),round(p['y']),disk2kont(p),letzterWert,entspringen,skalierung,knownValues,@callBackGetValue);
+ gDouble: dWerte.schreibeWert(f,round(p['x']),round(p['y']),disk2kont(p),letzterWert,entspringen,skalierung,knownValues,@callBackGetValue);
+ gExtended: eWerte.schreibeWert(f,round(p['x']),round(p['y']),disk2kont(p),letzterWert,entspringen,skalierung,knownValues,@callBackGetValue);
end{of Case};
end;
diff --git a/werteunit.pas b/werteunit.pas
index f400737..fdbad97 100644
--- a/werteunit.pas
+++ b/werteunit.pas
@@ -59,8 +59,8 @@ type
procedure fft2dNachbearbeitungB(xMin,xMax: longint; nB: tFFTDatenordnung);
procedure fft2dNachbearbeitungVerdoppeln(nB: tFFTDatenordnung);
procedure fft2dNachbearbeitungKomplex(xMin,xMax: longint; nB: tFFTDatenordnung);
- procedure schreibeWert(var f: textfile; x,y: longint; beschriftung: tExtPoint; var letzterWert: extended; entspringen: extended); overload; inline;
- procedure schreibeWert(var f: textfile; xBeschr,yBeschr,wert: extended); overload; inline;
+ procedure schreibeWert(var f: textfile; x,y: longint; beschriftung: tExtPoint; var letzterWert: extended; entspringen: extended; skalierung: string; kvs: tKnownValues; cbgv: tCallBackGetValue); overload; inline;
+ procedure schreibeWert(var f: textfile; xBeschr,yBeschr,wert: extended; skalierung: string; kvs: tKnownValues; cbgv: tCallBackGetValue); overload; inline;
procedure schreibeWertIntegriert(var f: textfile; i: longint; hor: boolean; var letzterWert: extended; entspringen: extended);
procedure erzeugeBinning(senkrecht,linien: boolean; x0,dx: extended; s: string);
procedure holeRAM; inline; overload;
@@ -871,7 +871,7 @@ begin
result:=not (in0 or out0);
end;
-procedure tLLWerte.schreibeWert(var f: textfile; x,y: longint; beschriftung: tExtPoint; var letzterWert: extended; entspringen: extended);
+procedure tLLWerte.schreibeWert(var f: textfile; x,y: longint; beschriftung: tExtPoint; var letzterWert: extended; entspringen: extended; skalierung: string; kvs: tKnownValues; cbgv: tCallBackGetValue);
var
tmp: extended;
begin
@@ -885,11 +885,13 @@ begin
tmp:=tmp+entspringen;
end;
letzterWert:=tmp;
- schreibeWert(f,beschriftung['x'],beschriftung['y'],tmp);
+ schreibeWert(f,beschriftung['x'],beschriftung['y'],tmp,skalierung,kvs,cbgv);
end;
-procedure tLLWerte.schreibeWert(var f: textfile; xBeschr,yBeschr,wert: extended);
+procedure tLLWerte.schreibeWert(var f: textfile; xBeschr,yBeschr,wert: extended; skalierung: string; kvs: tKnownValues; cbgv: tCallBackGetValue);
begin
+ if skalierung<>'1' then
+ wert:=wert*exprToFloat(false,skalierung,kvs,cbgv);
writeln(f,myFloatToStr(xBeschr)+' '+myFloatToStr(yBeschr)+' '+myFloatToStr(wert));
end;
@@ -917,9 +919,9 @@ begin
end;
letzterWert:=tmp;
if hor then
- schreibeWert(f,(params.xSteps-1)/2,i,tmp)
+ schreibeWert(f,(params.xSteps-1)/2,i,tmp,'1',nil,nil)
else
- schreibeWert(f,i,(params.tSiz-1)/2,tmp);
+ schreibeWert(f,i,(params.tSiz-1)/2,tmp,'1',nil,nil);
end;
procedure tLLWerte.erzeugeBinning(senkrecht,linien: boolean; x0,dx: extended; s: string);