3 * Definitions for colors
5 * Wireshark - Network traffic analyzer
6 * By Gerald Combs <gerald@wireshark.org>
7 * Copyright 1998 Gerald Combs
9 * SPDX-License-Identifier: GPL-2.0-or-later
16 #endif /* __cplusplus */
21 * Data structure holding RGB value for a color, 16 bits per channel.
30 * Convert a color_t to a 24-bit RGB value, reducing each channel to
31 * 8 bits and combining them.
33 inline static unsigned int
34 color_t_to_rgb(const color_t
*color
) {
35 return (((color
->red
>> 8) << 16)
36 | ((color
->green
>> 8) << 8)
37 | (color
->blue
>> 8));
42 #endif /* __cplusplus */
47 * Editor modelines - https://www.wireshark.org/tools/modelines.html
52 * indent-tabs-mode: nil
55 * vi: set shiftwidth=4 tabstop=8 expandtab:
56 * :indentSize=4:tabSize=8:noTabs=true: