开发者

How to get color from int value on blackberry

开发者 https://www.devze.com 2023-04-11 02:32 出处:网络
I\'ve 开发者_高级运维got int value (for red,green,blue) returned from a Web Service. topR = 0.14

I've 开发者_高级运维got int value (for red,green,blue) returned from a Web Service.

topR = 0.14
topG = 0.14
topB = 0.14


bottomR =0.62
bottomG =0.62
bottomB =0.62

From this value how to get color on blackberry.

Pls help me.


Maybe this is what your looking for

private int color =  0x00000000;  

public void setColor(int r, int g, int b)
{
     color = (255<<24) | (r<<16) | (g<<8) | b;
}
0

精彩评论

暂无评论...
验证码 换一张
取 消