38 #include <visp3/core/vpConfig.h>
42 #include <visp3/core/vpImageConvert.h>
87 for (
unsigned int i = 0; i < src.
getHeight(); ++i) {
88 for (
unsigned int j = 0; j < src.
getWidth(); ++j) {
89 dest->pixel(j, i) = src[i][j];
143 dest.
resize(src->height(), src->width());
145 for (
unsigned int i = 0; i < dest.
getHeight(); ++i) {
146 for (
unsigned int j = 0; j < dest.
getWidth(); ++j) {
147 dest[i][j] = src->pixel(j, i);
197 dest->setExternal(src.
bitmap,
static_cast<int>(src.
getCols()),
static_cast<int>(src.
getRows()));
245 dest.
resize(src->height(), src->width());
247 for (
unsigned int i = 0; i < dest.
getHeight(); ++i) {
248 for (
unsigned int j = 0; j < dest.
getWidth(); ++j) {
249 dest[i][j].R = src->pixel(j, i).r;
250 dest[i][j].G = src->pixel(j, i).g;
251 dest[i][j].B = src->pixel(j, i).b;
252 dest[i][j].A = src->pixel(j, i).a;
297 for (
unsigned int i = 0; i < srcRows; ++i) {
298 for (
unsigned int j = 0; j < srcWidth; ++j) {
299 dest->pixel(j, i).r = src[i][j].R;
300 dest->pixel(j, i).g = src[i][j].G;
301 dest->pixel(j, i).b = src[i][j].B;
350 const int srcHeight = src->height(), srcWidth = src->width();
351 dest.
resize(srcHeight, srcWidth);
352 for (
int i = 0; i < srcHeight; ++i) {
353 for (
int j = 0; j < srcWidth; ++j) {
354 dest[i][j].R = src->pixel(j, i).r;
355 dest[i][j].G = src->pixel(j, i).g;
356 dest[i][j].B = src->pixel(j, i).b;
static void convert(const vpImage< unsigned char > &src, vpImage< vpRGBa > &dest)
unsigned int getWidth() const
void resize(unsigned int h, unsigned int w)
resize the image : Image initialization
unsigned int getCols() const
Type * bitmap
points toward the bitmap
unsigned int getHeight() const
unsigned int getRows() const