public static FloatBitmap FromPPM(RawLoader ppm, ProgressReporter callback) { FloatBitmap fbg = new FloatBitmap(); if (fbg.LoadDataFromPPM(ppm, callback)) return fbg; else return null; }
public FloatBitmap(FloatBitmap src) { CopyDataFrom(src); }
protected void CopyDataFrom(FloatBitmap src) { mWidth = src.mWidth; mHeight = src.mHeight; r_chan = new float[mWidth, mHeight]; g_chan = new float[mWidth, mHeight]; b_chan = new float[mWidth, mHeight]; hl_chan = new float[mWidth, mHeight]; for (int i = 0; i < mWidth; i++) for (int j = 0; j < mHeight; j++) { r_chan[i, j] = src.r_chan[i, j]; g_chan[i, j] = src.g_chan[i, j]; b_chan[i, j] = src.b_chan[i, j]; hl_chan[i, j] = src.hl_chan[i, j]; } }