# Calculating a lighter shade from a passed color

**URL:** https://forum.kirupa.com/t/calculating-a-lighter-shade-from-a-passed-color/207239
**Category:** flash
**Created:** [November 15, 2006, 8:23pm UTC](https://forum.kirupa.com/t/calculating-a-lighter-shade-from-a-passed-color/207239 "2006-11-15T20:23:57Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![slopps](https://avatars.discourse-cdn.com/v4/letter/s/df788c/32.png) [@slopps](https://forum.kirupa.com/u/slopps)
#### Post date: [November 15, 2006, 8:23pm UTC](https://forum.kirupa.com/t/calculating-a-lighter-shade-from-a-passed-color/207239/1 "2006-11-15T20:23:57Z")

</div>

Hi everyone! This place is great and the website is a big help.

I’m trying to write a function for the purpose of generating a gradient fill from only one passed color. How can you take a passed color (0x0066cc, a blue, for example) and calculate a much lighter (almost white) shade of blue from it?

Any help would be much appreciated! Thanks again for all the previous aid I’ve gotten from you guys.
