The images themselves, not screenshots of pages
Converting a page to an image gives you a picture of the whole page at a chosen resolution. Extracting images is different: it takes the pictures that are embedded in the PDF and saves each one as its own file, in the size it was stored. A photo in a brochure comes out as the photo, without the text around it.
JPEG images, which is how most photos are stored in PDFs, are written to the JPG file exactly as they are in the PDF. They are not decoded and compressed again, so there is no extra quality loss and the file size stays the same.
PNG for everything else
PDFs also store pictures in other ways: compressed pixels, JPEG 2000, black and white scan formats, CMYK print colors or indexed palettes. These are decoded at their full resolution and saved as PNG, which keeps every pixel. If the PDF has a transparency mask for the image, the PNG keeps the transparency.
Images that appear on several pages, such as a logo in the header, are saved only once. Tiny images under 50 pixels, like icons and lines, are skipped by default; untick the option to keep them.
Limits
Very small inline images that are written directly into the page code are not extracted. Vector drawings and charts are not images, so they are not included; use PDF to JPG to save whole pages instead. Images that are cut by the page edge are saved in full.