Automatic visible line detection and rendering using the frame buffer