Imaging Concepts
Raster, vector and pixels
A digital image is either raster (a rectangular grid of pixels) or vector (mathematically described shapes and paths). Raster suits photographs and painted artwork; vector suits logos, type and diagrams because it scales to any size without losing edge quality. A raster image enlarged far beyond its native size shows visible squares (pixelation).
Dimensions vs resolution
Pixel dimensions state how many pixels wide by high. Resolution (ppi, pixels per inch) states how densely those pixels are packed for output. Link them with the only formula you need:
print size = pixel dimensions ÷ ppi
So 3000 × 2000 px printed at 300 ppi gives 10 × 6.7 inches. DPI strictly describes printer ink dots, not image pixels, but questions often use the terms loosely. Upsampling adds pixels by interpolation; it never recovers detail that was never captured.
Colour
Bit depth is bits per channel: 8 bits gives 256 levels; 24-bit RGB gives roughly 16.7 million colours. Indexed colour limits an image to a palette (GIF: 256 colours). RGB is additive and used for screens; CMYK is subtractive and used for presses. A device's gamut is the range of colours it can reproduce, so converting RGB artwork to CMYK can dull vivid colours.
Files and transparency
Lossless compression (PNG, TIFF with LZW) preserves every pixel; lossy compression (JPEG) discards data, and quality degrades with each re-save. Alpha channels carry transparency: supported by PNG and TIFF, only 1-bit by GIF, not at all by JPEG.
Worked rule: for a 6 × 4 inch print at 300 ppi you need 1800 × 1200 px. Trap: a large file size does not prove high quality - an upsample or a low-compression JPEG can be big and still soft.