xref: /aosp_15_r20/external/pigweed/pw_display/public/pw_display/colors_pico8.h (revision 61c4878ac05f98d0ceed94b57d316916de578985)
1 // Copyright 2024 The Pigweed Authors
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License"); you may not
4 // use this file except in compliance with the License. You may obtain a copy of
5 // the License at
6 //
7 //     https://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11 // WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12 // License for the specific language governing permissions and limitations under
13 // the License.
14 #pragma once
15 
16 #include "pw_display/color.h"
17 
18 namespace pw::display::colors::rgb565::pico8 {
19 
20 /// @defgroup pw_display_color_palette_pico8
21 /// Named colors for the Pico-8 palette.
22 /// @{
23 
24 // clang-format off
25 constexpr ColorRgb565 kBlack      = EncodeRgb565(0x00, 0x00, 0x00);
26 constexpr ColorRgb565 kDarkBlue   = EncodeRgb565(0x1d, 0x2b, 0x53);
27 constexpr ColorRgb565 kDarkPurple = EncodeRgb565(0x7e, 0x25, 0x53);
28 constexpr ColorRgb565 kDarkGreen  = EncodeRgb565(0x00, 0x87, 0x51);
29 constexpr ColorRgb565 kBrown      = EncodeRgb565(0xab, 0x52, 0x36);
30 constexpr ColorRgb565 kDarkGray   = EncodeRgb565(0x5f, 0x57, 0x4f);
31 constexpr ColorRgb565 kLightGray  = EncodeRgb565(0xc2, 0xc3, 0xc7);
32 constexpr ColorRgb565 kWhite      = EncodeRgb565(0xff, 0xf1, 0xe8);
33 constexpr ColorRgb565 kRed        = EncodeRgb565(0xff, 0x00, 0x4d);
34 constexpr ColorRgb565 kOrange     = EncodeRgb565(0xff, 0xa3, 0x00);
35 constexpr ColorRgb565 kYellow     = EncodeRgb565(0xff, 0xec, 0x27);
36 constexpr ColorRgb565 kGreen      = EncodeRgb565(0x00, 0xe4, 0x36);
37 constexpr ColorRgb565 kBlue       = EncodeRgb565(0x29, 0xad, 0xff);
38 constexpr ColorRgb565 kIndigo     = EncodeRgb565(0x83, 0x76, 0x9c);
39 constexpr ColorRgb565 kPink       = EncodeRgb565(0xff, 0x77, 0xa8);
40 constexpr ColorRgb565 kPeach      = EncodeRgb565(0xff, 0xcc, 0xaa);
41 // clang-format on
42 
43 /// @}
44 
45 }  // namespace pw::display::colors::rgb565::pico8
46