Cocoa and bit handling
Cocoa and bit handling
- Subject: Cocoa and bit handling
- From: "Peter Karlsson" <email@hidden>
- Date: Tue, 21 Dec 2004 12:27:14 +0100
Dear list!
I have 2 pointers declared as byte. They are called source and target.
The source pointer points to the first byte of a memory area. The target
pointer points to the first byte of another memory area.
Is there a easy way to move bits fom source byte to target byte?
Example:
Source byte maybe looks like this:
01001011
Target byte looks like this before:
00000000
Target byte looks like this after:
01000000
I want to move bit 3 of the source byte to bit 6 of the target byte. This
will repeat thousands of times in a loop. And the bit position changes
every lap. So next lap I maybe want to move source bit 2 to target bit 5
and so on...
Best regards Peter
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden