-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsnom-dsp.h
More file actions
86 lines (64 loc) · 3.16 KB
/
snom-dsp.h
File metadata and controls
86 lines (64 loc) · 3.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
// Routinen und #defines für SNOM_WRK.C
//#include <wingdi.h>
#include <windows.h>
// XXX Workaround: Old GCCs choke on type check.
#if defined __cplusplus
extern C {
#endif
// Sendet an alle Childs ein Redraw
#define UPDATE 1
#define CLEAR3D 2
#define SLIDER 4
BOOL RedrawAll( WORD flags );
BOOL PointInRect( CONST RECT *lprc, POINT pt );
// Includes border!
BOOLEAN WriteDib( LPSTR szFileName, LPBITMAPINFO lpDib, LPBYTE lpDaten );
// The ONLY way to copy into Metafile!!!
void CopyDibToDC( HDC hDC, LPBITMAPINFO pDib, LPBYTE pDest, RECT xywh );
// Ende Draw3D
// April 97
// "Schnelle Integeroutinen": 28.12.97
// Berechnet die neue Bitmapfarben (nur für Recalc-Cache)
WORD FarbenSetzen( LPBITMAPINFO pCacheDib, LPBILD pBild, LONG startcol, LONG max, double maxcol, BOOL StartEnde );
// Ermittelt Offset der Daten vom Start
LONG GetDibBitsAddr (LPBITMAPINFO lpDib);
// Kopiert die Farbewerte aus der Palette
WORD GetDibPalette ( LPLOGPALETTE palette, LPBITMAPINFO lpDib);
//**** Erzeugt neue Farbpalette, inklusive 2-Farbeverlauf und "Totfarben" ****
BOOL SetDibPaletteColors( LPBITMAPINFO pDib, COLORREF HUGE *Farbe, LPBILD pBild, LONG StartFarbe, LONG EndFarbe, WORD ClipStart, WORD ClipEnde );
// Berechnet die "zweckmaessigste Einheit, d.h die nachste durch 1, 2, 2,5, 5 teilbare Zahl,
// die am ehesten zwischen min und max Anzahl von Strichen erzeugt ...
double CalcIncrement( int min, int max, double len );
// 18.8.97
// Berechnet Ausmaße einer Bitmap mit Legende, 3D ...
void CalcDibSize( HDC hdc, LONG cxDib, LONG cyDib, LPRECT pCoord, BOOL Show3D, BOOL ShowScanline );
// Zeichnet eine Bitmap neu
BOOL RecalcCache( LPBMPDATA pBmp, BOOL AuchBitmapNeuBerechnen, BOOL AlleFarbenMitOffset );
// Zeichnet eine Bitmap in DC
BOOL DrawInDC( HDC hdc, LPBMPDATA pBmp, BOOL AuchBitmapNeuBerechnen, BOOL AlleFarbenMitOffset, double fZoom, RECT *BitmapExtend );
/**** Kopiert die Daten einer Querschnittslinie nach puDest ****/
/**** Das sind maximal (w^2+h^2)^.5+1 Punkte ****/
/**** Wenn bNurX TRUE, gibt es als Ergebnis die X-Werte, ****
**** wenn bNurY TRUE, gibt es nur die Y-Werte, sonst die Daten ****/
int BildGetLine( LPUWORD puDest, LPUWORD puDaten, LPRECT pRect, LONG w, LONG h, BOOLEAN bNurX, BOOLEAN bNurY );
// 18.2.98, 20.12.98
// Malt die Markierungslinie neu (in Topografie UND Lumineszens, wenn vorhanden)
void DrawScanLine( HDC hdc, LPBMPDATA pBmp, double fScale );
// 6.8.97
// Scanline im "Koordinatensystem" zeichnen
void DrawScanLinePlot( HDC hdc, LPBMPDATA pBmp, double fScale, BOOLEAN bWhiteOut );
// 22.11.97
// Quantenpunkte im "Koordinatensystem" zeichnen
void DrawDotsPlot( HDC hdc, LPBMPDATA pBmp, double fScale );
// 21.11.11
// BSF zeichnen
void DrawLinesPlot( HDC hdc, LPBMPDATA pBmp, double fScale );
// 18.3.20
// Stellt die aktuelle Dib im Cache dar
void DisplayDib( HDC hdc, LPBITMAPINFO lpDib, HWND TopHwnd, LPRECT pCoord, WORD wZoom, LPUCHAR lpDibBits );
// 27.7.97
// Malt eine waagerechte Achse
void DrawHorizontalAxis( HDC hDC, int x, int y, int weite, int min, int max, double MaxWeite, double offset, const char *label, const char *alt_label );
#if defined __cplusplus
};
#endif