Katark 0 Newbie Poster

Hello, Im studying java in high school.
Im building a project that containts ZBuffer so I have a problem impleting it with 3D models cuz I have a problem getting all of the pixel in a face that is made of 3 dots could some one suggest an algorithim for calculating Z parameter for each pixel in each Face?
Thanks in advance