cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Scholar
Scholar
780 Views
Registered: ‎12-07-2018

Overlay Data in SDI Video

Jump to solution

Hello, I have a ZCU-106 Eval board and am running the demo that is passing SDI video into the board and then sending it out to a display monitor. I would like to overlay a frame counter in the video, somewhere in the top right of the display for people to see. Is there a way I can easily do this overlay? I am using the 

Thank you,

Joe

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Explorer
Explorer
555 Views
Registered: ‎07-18-2011

Re: Overlay Data in SDI Video

Jump to solution

@joe306 

No, problem, glad to be of help to you.  I was in that exact same place myself not that long ago. and a few kind souls here on the forum were of great help to me.

Try to start at the back end of your design and work incrementally towards the front, using the Video Test Pattern Generator IP as a signal source at various points in the debug process.   Do not try to design the entire thing and expect it to work, you will be stuck staring at a bunch of IP blocks and not know where to begin.

Also, be sure to go through the entire Xilinx Video Series at the top of this forum.  @florentw  has put a lot of work into providing an excellent starting point tutorial on many video IP blocks you will need.

 

View solution in original post

12 Replies
Highlighted
Moderator
Moderator
740 Views
Registered: ‎04-09-2019

Re: Overlay Data in SDI Video

Jump to solution

Hello @joe306 ,

We do have an IP called "Video On Screen Display" to perform the Text Overlay on the Video. But this IP was Obsoleted in Vivado 2019.1 and later versions. So, most probably we don't have a direct replacement of this IP also.

Probably, You need to develop Your own RTL to Implement this feature.

I hope it helps to You.

With Regards,

Ashok

Highlighted
Scholar
Scholar
706 Views
Registered: ‎12-07-2018

Re: Overlay Data in SDI Video

Jump to solution

Hello, thank you for responding to my message. Can you give me any suggestions on how I would approach writing my own RTL to do the overlay? Reading the documentation on the tutorial it passes through the PS side so one would think a C program could be written to do the overlay.

 

Anything you can share will be helpful.

 

Thanks,

Joe

0 Kudos
Highlighted
Scholar
Scholar
684 Views
Registered: ‎12-07-2018

Re: Overlay Data in SDI Video

Jump to solution

Hello, I've downloaded the documenation for the Video Mixer v4.0 PG245. Could that be added to the SDI Pass Thru example to do overlay? I'm investigating this IP. 

0 Kudos
Highlighted
Moderator
Moderator
647 Views
Registered: ‎04-09-2019

Re: Overlay Data in SDI Video

Jump to solution

Hello @joe306 ,

Video Mixer doesn't help to perform the Text Overlay feature. It will perform the overlay of the layers, not the overlayof the text.

I hope You can Implement Frame Number Overlay , Using 7 segment display  implementation in RTL.

I hope it helps to You. 

With Regards,

Ashok

0 Kudos
Highlighted
Scholar
Scholar
627 Views
Registered: ‎12-07-2018

Re: Overlay Data in SDI Video

Jump to solution

Hello, thank you for responding to my post. I'm not following the seven segment display. Who do you mean by that?

 

Thank you,

Joe

0 Kudos
Highlighted
Explorer
Explorer
614 Views
Registered: ‎07-18-2011

Re: Overlay Data in SDI Video

Jump to solution

@joe306 

The Video Mixer IP allows you to set up multiple layers of video, with selective alpha keying.

The layers can either be memory layers, or streaming layers.  If you use streaming layers, simply add a VDMA configured for read-only and connect it to the corrseponding video mixer input.  If you use memory layers, they will be automatically connected to your DDR and you can set up the addressing in your SW.

The master layer (s_axis_video input) is the background, you can either use it as a video input, or just turn off the master layer and use a selectable background color, like black or blue when no video is keyed over the background.  This is handy if you want a blue screen when there is no video present.  If you don't use this layer for background video input and only want to use it as a color background, you need to expand the port on the IP block and tie the s_axis_tvalid input low with a constant IP set to 0, to prevent errors, as that input has no default tie-off state.  

You can add additional layers with alpha-keying, to make the layers translucent or opaque over the layer beneath, or with no keying if you just want them opaque.

For example, if you set up the master layer with a fixed color, you can set up layer 1 as your main 24-bit RGB (or other format) video layer, and add an additional layer 2 for your characters.  If you set up layer 2 as a 32-bit alpha-keyed layer (RGBA for streaming RGBA8 for memory), you can write 32-bit values to that memory plane and they will show up as alpha-keyed pixels on your output.

You can then write some SW that writes bitmapped characters to that memory plane location.  It could be as simple as blocks of colored areas, designed to look like a  traditional 7-segment display format as @ashokkum described, or you could get fancy and use real bit-mapped characters and fonts.

The character transparency will be set by the value of alpha (the "A" upper byte of the 32-bit RGBA or RGBA8).  If A is 0x00, there will be no character, if A is 0xFF, it will be fully opaque in the color set by the three RGB bytes

If you set up two memory plane locations for your character plane, you can write to one plane while displaying the other, and switch between them when you are done updating the characters.  This will allow for a smooth transition between characters.

 

 

Highlighted
Scholar
Scholar
593 Views
Registered: ‎12-07-2018

Re: Overlay Data in SDI Video

Jump to solution

Hello and thank you for responding to my message. You have given me hope. I will need to figure out how to interface the output of the RX Subsystem to the Video Mixer Block. I am a newbie with all this stuff and have a lot ot learn. I am still working on getting the SMPTE UHD-SDI Pass Through to work. I have Vivado 19.1 and 19.2 and both are giving me troubles. 

 

Looks like I have a path to go down now. Thank you very much. 

Joe

0 Kudos
Highlighted
Scholar
Scholar
583 Views
Registered: ‎12-07-2018

Re: Overlay Data in SDI Video

Jump to solution

I am now looking at the xapp749-axi-vdma reference document to figure out VMDA. So, correct me if I'm wrong here, but are you suggesting that this could be done all in the PS ARM core(s)? Do I need to remove the AXI-S Data Fifo between the TX and RX Subsystem and put in a Video Mixer? Or does is the Mixer placed before the FIFO or after the FIFO? I will try to educate myself on the VDMA IP. By the way I am using the ZCU-106 Board. 

Thank you very much, 

Joe

0 Kudos
Highlighted
Explorer
Explorer
572 Views
Registered: ‎07-18-2011

Re: Overlay Data in SDI Video

Jump to solution

@joe306 

No, I was referring to a standard Vivado HW implementation, using a MicroBlaze, not a Zynq, but you can adapt it to your Zynq.

I've attached a pdf of a rough example of the output side for both stream and memory applications for the Video Mixer IP. using a MicroBlaze. Note how I've tied the s_axis_tvalid input low with a constant IP set to 0 so the background video layer is unused, so you can disable the XVMIX_LAYER_MASTER layer in the Video Mixer SW and set it to a solid color black or blue background as I mentioned previously.

As you can see in the pdf files, I've put in two VDMAs for the Video Mixer stream inputs, and there are no VDMAs, only memory connections, for the memory application.

Streaming is usually what you want for a live video path, and you would configure the VDMA with both read and write sides, with 3 frames of memory so you can synchronize the video output to avoid image tearing from reading and writing to the same buffer.

However, if you are controlling the video path from the Zynq, you may want to instead use the Video Frame Buffer Write and Video Frame Buffer Read IP and do your own frame synchronization.   I'd start with the standalone VDMAs first, as it will be easier.

Another example might be if you have a still image, or a slowly changing set of images you load into memory, that you want to overlay with characters.  In this case you could use the memory interface instead of streaming, since the image does not have to be synchronized to an incoming video stream.

Basically, familiarize yourself with the Video Mixer IP, VDMA, Video Frame Buffer Read and Write, Video Timing Controller, Video In to AXI-stream and AXI-stream to Video Out documentation, and architect your project to what best suits your needs using those IP blocks.

You also should read UG934, XAPP741, XAPP742, XAPP1291 and any other video app notes you can find.

 

 

Highlighted
Scholar
Scholar
560 Views
Registered: ‎12-07-2018

Re: Overlay Data in SDI Video

Jump to solution

Wow! You are a life safer. At first I had no road map to get this text overlay onto SDI streaming video but now you have given me hope and a lot of resources. Thank you very much. Joe

0 Kudos
Highlighted
Explorer
Explorer
556 Views
Registered: ‎07-18-2011

Re: Overlay Data in SDI Video

Jump to solution

@joe306 

No, problem, glad to be of help to you.  I was in that exact same place myself not that long ago. and a few kind souls here on the forum were of great help to me.

Try to start at the back end of your design and work incrementally towards the front, using the Video Test Pattern Generator IP as a signal source at various points in the debug process.   Do not try to design the entire thing and expect it to work, you will be stuck staring at a bunch of IP blocks and not know where to begin.

Also, be sure to go through the entire Xilinx Video Series at the top of this forum.  @florentw  has put a lot of work into providing an excellent starting point tutorial on many video IP blocks you will need.

 

View solution in original post

Highlighted
Scholar
Scholar
513 Views
Registered: ‎12-07-2018

Re: Overlay Data in SDI Video

Jump to solution

Thank you very much for your suggestions. 

0 Kudos