1

When I am converting RGBA to ARGB, I used this code:

vImage_Buffer src;
src.height = height;
src.width = width;
src.rowBytes = srcBytesPerRow;
src.data = srcRows;

vImage_Buffer dest;
dest.height = height;
dest.width = width;
dest.rowBytes = destBytesPerRow;
dest.data = destRows;

// Swap pixel channels from BGRA to RGBA.
const uint8_t map[4] = { 2, 1, 0, 3 };
vImagePermuteChannels_ARGB8888(&src, &dest, map, kvImageNoFlags);

I am getting the error below: For that I added Convertion.h and Accelerate.framework.

Undefined symbols for architecture armv6:
"_vImagePermuteChannels_ARGB8888", referenced from: -[CCOverlayView processImage] in CCOverlayView.o ld: symbol(s) not found for architecture armv6 collect2: ld returned 1 exit status

Can any one help me please?

geet Sebastian
  • 677
  • 6
  • 12
sreenivas
  • 399
  • 2
  • 5
  • 20

1 Answers1

3

You may be seeing one of two problems:

1) This routine is located in the Accelerate.framework. You need to add this to your project.

2) This routine is only available in iOS 5.0 and later; you probably should not be including armv6 in these builds. (The devices that require armv6 cannot run iOS 5.0).

idz
  • 12,825
  • 1
  • 29
  • 40
  • Hi idz,Apple doc mention this is available from mac 10.4.1. It means below iOS5.0 also. i added Accelerate.Framework also but no use. – sreenivas Oct 03 '12 at 05:41
  • 1
    Eh, not it doesn't Mac OS X is a different OS and it's version numbers have no relation to iOS'. https://developer.apple.com/library/ios/documentation/Performance/Reference/vImage_conversion/Reference/reference.html#//apple_ref/doc/uid/TP40005488-CH210-DontLinkElementID_4 Follow this link and scroll down to the availability section: "Availability Available in iOS 5.0 and later." – idz Oct 03 '12 at 06:17
  • can i re-size AVCamra capture size Actually AVCaptureSessionPresetMedium is 480X360 AVCaptureSessionPresetMedium is 192x162 but i want 320X192; i am using iOS 4.2.1 – sreenivas Oct 03 '12 at 11:31
  • Best to ask that a separate question! – idz Oct 03 '12 at 17:07