I think you can try this -
copy the rectangle from the image which bounds the ellipse. Then traverse the rect and set the pixels transparent which are not in ellipse.
This might not be very efficient but you can optimise or look for some fast algo for determining points inside a ellipse. HINT : you can check the border areas,,, ellipse will cover most of the inner area.