Better way of calculating pixels from dp