001/******************************************************************************* 002 * This software is provided as a supplement to the authors' textbooks on digital 003 * image processing published by Springer-Verlag in various languages and editions. 004 * Permission to use and distribute this software is granted under the BSD 2-Clause 005 * "Simplified" License (see http://opensource.org/licenses/BSD-2-Clause). 006 * Copyright (c) 2006-2023 Wilhelm Burger, Mark J. Burge. All rights reserved. 007 * Visit https://imagingbook.com for additional details. 008 ******************************************************************************/ 009 010package imagingbook.common.mser; 011 012import imagingbook.common.color.sets.ColorEnumeration; 013 014import java.awt.Color; 015 016import static imagingbook.common.color.sets.ColorEnumeration.getColors; 017 018/** 019 * Color definitions used in MSER demo plugins. 020 * 021 * @author WB 022 * @version 2022/11/19 023 */ 024public enum MserColors implements ColorEnumeration { 025 Red(240, 0, 0), 026 Green(0, 185, 15), 027 Blue(0, 60, 255), 028 Magenta(255, 0, 200), 029 Brown(160, 82, 45), 030 Yellow(255, 200, 0), 031 Orange(255, 182, 86), 032 Cyan(0, 198, 255), 033 ; 034 035 public static final Color[] LevelColors = 036 getColors(Red, Green, Blue, Magenta); 037 038 private final Color color; 039 040 MserColors(int r, int g, int b) { 041 this.color = new Color(r, g, b); 042 } 043 044 @Override 045 public Color getColor() { 046 return this.color; 047 } 048 049}