A digital cameras zoom lens is effectively a YouTube Video Cropper tool that lets you zero in on an important subject area to make it fill as much of the frame as you want. The lens does this optically by narrowing its view to exclude some subject area while magnifying those that are left within the frame.
When zooming optically with a digital camera, the picture area contains the full number of pixels for the selected resolution setting, but more of them are now devoted to the area you want, making its details clearer. Most digicams (and some camera-phones) include a digital zoom facility that works by selecting out a rectangular area in the centre of the field of view and enlarging it to fill the frame. All unwanted pixels in the surrounding area are discarded.
The cropped image then undergoes an interpolation process that adds new pixels on the basis of existing pixels in the image, these new interpolated pixels are created from existing image data, so you don’t gain anything beyond a slightly tighter composition.
The actual picture quality will depend on how many pixels your camera used to make the image and how much of that image you crop away. It will also be influenced by the quality of the cameras interpolation algorithms. High levels of digital zoom require a lot of extra pixels to be added and this usually results in a loss of both image sharpness and contrast so digital zoom shots often look much flatter and fuzzier than shots taken with the cameras optical zoom lens.
Digital SLR cameras never include a digital zoom function but photographers who use these cameras can achieve a similar objective by enlarging and cropping shots when they edit them on a computer. The higher the cameras sensor resolution, the more enlargement is possible before the image starts to degrade and the greater potential for selective cropping.