Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
21611 Discussions

Avalon Streaming new component in SOPC (VHDL)

Altera_Forum
Honored Contributor II
1,744 Views

Hello everyone, 

 

I am trying to create a new component to be integrated in the SOPC builder which performs, as a start, a color inverting operation. I've built a system using Test pattern generater and Clocked video output and I managed to create a dummy core that streams the data between the two cores.  

After reading the avalon streaming specifications I come out with the following : 

- The valid RGB data coming out from the TPG is asserted when valid=1 and reday=1  

- The data contains the RGB informations  

 

When I tried to invert the signal (when valid = 1 and ready = 1) by pressing a switch I get nothing on the screen ! 

 

Would please help me out with how to decode that data coming from the ST source into RGB in order to know the exact value of the pixel ? 

 

Best regards
0 Kudos
4 Replies
Altera_Forum
Honored Contributor II
673 Views

You should review Chapter 3 of the "Video and Image Processing Suite User Guide" (ug_vip.pdf) 

 

The Avalon Streaming specification will only describe the generic Avalon-ST, while the above will describe the packet format used by the Altera video blocks. 

 

From your description, it sounds like your problem is likely that you are also inverting the data in the control packets and also the first symbol of the video packet that mark it as a "video" type packet.
0 Kudos
Altera_Forum
Honored Contributor II
673 Views

First of all I would like to thank you for responding. 

 

Second, I managed to isolate the data packet and invert the color patern but I still have a minor problem. The image brightness increased !!  

Does the data packet include the brightness of color ?  

 

 

Thank you again
0 Kudos
Altera_Forum
Honored Contributor II
673 Views

No, "brightness" is not a separate field in any packet. 

 

By manipulating the RGB values, you will affect the perceived brightness of the image. If you google for "rgb brightness calculation" you'll find some pages that have the formula. 

Also, the wikipedia article on Brightness may be useful reading.
0 Kudos
Altera_Forum
Honored Contributor II
673 Views

Thank you ted for your help  

 

Best regards
0 Kudos
Reply