amiga.org
     
iconAll times are GMT -6. The time now is 01:33 AM. | Welcome to Forum, please register to access all of our features.

» Amiga.org » Amiga computer related discussion » Amiga Software Issues and Discussion » Video overlay - essential for fast video playback

Amiga Software Issues and Discussion This forum exists for the discussion of the use, issues with, and fun brought about by classic and next generation Amiga software.

Reply
 
Thread Tools Display Modes
Old 06-27-2012, 01:23 PM   #1
Piru
' union select name,pwd--
Points: 30,457, Level: 100 Points: 30,457, Level: 100 Points: 30,457, Level: 100
Activity: 69% Activity: 69% Activity: 69%
 
Piru's Avatar
 
Join Date: Aug 2002
Location: Helsinki, Finland
Posts: 6,946
Default Video overlay - essential for fast video playback

Recently there has been a lot of discussion about overlay, and how it supposedly is obsolete and/or of small priority.

It is neither. Overlay is absolutely critical for low-end systems displaying video. The benefits of overlay are two-fold:
  1. Offloading the video scaling to hardware.
  2. Offloading the YCbCr -> RGB conversion to hardware.
The first point is the most critical. It allows the video to be scaled to whatever size requested without requiring the application to perform the frame scaling with the CPU. Even if you choose not to resize the video output at all, much of the video content (such as DVDs) require scaling out of the box to display the video with the correct aspect ratio.

The second point removes the need for the application to convert the YCbCr encoded image information to RGB understood by the graphics system. This leaves more time for actual video and audio decoding.

The practical implications are that if the OS or graphics driver doesn't support overlay, video playback will suffer. This is especially critical with the low-end systems that already spend considerable resources decoding the video and audio in the first place.

So neither is overlay low priority nor obsolete.

PS. It does not matter how the overlay is implemented. It could be dedicated overlay mode supported by the graphics hardware, or it could be implemented via the 3D hardware. The important point is that both OS and the device driver implement it and the APIs providing the overlay to the applications.

PPS. Overlay has other uses as well, such as in emulators where the graphics can be stretched to whatever size needed. Without it you're stuck with the postage stamp on a 1920x1080 display.

Last edited by Karlos; 06-29-2012 at 02:12 PM.. Reason: Merged PPS text from duplicate post.
Piru is offline   Reply With Quote
Old 06-28-2012, 06:39 AM   #2
woof
Hobbyist
Points: 7,631, Level: 58 Points: 7,631, Level: 58 Points: 7,631, Level: 58
Activity: 2% Activity: 2% Activity: 2%
 
Join Date: Feb 2003
Posts: 51
Default Re: Video overlay - essential for fast video playback

Hello

>1. Offloading the video scaling to hardware.
But the existing CompositeTags() can do hardware resizing on x1000...

>2. Offloading the YCbCr -> RGB conversion to hardware.
But Altivec can (may) do that...

So when when you say "we need overlay" what exactly is needed ? a full gxvideo.library implementation ? or just a function to convert/display an YCbCr buffer ?

Alain Thellier
woof is offline   Reply With Quote
Old 06-28-2012, 07:04 AM   #3
LaserBack
Technoid
Points: 5,275, Level: 46 Points: 5,275, Level: 46 Points: 5,275, Level: 46
Activity: 14% Activity: 14% Activity: 14%
 
Join Date: Mar 2007
Posts: 280
Default Re: Video overlay - essential for fast video playback

yes overlay is essential
on the Amiga only the Picasso 4 and the cybervision 64 supports overlay
on winuae have not been implemented yet...Tony was asked to implement it on winuae for fast and better video play back but he said he is not interested in add that function to winuae...he said that everyone must use windows to watch videos
LaserBack is offline   Reply With Quote
Old 06-28-2012, 08:11 AM   #4
Crumb
Defender of the Faith
Points: 11,878, Level: 71 Points: 11,878, Level: 71 Points: 11,878, Level: 71
Activity: 33% Activity: 33% Activity: 33%
 
Crumb's Avatar
 
Join Date: Mar 2002
Posts: 1,724
Default Re: Video overlay - essential for fast video playback

Quote:
Originally Posted by woof View Post
Hello

>1. Offloading the video scaling to hardware.
But the existing CompositeTags() can do hardware resizing on x1000...

>2. Offloading the YCbCr -> RGB conversion to hardware.
But Altivec can (may) do that...

So when when you say "we need overlay" what exactly is needed ? a full gxvideo.library implementation ? or just a function to convert/display an YCbCr buffer ?

Alain Thellier
These *PIP* functions expect a driver with working overlay:
http://amiga.sourceforge.net/amigade...roup=Picasso96 otherwise current videoplayers won't be able to open a PIP/overlay windows and will have to switch to other rendering methods.
__________________
The only spanish amiga news web page/club: Club de Usuarios de Amiga de Zaragoza (CUAZ)
Crumb is offline   Reply With Quote
Old 06-28-2012, 09:51 AM   #5
spirantho
Premium Member
Points: 10,848, Level: 68 Points: 10,848, Level: 68 Points: 10,848, Level: 68
Activity: 46% Activity: 46% Activity: 46%
 
Join Date: Aug 2002
Posts: 1,100
Default Re: Video overlay - essential for fast video playback

My understanding is that Overlay is a hardware device - it's where the graphics card renders its frame buffer and then renders a seperate area (the overlay).

Using 3D to emulate overlay is a perfectly valid way of doing it, but it's not actually overlay - which is Hans' point.

Overlay is obsolete.
Using 3D to gain the same benefits as overlay is not.

Hans isn't saying that the drivers don't need video support, he's saying it should be done via 3D, not overlay. Which is correct, as overlay is indeed pretty much obsolete these days of 3D graphics cards.
__________________
--
Ian Gledhill
ian.gledhill@btinternit.com (except it should be internEt of course...!)
Check out my shop! http://www.mutant-caterpillar.co.uk/shop/ - for 8-bit (and soon 16-bit) goodness!
spirantho is offline   Reply With Quote
Old 06-28-2012, 09:58 AM   #6
Crumb
Defender of the Faith
Points: 11,878, Level: 71 Points: 11,878, Level: 71 Points: 11,878, Level: 71
Activity: 33% Activity: 33% Activity: 33%
 
Crumb's Avatar
 
Join Date: Mar 2002
Posts: 1,724
Default Re: Video overlay - essential for fast video playback

Quote:
Originally Posted by spirantho View Post
Hans isn't saying that the drivers don't need video support, he's saying it should be done via 3D, not overlay.
And OS4 should support various cpu cores and include memory protection but it doesn't and most probably won't.

Quote:
My understanding is that Overlay is a hardware device - it's where the graphics card renders its frame buffer and then renders a seperate area (the overlay).
There's an API to handle overlay/PIP or whatever name you want to use. The graphic card drivers should take care of providing an implementation for that interface. It doesn't matter how you implement overlay, what matters is if it's supported or not because all amiga video players from the nineties to 2012 use PIP/overlay API.

Hans has said gpu is very complex and you can expect creating working 3d drivers will take much more time. If you plan to implement overlay compatibility after 3d drivers are done it will take much more time. Permedia2 lacked true overlay and CGX coders implemented Overlay support using a pair of textures. It didn't require full OpenGL support.
__________________
The only spanish amiga news web page/club: Club de Usuarios de Amiga de Zaragoza (CUAZ)

Last edited by Crumb; 06-28-2012 at 10:01 AM..
Crumb is offline   Reply With Quote
Old 06-28-2012, 10:05 AM   #7
itix
Defender of the Faith
Points: 11,740, Level: 71 Points: 11,740, Level: 71 Points: 11,740, Level: 71
Activity: 5% Activity: 5% Activity: 5%
 
itix's Avatar
 
Join Date: Oct 2002
Posts: 1,874
Default Re: Video overlay - essential for fast video playback

Quote:
But the existing CompositeTags() can do hardware resizing on x1000...
It is faster use an overlay. Besides, when you are setting up a call to CompositeTags() or BltBitMapScaleArgs() overlay has done it already.

Quote:
But Altivec can (may) do that...
It is faster use an overlay. Besides, low end machines dont have AltiVec.

Overlay is not obsolete.
__________________
Only MorphOS makes it possible \o_
itix is offline   Reply With Quote
Old 06-28-2012, 12:32 PM   #8
Heiroglyph
Cult Member
Points: 7,346, Level: 56 Points: 7,346, Level: 56 Points: 7,346, Level: 56
Activity: 20% Activity: 20% Activity: 20%
 
Heiroglyph's Avatar
 
Join Date: Jun 2010
Posts: 834
Default Re: Video overlay - essential for fast video playback

Once you've converted to RGB, the video takes much more memory and bandwidth.

Yuv (or ycbcr) is skipping many color components.

RGB is 4:4:4 (for every 4 pixels, there are 4 sames of each component)
Yuv can be 4:2:2, 4:1:1, 4:2:0 (really a misnomer), etc. so it's much smaller in memory.

DVD, BluRay and all the common mp4/h264 variants are 4:2:0 for example.

Not having to convert to a larger more cumbersome RGB format is one of the biggest benefits of overlay, 3D "faked" or not.
Heiroglyph is offline   Reply With Quote
Old 06-28-2012, 02:07 PM   #9
Karlos
Sockologist
Points: 48,752, Level: 100 Points: 48,752, Level: 100 Points: 48,752, Level: 100
Activity: 8% Activity: 8% Activity: 8%
 
Karlos's Avatar
 
Join Date: Nov 2002
Location: I solve practical problems...
Posts: 16,606
Blog Entries: 18
Default Re: Video overlay - essential for fast video playback

I think part of the problem is that many people are confusing the concept with with a particular implementation of the concept. To me, and probably to Hans, a video overlay is a very specific hardware implementation that is distinct from chromakeying and video texturing. To the next guy, maybe not. So, for the sake of clarity, I'll use the term "hardware video surface" to describe the general concept of a hardware assisted mechanism for rendering YCbCr formatted frames without the need for software colour conversion or scaling.

Nobody is arguing against the need for "hardware video surface" support in display drivers. Even when you don't need to scale the output, not having to do the colour conversion can make a difference in the amount of data that has to be transferred over the bus as the YCbCr data is typically more compact than RGB. In a perfect world, various parts of the hardware that are involved in video stream decoding would be openly documented and we could use those too.

The argument has been over the merits of particular ways of implementing support for "hardware video surfaces". The original hardware mechanism that we are used to from the days of Cirrus Logic and S3 chipsets of yesteryear (and variations thereof) are what are being described as obsolete here. I haven't looked too closely, but from what I gather, this particular method doesn't even exist in a lot of current generation cards. Instead, video colour conversion and scaling is handled by parts of the hardware 3D pipeline through the use of texture mapping, in which each YCbCr frame is used as a texture and rendered onto a quad (a rectangle primitive, optionally realized as a triangle fan or strip on hardware without direct support for quads).

Right now, as far as I know no specific implementation exists for the RadeonHD drivers. With adequate 3D support, however, implementing a hardware video surface via video texturing becomes feasible. Since both 3D and video playback are desirable features, it makes sense to focus on the overlap.
__________________
OCA
This isn't SCSI... This is SATA!!!
I have CDO. It's like OCD except all the letters are in ascending order. The way they should be.
Core2 Quad Q9450 2.66GHz / X48T / 4GB DDR3 / nVidia GTX275 / Linux x64, AROS, Win64
A1XE 800MHz / 512MB / Radeon 9200 / OS4.1
A1200T BPPC 240MHz / 256MB / Permedia 2 / OS 3.1 - OS3.9, OS4
A1200T Apollo 1240 28MHz / 32MB / Mediator1200 / Voodoo 3000 / OS3.9
A1200D Apollo 1240 25MHz (ejector seat ROM edition) / 32MB
Karlos is offline   Reply With Quote
Old 06-28-2012, 02:26 PM   #10
Akiko
VIP / Donor
Points: 11,235, Level: 69 Points: 11,235, Level: 69 Points: 11,235, Level: 69
Activity: 8% Activity: 8% Activity: 8%
 
Akiko's Avatar
 
Join Date: Jun 2002
Location: UK
Posts: 932
Default Re: Video overlay - essential for fast video playback

The good news is thanks to funding this guy appears to be working on these drivers full time. I'm sure many of the features including those right up to what the latest new Radeon graphics cards have to offer with video playback enhancements will come.
Akiko is offline   Reply With Quote
Old 06-28-2012, 07:34 PM   #11
magnetic
Defender of the Faith
Points: 14,609, Level: 78 Points: 14,609, Level: 78 Points: 14,609, Level: 78
Activity: 99% Activity: 99% Activity: 99%
 
magnetic's Avatar
 
Join Date: Feb 2002
Posts: 1,736
Blog Entries: 1
Default Re: Video overlay - essential for fast video playback

Piru

Thanks for the technical explanation. I guess the fanboys that DONT have overlay needed this. I found some of the comments about not having it being ok to be funny. Overlay makes a big difference in many practical ways that affect all users.

Dont know if this is really a "news" item but glad for the clarification to stop silly additional posts
__________________
bPlan Pegasos2 G4@1ghz
Quad Boot:Reg. MorphOS /Amiga OS4.1 U4/Ubuntu GNU-Linux /MacOS X

Amiga Technologies A1200 HD | Blizzard 1260@66mhz | 128mb | OS 3.9 | Indivision MK2
magnetic is offline   Reply With Quote
Old 06-28-2012, 07:48 PM   #12
Akiko
VIP / Donor
Points: 11,235, Level: 69 Points: 11,235, Level: 69 Points: 11,235, Level: 69
Activity: 8% Activity: 8% Activity: 8%
 
Akiko's Avatar
 
Join Date: Jun 2002
Location: UK
Posts: 932
Default Re: Video overlay - essential for fast video playback

A discussion about overlay is classed as a news item?
Akiko is offline   Reply With Quote
Old 06-28-2012, 08:19 PM   #13
Piru
' union select name,pwd--
Points: 30,457, Level: 100 Points: 30,457, Level: 100 Points: 30,457, Level: 100
Activity: 69% Activity: 69% Activity: 69%
 
Piru's Avatar
 
Join Date: Aug 2002
Location: Helsinki, Finland
Posts: 6,946
Default Re: Video overlay - essential for fast video playback

Quote:
Originally Posted by Akiko View Post
A discussion about overlay is classed as a news item?
The mistake was mine, I originally posted to a wrong category by accident. This "news item" should be deleted. To quote the actual discussion thread post:
Quote:
MODS: I think I posted this yesterday as an misc announcement by accident. Please nuke that post.

Last edited by Piru; 06-28-2012 at 08:48 PM..
Piru is offline   Reply With Quote
Old 06-29-2012, 01:44 PM   #14
Akiko
VIP / Donor
Points: 11,235, Level: 69 Points: 11,235, Level: 69 Points: 11,235, Level: 69
Activity: 8% Activity: 8% Activity: 8%
 
Akiko's Avatar
 
Join Date: Jun 2002
Location: UK
Posts: 932
Default Re: Video overlay - essential for fast video playback

It goes to show how active the mods are here now days, talk about a slippery slope.
Akiko is offline   Reply With Quote
Old 06-29-2012, 02:13 PM   #15
Karlos
Sockologist
Points: 48,752, Level: 100 Points: 48,752, Level: 100 Points: 48,752, Level: 100
Activity: 8% Activity: 8% Activity: 8%
 
Karlos's Avatar
 
Join Date: Nov 2002
Location: I solve practical problems...
Posts: 16,606
Blog Entries: 18
Default Re: Video overlay - essential for fast video playback

Quote:
Originally Posted by Akiko View Post
It goes to show how active the mods are here now days, talk about a slippery slope.
We do have lives too, you know.
__________________
OCA
This isn't SCSI... This is SATA!!!
I have CDO. It's like OCD except all the letters are in ascending order. The way they should be.
Core2 Quad Q9450 2.66GHz / X48T / 4GB DDR3 / nVidia GTX275 / Linux x64, AROS, Win64
A1XE 800MHz / 512MB / Radeon 9200 / OS4.1
A1200T BPPC 240MHz / 256MB / Permedia 2 / OS 3.1 - OS3.9, OS4
A1200T Apollo 1240 28MHz / 32MB / Mediator1200 / Voodoo 3000 / OS3.9
A1200D Apollo 1240 25MHz (ejector seat ROM edition) / 32MB
Karlos is offline   Reply With Quote
Reply

Bookmarks

Tags
essential , fast , fast video , overlay , playback , scaling , video , video playback , ycbcr

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump