Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
a8f3c4ca
Commit
a8f3c4ca
authored
Nov 17, 2003
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* all: a little compil fix and more sanity checks (needed for wma).
parent
a48ec614
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
6 deletions
+14
-6
modules/codec/ffmpeg/audio.c
modules/codec/ffmpeg/audio.c
+6
-2
modules/codec/ffmpeg/video.c
modules/codec/ffmpeg/video.c
+8
-4
No files found.
modules/codec/ffmpeg/audio.c
View file @
a8f3c4ca
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* audio.c: audio decoder using ffmpeg library
* audio.c: audio decoder using ffmpeg library
*****************************************************************************
*****************************************************************************
* Copyright (C) 1999-2003 VideoLAN
* Copyright (C) 1999-2003 VideoLAN
* $Id: audio.c,v 1.2
2 2003/11/16 21:07:30 gbazin
Exp $
* $Id: audio.c,v 1.2
3 2003/11/17 02:52:39 fenrir
Exp $
*
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
* Gildas Bazin <gbazin@netcourrier.com>
* Gildas Bazin <gbazin@netcourrier.com>
...
@@ -160,7 +160,7 @@ aout_buffer_t *E_( DecodeAudio )( decoder_t *p_dec, block_t **pp_block )
...
@@ -160,7 +160,7 @@ aout_buffer_t *E_( DecodeAudio )( decoder_t *p_dec, block_t **pp_block )
return
NULL
;
return
NULL
;
}
}
if
(
!
p_block
->
i_buffer
)
if
(
p_block
->
i_buffer
<=
0
)
{
{
block_Release
(
p_block
);
block_Release
(
p_block
);
return
NULL
;
return
NULL
;
...
@@ -179,6 +179,10 @@ aout_buffer_t *E_( DecodeAudio )( decoder_t *p_dec, block_t **pp_block )
...
@@ -179,6 +179,10 @@ aout_buffer_t *E_( DecodeAudio )( decoder_t *p_dec, block_t **pp_block )
block_Release
(
p_block
);
block_Release
(
p_block
);
return
NULL
;
return
NULL
;
}
}
else
if
(
i_used
>
p_block
->
i_buffer
)
{
i_used
=
p_block
->
i_buffer
;
}
p_block
->
i_buffer
-=
i_used
;
p_block
->
i_buffer
-=
i_used
;
p_block
->
p_buffer
+=
i_used
;
p_block
->
p_buffer
+=
i_used
;
...
...
modules/codec/ffmpeg/video.c
View file @
a8f3c4ca
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* video.c: video decoder using the ffmpeg library
* video.c: video decoder using the ffmpeg library
*****************************************************************************
*****************************************************************************
* Copyright (C) 1999-2001 VideoLAN
* Copyright (C) 1999-2001 VideoLAN
* $Id: video.c,v 1.4
5 2003/11/16 22:23:47 gbazin
Exp $
* $Id: video.c,v 1.4
6 2003/11/17 02:52:39 fenrir
Exp $
*
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
* Gildas Bazin <gbazin@netcourrier.com>
* Gildas Bazin <gbazin@netcourrier.com>
...
@@ -392,7 +392,7 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
...
@@ -392,7 +392,7 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
return
VLC_SUCCESS
;
return
VLC_SUCCESS
;
}
}
if
(
!
p_sys
->
p_context
->
width
||
!
p_sys
->
p_context
->
height
)
if
(
p_sys
->
p_context
->
width
<=
0
||
p_sys
->
p_context
->
height
<=
0
)
{
{
p_sys
->
p_context
->
hurry_up
=
5
;
p_sys
->
p_context
->
hurry_up
=
5
;
}
}
...
@@ -403,7 +403,7 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
...
@@ -403,7 +403,7 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
/* Don't forget that ffmpeg requires a little more bytes
/* Don't forget that ffmpeg requires a little more bytes
* that the real frame size */
* that the real frame size */
if
(
p_block
->
i_buffer
)
if
(
p_block
->
i_buffer
>
0
)
{
{
p_sys
->
i_buffer
=
p_block
->
i_buffer
;
p_sys
->
i_buffer
=
p_block
->
i_buffer
;
if
(
p_sys
->
i_buffer
+
FF_INPUT_BUFFER_PADDING_SIZE
>
if
(
p_sys
->
i_buffer
+
FF_INPUT_BUFFER_PADDING_SIZE
>
...
@@ -424,7 +424,7 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
...
@@ -424,7 +424,7 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
p_block
->
i_buffer
=
0
;
p_block
->
i_buffer
=
0
;
}
}
while
(
p_sys
->
i_buffer
)
while
(
p_sys
->
i_buffer
>
0
)
{
{
int
i_used
,
b_gotpicture
;
int
i_used
,
b_gotpicture
;
picture_t
*
p_pic
;
picture_t
*
p_pic
;
...
@@ -439,6 +439,10 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
...
@@ -439,6 +439,10 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
block_Release
(
p_block
);
block_Release
(
p_block
);
return
NULL
;
return
NULL
;
}
}
else
if
(
i_used
>
p_sys
->
i_buffer
)
{
i_used
=
p_sys
->
i_buffer
;
}
/* Consumed bytes */
/* Consumed bytes */
p_sys
->
i_buffer
-=
i_used
;
p_sys
->
i_buffer
-=
i_used
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment