Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.
Announcements
Important Update: Community Platform Migration​. Learn more​>

Convert an int to a byte array

constantine-vassilev
9,679 Views

Does Intel has a fast routine for converting a 4 byteint and 4 byte float to a 4 byte byte array
and back?

Thanks in advance,
Constantine

0 Kudos
21 Replies
Vladimir_Dudnik
Employee
570 Views

I though I described that earlier. You may do

int abcd;

unsigned char* p = &abcd;

Now you can access a as p[3],b as p[2] and so on.

Vladimir

0 Kudos
Reply