自分用メモ
(x,y)にあるピクセルのRGBそれぞれを個別に操作する時。p71
((unsigned char*)(img->imageData + img->widthStep * y))[x*3+0] // R ((unsigned char*)(img->imageData + img->widthStep * y))[x*3+1] // G ((unsigned char*)(img->imageData + img->widthStep * y))[x*3+2] // B
自分用メモ
(x,y)にあるピクセルのRGBそれぞれを個別に操作する時。p71
((unsigned char*)(img->imageData + img->widthStep * y))[x*3+0] // R ((unsigned char*)(img->imageData + img->widthStep * y))[x*3+1] // G ((unsigned char*)(img->imageData + img->widthStep * y))[x*3+2] // B