I have this function and I can't modify it
Image z("abc.jpg");
Image g = z.change();
in function Change, I need to return a new value in g without affecting z.
My main problem is in the next function
Image Image::change(){
    Image temp = *this;
    ...
    temp.image[i][j] = mean; // here also this->image[i][j] changed to the same value
}
in this function whenever I change temp , this changes and this is not what I want
the copy constructor
Image::Image(const Image &obj):imageHeader("Temp")
{
    width = obj.width;
    height = obj.height;
    image = obj.image;
    imageHeader = obj.imageHeader;
}
 
     
    