I am working on a complex UI design it is like circular wheel containing 10 icons in circular locus. i need to scale every icon as per the device resolution. Please have a look for specific code snippet:-
if (displayWidth<=241) {
bitmap = scaleBimtap(bitmap, 42, 39);
}else if (displayWidth<=320) {
bitmap = scaleBimtap(bitmap, 42, 39);
}else if (displayWidth<=480) {
bitmap = scaleBimtap(bitmap, 52, 44);
}else{
bitmap = scaleBimtap(bitmap, 52, 44);
}
HTC sensation is a 540X960 resolution device. So here is bitmap = scaleBimtap(bitmap, 52, 44); must be chosen in this case but this seems to be wrongly scaled and icons being displayed bigger then. What can i do for this to work.