ICF 3.1.1.10
Technical documentation of ICF Libraries
CBitmapBase.h
Go to the documentation of this file.
1/********************************************************************************
2** This file is part of the ICF Framework. Copyright (C) Witold Gantzke & Kirill Lepskiy
3** ICF Framework may be used under the terms of the LGPL License v. 2.1 by the Free Software Foundation.
4********************************************************************************/
5
6#ifndef iimg_CBitmapBase_included
7#define iimg_CBitmapBase_included
8
9
10// ICF includes
11#include <i2d/CObject2dBase.h>
12#include <iimg/IBitmap.h>
13
14
15namespace iimg
16{
17
18
23 public i2d::CObject2dBase,
24 virtual public IBitmap
25{
26public:
28
29 virtual bool CreateImageFromRegion(const iimg::IBitmap& sourceBitmap, const i2d::CRect& region);
30
31 // reimplemented (i2d::IObject2d)
32 i2d::CVector2d GetCenter() const override;
33 void MoveCenterTo(const i2d::CVector2d& position) override;
35
36 // reimplemented (iimg::IBitmap)
37 int GetLineBytesCount() const override;
38 int GetComponentBitsCount(int componentIndex = 0) const override;
39
40 // reimplemented (iimg::IRasterImage)
41 bool IsEmpty() const override;
42 icmm::CVarColor GetColorAt(const istd::CIndex2d& position) const override;
43 bool SetColorAt(const istd::CIndex2d& position, const icmm::CVarColor& color) override;
44
45 // reimplemented (iser::ISerializable)
46 bool Serialize(iser::IArchive& archive) override;
47
48 // reimplemented (istd::IChangeable)
50};
51
52
53} // namespace iimg
54
55
56#endif // !iimg_CBitmapBase_included
57
58
Base class for 2D-objects implementing interface i2d::IObject2d.
Simple rectangle with integer bounds.
Definition CRect.h:26
Definition of rectangle area orthogonal to axis of coordination system.
Definition CRectangle.h:31
Definition of position or mathematical vector on 2D plane.
Definition CVector2d.h:29
Generic color implementation with variable number of color components.
Definition CVarColor.h:26
Base implementation of some iimg::IBitmap methods.
Definition CBitmapBase.h:25
icmm::CVarColor GetColorAt(const istd::CIndex2d &position) const override
Get color at specified pixel.
i2d::CRectangle GetBoundingBox() const override
Get bounding box of this shape.
int GetLineBytesCount() const override
Number of bytes per single line.
int GetComponentBitsCount(int componentIndex=0) const override
Get number of bits per single pixel component.
virtual bool CreateImageFromRegion(const iimg::IBitmap &sourceBitmap, const i2d::CRect &region)
i2d::CObject2dBase BaseClass
Definition CBitmapBase.h:27
bool SetColorAt(const istd::CIndex2d &position, const icmm::CVarColor &color) override
Set color at specified pixel.
bool IsEmpty() const override
Return true if this image is empty.
i2d::CVector2d GetCenter() const override
Returns center of this 2D-object.
bool Serialize(iser::IArchive &archive) override
Load or store state of this object as a archive stream.
void MoveCenterTo(const i2d::CVector2d &position) override
Move object to position position.
bool ResetData(CompatibilityMode mode=CM_WITHOUT_REFS) override
Reset data to its default state.
Definition of single plane bitmap.
Definition IBitmap.h:24
Represent input/output persistence archive.
Definition IArchive.h:34
Index implementation for addressing elements in 2D-space.
Definition CIndex2d.h:25
CompatibilityMode
Control how relationship betweeen objects are interpreted.
@ CM_WITHOUT_REFS
External references are simple ignored.
Contains the system indenendent definitions of image and related themes.
Definition CBitmap.h:21

© Witold Gantzke and Kirill Lepskiy