Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

meaning of an expression in VHDLcode of JPEG2000

Status
Not open for further replies.

farhaenis

Newbie level 5
Newbie level 5
Joined
Mar 27, 2010
Messages
8
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
sfax
Activity points
1,323
meaning of an expression

In the code vhdl of the JPEG2000,i dont understand what's the meaning of this expression:

FUNCTION filter_5_3_even(x, yp, yn : SIGNED(CST_BUF_DATA_BUS_WIDTH - 1 DOWNTO 0)) RETURN SIGNED IS
BEGIN
RETURN x + SHIFT_RIGHT(yp + yn + 2, 2);
END;

This function ε to the DWT bloc.

Can any one please help me?
 

Re: meaning of an expression

I need the vhdl code of JPEG2000, can you send it to me?
Also we can help each others in understanding it.
 
  • Like
Reactions: sanju_

    sanju_

    Points: 2
    Helpful Answer Positive Rating
It seems to be a short FIR lowpass filter, length = 3
The 3 input values: yp, x, yn.
(yp = "previous", yn = "next")

The 3 coefficients: 0.25; 1; 0.25

Result = 0.25 * yp + 1 * x + 0.25 * yn
The "+ 2" in the SHIFT_RIGHT argument creates rounding to the nearest integer.
(it is an addition of 0.5, then a truncation to integer).

This is probably a very hardware efficient filter, since no multipliers are needed.
It is only an addition of 4 values. The shifting doesn't cost anything.
 
  • Like
Reactions: sanju_

    sanju_

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top