1 | // Aseprite |
2 | // Copyright (C) 2001-2017 David Capello |
3 | // |
4 | // This program is distributed under the terms of |
5 | // the End-User License Agreement for Aseprite. |
6 | |
7 | #ifndef FILTERS_FILTER_INDEXED_DATA_H_INCLUDED |
8 | #define FILTERS_FILTER_INDEXED_DATA_H_INCLUDED |
9 | #pragma once |
10 | |
11 | namespace doc { |
12 | class Palette; |
13 | class PalettePicks; |
14 | class RgbMap; |
15 | } |
16 | |
17 | namespace filters { |
18 | |
19 | // Provides a Palette and a RgbMap to help a Filter which operate |
20 | // over an indexed image. |
21 | class FilterIndexedData { |
22 | public: |
23 | virtual ~FilterIndexedData() { } |
24 | virtual const doc::Palette* getPalette() const = 0; |
25 | virtual const doc::RgbMap* getRgbMap() const = 0; |
26 | |
27 | // If a filter ask for a new palette, it means that the filter |
28 | // will modify the palette instead of pixels. |
29 | virtual doc::Palette* getNewPalette() = 0; |
30 | |
31 | // Get the selected palettes to be modified by a palette filter |
32 | // (e.g. HueSaturationFilter). |
33 | virtual doc::PalettePicks getPalettePicks() = 0; |
34 | }; |
35 | |
36 | } // namespace filters |
37 | |
38 | #endif |
39 | |