Added width and height checks to is_high_definition method