You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-06-14 22:15:12 +02:00
Making it easier to send arbitrary structures as work orders to MT workers
Originally committed as revision 15804 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
@ -81,7 +81,7 @@ void avcodec_thread_free(AVCodecContext *s){
|
||||
av_freep(&s->thread_opaque);
|
||||
}
|
||||
|
||||
int avcodec_thread_execute(AVCodecContext *s, int (*func)(AVCodecContext *c2, void *arg2),void **arg, int *ret, int count){
|
||||
int avcodec_thread_execute(AVCodecContext *s, int (*func)(AVCodecContext *c2, void *arg2),void *arg, int *ret, int count, int size){
|
||||
ThreadContext *c= s->thread_opaque;
|
||||
int i;
|
||||
|
||||
@ -92,7 +92,7 @@ int avcodec_thread_execute(AVCodecContext *s, int (*func)(AVCodecContext *c2, vo
|
||||
|
||||
for(i=0; i<count; i++){
|
||||
|
||||
c[i].arg= arg[i];
|
||||
c[i].arg= (char*)arg + i*size;
|
||||
c[i].func= func;
|
||||
c[i].ret= 12345;
|
||||
|
||||
|
Reference in New Issue
Block a user