OpendTect  6.3
bitmapmgr.h
Go to the documentation of this file.
1 #pragma once
2 /*+
3 ________________________________________________________________________
4 
5  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
6  Author: Bert
7  Date: Feb 2007
8 ________________________________________________________________________
9 
10 -*/
11 
12 #include "generalmod.h"
13 
14 #include "array2dbitmap.h"
15 #include "datapack.h"
16 #include "geometry.h"
17 
18 namespace FlatView { class Appearance; }
19 class FlatDataPack;
20 
26 {
27 public:
28  BitMapMgr();
29  ~BitMapMgr();
30 
31  void init(const FlatDataPack*,const FlatView::Appearance&,
32  bool wva);
33  void clearAll();
34 
36  const Geom::Size2D<int>&) const;
38 
39  bool generate(const Geom::PosRectangle<double>& wr,
40  const Geom::Size2D<int>& bufwrsz,
41  const Geom::Size2D<int>& availpixels);
43  const A2DBitMap* bitMap() const { return bmp_; }
44  const A2DBitMapGenerator* bitMapGen() const { return gen_; }
45  A2DBitMapGenerator* bitMapGen() { return gen_; }
46 
47 private:
48 
49  void setup();
50 
58  bool wva_;
59 
62 };
63 
64 
69 mExpClass(General) BitMapGenTask : public Task
70 {
71 public:
74  const Geom::Size2D<int>& bufwrsz,
75  const Geom::Size2D<int>& pix )
76  : mgr_(mgr), wr_(wr), bufwrsz_(bufwrsz), availpixels_(pix){}
77 
78  bool execute() { return mgr_.generate(wr_,bufwrsz_,availpixels_); }
79 
80 protected:
81 
86 };
#define mExpClass(module)
Definition: commondefs.h:157
A2DBitMap * bmp_
Definition: bitmapmgr.h:54
BitMapMgr & mgr_
Definition: bitmapmgr.h:82
A lock of a type that (hopefully) suits your needs. To use it, you need the Locker class...
Definition: threadlock.h:51
const Geom::Size2D< int > & availpixels_
Definition: bitmapmgr.h:85
const A2DBitMapGenerator * bitMapGen() const
Definition: bitmapmgr.h:44
bool init()
Geom::PosRectangle< double > wr_
Definition: bitmapmgr.h:61
Array2D Bitmap generation setup.
Definition: array2dbitmap.h:109
const Geom::Size2D< int > & bufwrsz_
Definition: bitmapmgr.h:84
Bitmap generation Task.
Definition: bitmapmgr.h:69
A2DBitMapGenerator * gen_
Definition: bitmapmgr.h:57
ConstRefMan< FlatDataPack > datapack_
Definition: bitmapmgr.h:52
A2DBitMapGenerator * bitMapGen()
Definition: bitmapmgr.h:45
Array2D<float>& + statistics.
Definition: array2dbitmap.h:53
bool execute()
Definition: bitmapmgr.h:78
BitMapGenTask(BitMapMgr &mgr, const Geom::PosRectangle< double > &wr, const Geom::Size2D< int > &bufwrsz, const Geom::Size2D< int > &pix)
Definition: bitmapmgr.h:72
const Geom::PosRectangle< double > & wr_
Definition: bitmapmgr.h:83
bool wva_
Definition: bitmapmgr.h:58
Geom::Size2D< int > sz_
Definition: bitmapmgr.h:60
A2DBitMapPosSetup * pos_
Definition: bitmapmgr.h:55
const A2DBitMap * bitMap() const
Definition: bitmapmgr.h:43
FlatView::Appearance & appearance_
Definition: bitmapmgr.h:53
Manages bitmaps.
Definition: bitmapmgr.h:25
DataPack for flat data.
Definition: datapackbase.h:61
Flatviewer appearance.
Definition: flatview.h:276
A2DBitMapInpData * data_
Definition: bitmapmgr.h:56
Definition: bitmap2rgb.h:15
Generalization of something (e.g. a computation) that needs to be done in multiple steps...
Definition: task.h:26
Threads::Lock lock_
Definition: bitmapmgr.h:51
Generates Array2D bitmap from Array2D<float>.
Definition: array2dbitmap.h:178

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B. V. 2017