10#include "Fg3ImgIo.hpp"
18 const FimImgRgbaUbC & in,
21 out.resize(in.width(),in.height());
22 for (uint row=0; row<out.height(); ++row)
23 for (uint col=0; col<out.width(); ++col)
24 out.xy(col,row) = *(Rgba8*)(&(in[row][col]));
29 const FimImgRgbaFC & in,
32 out.resize(in.width(),in.height());
33 for (uint row=0; row<out.height(); ++row)
34 for (uint col=0; col<out.width(); ++col)
37 uchar(in[row][col].c[0]),
38 uchar(in[row][col].c[1]),
39 uchar(in[row][col].c[2]),
40 uchar(in[row][col].c[3]));
48 out.resize(in.width(),in.height());
49 for (uint row=0; row<out.height(); ++row)
50 for (uint col=0; col<out.width(); ++col)
51 out[row][col] = *(FimRgbaUbC*)(&in.xy(col,row));
56 String8
const & fname,
59 ImgRgba8 img2 = loadImage(fname);
60 fg3ImgConvert(img2,img);