AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Programmierung allgemein Multimedia Delphi How to draw color circle?

How to draw color circle?

Ein Thema von WojTec · begonnen am 12. Mär 2012 · letzter Beitrag vom 12. Mär 2012
Antwort Antwort
WojTec

Registriert seit: 17. Mai 2007
480 Beiträge
 
Delphi XE6 Professional
 
#1

How to draw color circle?

  Alt 12. Mär 2012, 14:48
I want to draw circles like in attachment (RGB and RYB). I want to only know how to draw circle filled with some colors spectrum, routine for RYB values I already have.
Miniaturansicht angehängter Grafiken
circle.jpg  
  Mit Zitat antworten Zitat
Medium

Registriert seit: 23. Jan 2008
3.679 Beiträge
 
Delphi 2007 Enterprise
 
#2

AW: How to draw color circle?

  Alt 12. Mär 2012, 15:09
What you deem to be RGB is actually drawn using HSV. (Have a look here, the upper right in the topmost image.) So you basically go through a bitmap pixel by pixel, determin the angle and distance to the bitmap's center pixel, and use these for hue and saturation respectively. Vaule is simply fixed at 1. It naturally becomes a circle, since distances > 1 from the center would result in invalid parameters for HSV anyways.
"When one person suffers from a delusion, it is called insanity. When a million people suffer from a delusion, it is called religion." (Richard Dawkins)
  Mit Zitat antworten Zitat
freeway

Registriert seit: 11. Jul 2009
57 Beiträge
 
Delphi XE Professional
 
#3

AW: How to draw color circle?

  Alt 12. Mär 2012, 17:54
Solution with source code here http://www.efg2.com/Lab/Graphics/Colors/HSV.htm
  Mit Zitat antworten Zitat
Themen-Optionen Thema durchsuchen
Thema durchsuchen:

Erweiterte Suche
Ansicht

Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 14:43 Uhr.
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz