{"id":25990110,"url":"https://github.com/gautamthampy/color-detection","last_synced_at":"2026-04-10T12:05:26.649Z","repository":{"id":246630774,"uuid":"391187229","full_name":"gautamthampy/color-detection","owner":"gautamthampy","description":"Provides colour names and HTML/RGB mappings in various output formats.","archived":false,"fork":false,"pushed_at":"2021-07-30T21:44:36.000Z","size":360,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-03T22:11:37.071Z","etag":null,"topics":["c","numpy","opencv","python"],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gautamthampy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-07-30T21:02:44.000Z","updated_at":"2021-07-30T21:44:38.000Z","dependencies_parsed_at":"2024-06-29T08:37:44.660Z","dependency_job_id":"f0b6247f-14de-404e-9c31-167dab217152","html_url":"https://github.com/gautamthampy/color-detection","commit_stats":null,"previous_names":["gautamthampy/color-detection"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/gautamthampy/color-detection","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gautamthampy%2Fcolor-detection","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gautamthampy%2Fcolor-detection/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gautamthampy%2Fcolor-detection/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gautamthampy%2Fcolor-detection/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gautamthampy","download_url":"https://codeload.github.com/gautamthampy/color-detection/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gautamthampy%2Fcolor-detection/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31641493,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-10T07:40:12.752Z","status":"ssl_error","status_checked_at":"2026-04-10T07:40:11.664Z","response_time":98,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","numpy","opencv","python"],"created_at":"2025-03-05T13:32:28.295Z","updated_at":"2026-04-10T12:05:26.623Z","avatar_url":"https://github.com/gautamthampy.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"Color Names\n===========\n\nThese files are generated using a script which parses the list of colors\non Wikipedia, here:\n\n  http://en.wikipedia.org/wiki/List_of_colors\n\nThe script used is written in Python and depends heavily on the\ninput format from Wikipedia. The script is named `format-colors` and can be found in the\nsame directory as the data files.\n\nThere's a GNU Make file called `makefile` that just re-generates the data\nfiles when the input file is updated or the script is changed. You probably\ndon't need this file at all.\n\nThere are various output formats, explained below.\n\nC Code\n------\n\nFor use in programs in the C programming language. It contains an enum like:\n\n```c\ntypedef enum Color {\n  ...\n  COLOR_RED,\n  ...\n};\n```\n\nAnd then an array of `ColorInfo` structures where the `COLOR_` enumerators\nindex into the array. It looks like:\n\n```c\nColorInfo color_data[COLOR_NAMES_MAX] = {\n  ...\n  { \"Red\", \"#f00\", { 255, 0, 0 } },\n  ...\n};\n```\n\nSo if you wanted to look up the colour red, you'd do something like this:\n\n```c\nconst ColorInfo *clrinf = \u0026color_data[COLOR_RED];\nprintf(\"Color Name: %s\\n\", clrinf-\u003ename);\nprintf(\"Color Hex: %s\\n\", clrinf-\u003ehex);\nprintf(\"Color RGB: (%d, %d, %d)\\n\",\n  clrinf-\u003ergb.r, clrinf-\u003ergb.g, clrinf-\u003ergb.b);\n```\n\nConf\n----\n\nSimilar to Windows `.ini` files or GKeyFiles (GLIB). For example:\n\n```ini\n...\n[red]\nname=Red\nhex=#f00\nrgb=255;0;0\n...\n```\n\nCSV\n---\n\nComma separated values for example to import into a spreadsheet utility.\nLooks like:\n\n```csv\n...\nred,\"Red\",#f00,255,0,0\n...\n```\n\nHTML\n----\n\nThe HTML format is meant to be viewed in your browser as a \"catalog\" of the\ncolors. It closely resembes the Wikipedia colour list page.\n\nUse the \"View Source\" feature in your browser to examine the format.\n\nJSON\n----\n\nJavaScript Object Notation, looks like a JS or Python data structure, for\nexample:\n\n```js\n{\n  ...\n  \"red\": {\n    \"name\": \"Red\",\n    \"hex\": \"#f00\",\n    \"rgb\": [255, 0, 0]\n  }\n  ...\n}\n```\n\nS-Expressions\n-------------\n\nS-Expression, which might be useful for Lisp or other languages, for example:\n\n```lisp\n(\n  ...\n  (red 'Red' '#f00' (255 0 0))\n  ...\n)\n```\n\nXML\n---\n\nGood ol' XML format, for example:\n\n```xml\n\u003ccolors\u003e\n  ...\n  \u003ccolor id=\"red\" hex=\"#f00\" red=\"255\" green=\"0\" blue=\"0\"\u003eRed\u003c/color\u003e\n  ...\n\u003c/colors\u003e\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgautamthampy%2Fcolor-detection","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgautamthampy%2Fcolor-detection","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgautamthampy%2Fcolor-detection/lists"}