2

I have an MVC application where I need to shrink the size of a Image. To do that I also reduce the bit depth to max. 8 bits. I've got all the code in a Controller but now I want to get it from the server to the client. How can I reduce the bit depth of an image in JavaScript or some other client side solution ?

Some pseudo code:

function ScaleImage(image) {
    var ration = GetSize(image);

    if (image.bitdepth > 8) {
        ReduceBitDepth(image)
    }

    ...
}
Lexu
  • 579
  • 1
  • 5
  • 14

0 Answers0