Obtaining Average RGB Value of an Image
You can obtain the average RGB value of an image by making an API call only.
This operation enables you to obtain the average RGB value of an image, which is returned as a hexadecimal value in JSON format.
Operation name: average-hue
Example
You can access the following address through a web browser and obtain the average RGB value of the example.jpg image:
https://obs.region.example.com/image-demo/example.jpg?x-image-process=image/average-hue
If information similar to the following is displayed, the average RGB value of the image is obtained successfully:
{"RGB":"#28577D"}
The original image of example.jpg is as follows:
The obtained average RGB value (#28577D) is:
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot