1. A method of generating perceptually lossless compression of image data or perceptually enhanced compression of image data including the steps of: receiving an image; color transforming the received image to a desired color space, forming converted color-space (CCS) images; transforming the CCS images into transformed CCS images; applying quantization to the transformed CCS images to form quantized CCS images; processing the image to produce optimized images that are perceptually lossless or perceptually enhanced in quality, processing including the steps of: mapping pixels in the CCS images to corresponding CCS transform-domain coefficients, forming mapped CCS images; determining a contrast and magnitude sensitivity level of the mapped CCS images based on the human visual system (HVS) and outputting a contrast sensitivity profile for the mapped CCS images; calculating the activity level in the mapped CCS images and outputting an activity estimation profile; using the mapped CCS images along with the transformed or quantized CCS images for estimating a base error magnitude at or below a visibility threshold and outputting a base error magnitude profile; using the visual masking profile, contrast sensitivity profile, activity estimation profile and base error magnitude profile to determine a perceptual error estimation; sending the mapped CCS images along with the transformed or quantized CCS images to an enhancement unit to determine where and how much information should be enhanced in the transformed or quantized CCS images and outputting a resulting enhancement profile representing where and how much information should be enhanced; sending the mapped CCS images to a low luminance/chrominance contrast unit to determine a low luminance/chrominance contrast profile; and encoding the optimized images for subsequent storage and/or transmission.