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
165acf14
Commit
165acf14
authored
Jul 01, 2004
by
Gildas Bazin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/codec/dmo/dmo.c: small fix to CopyPicture()
parent
4f8b045e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
8 deletions
+5
-8
modules/codec/dmo/dmo.c
modules/codec/dmo/dmo.c
+5
-8
No files found.
modules/codec/dmo/dmo.c
View file @
165acf14
...
@@ -79,6 +79,7 @@ struct decoder_sys_t
...
@@ -79,6 +79,7 @@ struct decoder_sys_t
IMediaObject
*
p_dmo
;
IMediaObject
*
p_dmo
;
int
i_min_output
;
int
i_min_output
;
uint8_t
*
p_buffer
;
audio_date_t
end_date
;
audio_date_t
end_date
;
};
};
...
@@ -374,6 +375,8 @@ static int DecoderOpen( vlc_object_t *p_this )
...
@@ -374,6 +375,8 @@ static int DecoderOpen( vlc_object_t *p_this )
msg_Dbg
(
p_dec
,
"GetOutputSizeInfo(): bytes %i, align %i"
,
msg_Dbg
(
p_dec
,
"GetOutputSizeInfo(): bytes %i, align %i"
,
i_size
,
i_align
);
i_size
,
i_align
);
p_sys
->
i_min_output
=
i_size
;
p_sys
->
i_min_output
=
i_size
;
p_sys
->
p_buffer
=
malloc
(
i_size
);
if
(
!
p_sys
->
p_buffer
)
goto
error
;
}
}
}
}
...
@@ -421,6 +424,7 @@ void DecoderClose( vlc_object_t *p_this )
...
@@ -421,6 +424,7 @@ void DecoderClose( vlc_object_t *p_this )
FreeLibrary
(
p_sys
->
hmsdmo_dll
);
FreeLibrary
(
p_sys
->
hmsdmo_dll
);
if
(
p_sys
->
p_buffer
)
free
(
p_sys
->
p_buffer
);
free
(
p_sys
);
free
(
p_sys
);
}
}
...
@@ -508,7 +512,7 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -508,7 +512,7 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
}
}
/* Get output from the DMO */
/* Get output from the DMO */
block_out
.
p_buffer
=
malloc
(
p_sys
->
i_min_output
)
;
block_out
.
p_buffer
=
p_sys
->
p_buffer
;
;
block_out
.
i_buffer
=
0
;
block_out
.
i_buffer
=
0
;
p_out
=
CMediaBufferCreate
(
&
block_out
,
p_sys
->
i_min_output
,
VLC_FALSE
);
p_out
=
CMediaBufferCreate
(
&
block_out
,
p_sys
->
i_min_output
,
VLC_FALSE
);
...
@@ -531,7 +535,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -531,7 +535,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
#endif
#endif
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
free
(
block_out
.
p_buffer
);
return
NULL
;
return
NULL
;
}
}
...
@@ -545,7 +548,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -545,7 +548,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
{
{
msg_Dbg
(
p_dec
,
"GetBufferAndLength(): failed"
);
msg_Dbg
(
p_dec
,
"GetBufferAndLength(): failed"
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
free
(
block_out
.
p_buffer
);
return
NULL
;
return
NULL
;
}
}
...
@@ -555,7 +557,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -555,7 +557,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
msg_Dbg
(
p_dec
,
"ProcessOutput(): no output (i_buffer_out == 0)"
);
msg_Dbg
(
p_dec
,
"ProcessOutput(): no output (i_buffer_out == 0)"
);
#endif
#endif
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
free
(
block_out
.
p_buffer
);
return
NULL
;
return
NULL
;
}
}
...
@@ -572,7 +573,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -572,7 +573,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
aout_DateIncrement
(
&
p_sys
->
end_date
,
1
);
aout_DateIncrement
(
&
p_sys
->
end_date
,
1
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
free
(
block_out
.
p_buffer
);
return
p_pic
;
return
p_pic
;
}
}
...
@@ -592,7 +592,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -592,7 +592,6 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
aout_DateIncrement
(
&
p_sys
->
end_date
,
i_samples
);
aout_DateIncrement
(
&
p_sys
->
end_date
,
i_samples
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
p_out
->
vt
->
Release
(
(
IUnknown
*
)
p_out
);
free
(
block_out
.
p_buffer
);
return
p_aout_buffer
;
return
p_aout_buffer
;
}
}
...
@@ -615,8 +614,6 @@ static void CopyPicture( decoder_t *p_dec, picture_t *p_pic, uint8_t *p_in )
...
@@ -615,8 +614,6 @@ static void CopyPicture( decoder_t *p_dec, picture_t *p_pic, uint8_t *p_in )
i_width
=
p_pic
->
p
[
i_plane
].
i_visible_pitch
;
i_width
=
p_pic
->
p
[
i_plane
].
i_visible_pitch
;
i_dst_stride
=
p_pic
->
p
[
i_plane
].
i_pitch
;
i_dst_stride
=
p_pic
->
p
[
i_plane
].
i_pitch
;
p_src
+=
i_width
;
for
(
i_line
=
0
;
i_line
<
p_pic
->
p
[
i_plane
].
i_lines
;
i_line
++
)
for
(
i_line
=
0
;
i_line
<
p_pic
->
p
[
i_plane
].
i_lines
;
i_line
++
)
{
{
p_dec
->
p_vlc
->
pf_memcpy
(
p_dst
,
p_src
,
i_width
);
p_dec
->
p_vlc
->
pf_memcpy
(
p_dst
,
p_src
,
i_width
);
...
...
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