AN2121 Freescale Semiconductor / Motorola, AN2121 Datasheet - Page 18

no-image

AN2121

Manufacturer Part Number
AN2121
Description
JPEG2000 Arithmetic Encoding on StarCore SC140
Manufacturer
Freescale Semiconductor / Motorola
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
AN2121SC
Manufacturer:
TERIDIAN
Quantity:
40
Background Theory
In principle, the probability model counts the frequencies of LPS and MPS to adaptively estimate Q
P
the machine transfers to a new state with a larger Q
occurs and the interval length A becomes less than 0.75, the state machine transfers to a new state with a
smaller Q
renormalized. In other words, if an MPS occurs, then the probability associated with the MPS, (1 – Q
increased slightly because it has taken place once again, i.e. this means that the LPS is even less likely to
occur so the Q
(i.e., Q
For example, when the model is at state 31 (index 31), Q
transfers to state 29 where Q
If an MPS then occurs, a state transition may or may not occur, depending on the value of interval length
A. If A < 0.75, the model transfers to state 30 where Q
Renormalization then follows. Otherwise, no state transition, hence no renormalization occurs.
2.4.4
To solve the growing precision problem, coding operations are carried out using fixed precision integer
arithmetic. The hexadecimal value $8000, which normally represents the decimal value 0.5, represents the
decimal value 0.75 in the JPEG2000. With this representation, if the integer $8000 is left-shifted once, the
decimal value becomes 1.5; if it is right-shifted once, the decimal value becomes 0.375. The interval length
A is renormalized whenever the integer value falls below $8000, and is kept in the range [0.75, 1.5) by a
left shift.
To maintain consistent scaling between C and A, C is left-shifted whenever A is renormalized. This scaling
would require a register of unlimited length in which to store the value of C. To avoid this impossible
requirement, an external data buffer or ‘B register’ is attached to the high order bits of the C register. A
byte of data is shifted from the high order bits of the C register to this buffer whenever the C register is full.
Each output byte effectively refines the code word, resulting in incremental code word transmission.
2.4.5
Whenever an MPS occurs, the C value is incremented by the value of the LPS interval, which can generate
a carry. However, if the carry bit propagates into the data buffer, thus altering its contents, the incremental
transmission is invalid. The B register described in Section 2.4.4 also serves to resolve the carry problem.
14
e
Index
. The model always expects an MPS to occur. The state machine is designed so that when an LPS occurs,
29
30
31
32
33
e
) must be increased slightly.
e
. Thus, the change in state occurs only when the arithmetic coder interval register is
Hexadecimal
Finite Precision
Carry Propagation
e
$0AC1
$09C1
$08A1
$1101
$0521
is correspondingly reduced. Similarly, if an LPS occurs, then its probability of occurrence
Table 2. A Portion Table C-2 From the JPEG2000 FDIS
JPEG2000 Arithmetic Encoding on the StarCore SC140
Freescale Semiconductor, Inc.
e
= 0.099634, which is greater than 0.057153. Renormalization then follows.
For More Information On This Product,
0001 0001 0000 0001
0000 1010 1100 0001
0000 1001 1100 0001
0000 1000 1010 0001
0000 0101 0010 0001
Q
e
Binary
Value
Go to: www.freescale.com
e
, and a renormalization is performed. When an MPS
e
= 0.063012 (smaller than 0.099634).
e
= 0.057153. If an LPS occurs, the model
0.099 634
0.063 012
0.057 153
0.050 561
0.030 053
Decimal
NMPS
30
31
32
33
34
NLPS
27
28
29
30
31
SWITCH
0
0
0
0
0
e
and
e
), is

Related parts for AN2121