Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-02 Thread Reimar Döffinger
On 01.11.2014, at 13:45, Reimar Döffinger reimar.doeffin...@gmx.de wrote:
 This is a regression, previous code did not require
 users to set the profile to use VDPAU.
 In addition, ASP is a superset of SP, so there is not
 even a good reason to require it.

Are there still objections?
As said, to my knowledge every ASP decoder is required to be a fully working SP 
decoder, so I think this can't break anything with compliant implementations, 
which is my main justification (besides the regression part).
Does anyone disagree?
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-02 Thread Carl Eugen Hoyos
Reimar Döffinger Reimar.Doeffinger at gmx.de writes:

 Are there still objections?

I just wanted to know if we shouldn't always set ASP?
Or at least for everything != SP?

Carl Eugen

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-02 Thread Reimar Döffinger
On Sun, Nov 02, 2014 at 10:02:50AM +, Carl Eugen Hoyos wrote:
 Reimar Döffinger Reimar.Doeffinger at gmx.de writes:
 
  Are there still objections?
 
 I just wanted to know if we shouldn't always set ASP?
 Or at least for everything != SP?

I am unsure. It seemed to me this way would be more reliable
and ensure we review it if we were to ever add a new profile.
But if anyone has a real opinion on it I'll happily follow it.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread Reimar Döffinger
This is a regression, previous code did not require
users to set the profile to use VDPAU.
In addition, ASP is a superset of SP, so there is not
even a good reason to require it.
---
 libavcodec/vdpau_mpeg4.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/vdpau_mpeg4.c b/libavcodec/vdpau_mpeg4.c
index 2a036b6..02ed4d1 100644
--- a/libavcodec/vdpau_mpeg4.c
+++ b/libavcodec/vdpau_mpeg4.c
@@ -119,6 +119,7 @@ static int vdpau_mpeg4_init(AVCodecContext *avctx)
 case FF_PROFILE_MPEG4_SIMPLE:
 profile = VDP_DECODER_PROFILE_MPEG4_PART2_SP;
 break;
+case FF_PROFILE_UNKNOWN:
 case FF_PROFILE_MPEG4_ADVANCED_SIMPLE:
 profile = VDP_DECODER_PROFILE_MPEG4_PART2_ASP;
 break;
-- 
2.1.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread wm4
On Sat,  1 Nov 2014 13:45:46 +0100
Reimar Döffinger reimar.doeffin...@gmx.de wrote:

 This is a regression, previous code did not require
 users to set the profile to use VDPAU.

It still doesn't...?

There are basically 3 ffmpeg vdpau hwaccel APIs now.

 In addition, ASP is a superset of SP, so there is not
 even a good reason to require it.
 ---
  libavcodec/vdpau_mpeg4.c | 1 +
  1 file changed, 1 insertion(+)
 
 diff --git a/libavcodec/vdpau_mpeg4.c b/libavcodec/vdpau_mpeg4.c
 index 2a036b6..02ed4d1 100644
 --- a/libavcodec/vdpau_mpeg4.c
 +++ b/libavcodec/vdpau_mpeg4.c
 @@ -119,6 +119,7 @@ static int vdpau_mpeg4_init(AVCodecContext *avctx)
  case FF_PROFILE_MPEG4_SIMPLE:
  profile = VDP_DECODER_PROFILE_MPEG4_PART2_SP;
  break;
 +case FF_PROFILE_UNKNOWN:
  case FF_PROFILE_MPEG4_ADVANCED_SIMPLE:
  profile = VDP_DECODER_PROFILE_MPEG4_PART2_ASP;
  break;

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread Carl Eugen Hoyos
Reimar Döffinger Reimar.Doeffinger at gmx.de writes:

 +case FF_PROFILE_UNKNOWN:
  case FF_PROFILE_MPEG4_ADVANCED_SIMPLE:
  profile = VDP_DECODER_PROFILE_MPEG4_PART2_ASP;

Could instead be the default case to set profile to ASP?
Or to remove this whole logic?

Carl Eugen

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread Jean-Baptiste Kempf
On 01 Nov, Reimar Döffinger wrote :
 This is a regression, previous code did not require
 users to set the profile to use VDPAU.

If you don't set the profile, how can you know that the hardware
supports it?

-- 
Jean-Baptiste Kempf
http://www.jbkempf.com/ - +33 672 704 734
Sent from my Electronic Device
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread Carl Eugen Hoyos
Jean-Baptiste Kempf jb at videolan.org writes:

 On 01 Nov, Reimar Döffinger wrote :
  This is a regression, previous code did not require
  users to set the profile to use VDPAU.
 
 If you don't set the profile, how can you know that 
 the hardware supports it?

Does this have any relevance for ASP?

Carl Eugen

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread Reimar Döffinger
On Sat, Nov 01, 2014 at 02:18:06PM +0100, Jean-Baptiste Kempf wrote:
 On 01 Nov, Reimar Döffinger wrote :
  This is a regression, previous code did not require
  users to set the profile to use VDPAU.
 
 If you don't set the profile, how can you know that the hardware
 supports it?

Firstly: As I said, SP is a subset of ASP, so if the hardware supports ASP
it supports SP.
Secondly: The code actually interacting with the hardware can handle
that. There is no need for the FFmpeg decoder to require that
information.
Obviously I can just hack around this by setting it to ASP if it's
unknown, but I'd like a good reason why that is a better solution than
graceful degradation here.

Only slightly related:
I generally dislike that part of the design as it mixes up the whole VDPAU
structure/bitstream generation with the actual hardware decoding,
which is a pain if you want to use security feature like process
separation of decoding (which is a higher security risk) from
actual display.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread Reimar Döffinger
On Sat, Nov 01, 2014 at 01:52:17PM +0100, wm4 wrote:
 On Sat,  1 Nov 2014 13:45:46 +0100
 Reimar Döffinger reimar.doeffin...@gmx.de wrote:
 
  This is a regression, previous code did not require
  users to set the profile to use VDPAU.
 
 It still doesn't...?

It does if you want the hwaccel API.

 There are basically 3 ffmpeg vdpau hwaccel APIs now.

(possibly 4 depending on how you could, but)
Adding the newest one because of this code had the
side-effect that you now need to set the profile
even for the older ones (not for the oldest one
using mpeg4_vdpau though it seems?).
Obviously it would be possible to just skip this in the
case of the older API, but as said I see no good reason.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vdpau_mpeg4: Do not fail on unknown profile.

2014-11-01 Thread wm4
On Sat, 1 Nov 2014 15:13:17 +0100
Reimar Döffinger reimar.doeffin...@gmx.de wrote:

 On Sat, Nov 01, 2014 at 01:52:17PM +0100, wm4 wrote:
  On Sat,  1 Nov 2014 13:45:46 +0100
  Reimar Döffinger reimar.doeffin...@gmx.de wrote:
  
   This is a regression, previous code did not require
   users to set the profile to use VDPAU.
  
  It still doesn't...?
 
 It does if you want the hwaccel API.
 
  There are basically 3 ffmpeg vdpau hwaccel APIs now.
 
 (possibly 4 depending on how you could, but)
 Adding the newest one because of this code had the
 side-effect that you now need to set the profile
 even for the older ones (not for the oldest one
 using mpeg4_vdpau though it seems?).
 Obviously it would be possible to just skip this in the
 case of the older API, but as said I see no good reason.

That seems indeed like a bug, then. It would mean every API user got
broken. Nice job, Libav.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel