BIT_SHIFT
Name
BIT_SHIFT
Purpose
Shift bits in a byte array by any amount.
Category
Calling Sequence
out = bit_shift(in,n)
Inputs
in = Input byte array. in
May be 1-D or 2-D. Always shifts
the X dimension.
n = Number of bits to shift (+ or -). in
Keyword Parameters
Keywords
/ONE_D Shift input array as a 1-D array even if 2-D.
ERROR=err Error flag: 0=ok.
Outputs
out = Resulting byte array. out
Common Blocks
Notes
Note: The shift may be left (n>0) or right (n<0).
Same direction as ishft.
Bits will shift between bytes in the array and will
be lost when they go out of either end. Bits that shift
into the array will be 0.
Modification History
R. Sterner, 2011 Aug 11
R. Sterner, 2011 Aug 23 --- Fixed shift direction in help text.
R. Sterner, 2011 Sep 05 --- Added keyword /ONE_D.
Copyright (C) 2011, Johns Hopkins University/Applied Physics Laboratory
This software may be used, copied, or redistributed as long as it is not
sold and this copyright notice is reproduced on each copy made. This
routine is provided as is without any express or implied warranties
whatsoever. Other limitations apply as described in the file disclaimer.txt.