[vlc-devel] compile fix for atmo

André Weber \(atmo\) WeberAndre at gmx.de
Sun Aug 3 19:41:55 CEST 2008


Hi Filippo,

for me the patch looks fine - but I can't commit currently :) don't have a working git tree - again -
when did the VLC thread API change - so that my code gots broken?
I didn't recognized the commit.

Why needs the threadproc to return a "void *" ?? -  and where is the "return" for this?
- so that patch may at least require a "return( NULL );" or something like that - to be
clean?

@to the others:
What was the reason to change the thread function signature?


André

--
atmo

----- Original Message ----- 
From: "Filippo Carone" <filippo at carone.org>
To: <vlc-devel at videolan.org>
Sent: Sunday, August 03, 2008 7:14 PM
Subject: [vlc-devel] compile fix for atmo


> Hi ppl,
> since I'm not sure I fixed it in the best way, please review the patch.
>
> Cheers,
> Filippo
>


--------------------------------------------------------------------------------


> >From 8f16ed6f7f54a9551c670417f7e62bc5e8697475 Mon Sep 17 00:00:00 2001
> From: Filippo Carone <littlejohn at videolan.org>
> Date: Sun, 3 Aug 2008 19:11:13 +0200
> Subject: [PATCH] atmo video filter compile fix
>
> ---
>  modules/video_filter/atmo/AtmoThread.cpp |    3 ++-
>  modules/video_filter/atmo/AtmoThread.h   |    2 +-
>  modules/video_filter/atmo/atmo.cpp       |    5 +++--
>  3 files changed, 6 insertions(+), 4 deletions(-)
>
> diff --git a/modules/video_filter/atmo/AtmoThread.cpp b/modules/video_filter/atmo/AtmoThread.cpp
> index 18abfc2..0fe47b3 100644
> --- a/modules/video_filter/atmo/AtmoThread.cpp
> +++ b/modules/video_filter/atmo/AtmoThread.cpp
> @@ -67,8 +67,9 @@ CThread::~CThread(void)
>
>  #if defined(_ATMO_VLC_PLUGIN_)
>
> -void CThread::ThreadProc(atmo_thread_t *pAtmoThread)
> +void* CThread::ThreadProc(vlc_object_t *p_vlc_object)
>  {
> +      atmo_thread_t *pAtmoThread = (atmo_thread_t *) p_vlc_object;
>        CThread *pThread = (CThread *)pAtmoThread->p_thread;
>        if(pThread) {
>           // give feedback I'am running?
> diff --git a/modules/video_filter/atmo/AtmoThread.h b/modules/video_filter/atmo/AtmoThread.h
> index a129e9f..49f9a39 100644
> --- a/modules/video_filter/atmo/AtmoThread.h
> +++ b/modules/video_filter/atmo/AtmoThread.h
> @@ -50,7 +50,7 @@ protected:
>  private:
>
>  #if defined(_ATMO_VLC_PLUGIN_)
> -    static void ThreadProc(atmo_thread_t *pAtmoThread);
> +    static void* ThreadProc(vlc_object_t *pAtmoThread);
>  #else
>   static DWORD WINAPI ThreadProc(LPVOID lpParameter);
>  #endif
> diff --git a/modules/video_filter/atmo/atmo.cpp b/modules/video_filter/atmo/atmo.cpp
> index 79b4ddb..b622f2a 100644
> --- a/modules/video_filter/atmo/atmo.cpp
> +++ b/modules/video_filter/atmo/atmo.cpp
> @@ -555,7 +555,7 @@ typedef struct
>
>  } fadethread_t;
>
> -static void FadeToColorThread(fadethread_t *p_fadethread);
> +static void* FadeToColorThread(vlc_object_t *p_vlc_object);
>
>
>  /*****************************************************************************
> @@ -1723,8 +1723,9 @@ static picture_t * Filter( filter_t *p_filter, picture_t *p_pic )
>  * to a target color defined in p_fadethread struct
>  * use for: Fade to Pause Color,  and Fade to End Color
>  *****************************************************************************/
> -static void FadeToColorThread(fadethread_t *p_fadethread)
> +static void* FadeToColorThread(vlc_object_t *p_vlc_object)
>  {
> +    fadethread_t *p_fadethread = (fadethread_t *) p_vlc_object;
>      filter_sys_t *p_sys = (filter_sys_t *)p_fadethread->p_filter->p_sys;
>      int i_steps_done = 0;
>      int i_index;
> -- 
> 1.5.4.3
>
>


--------------------------------------------------------------------------------


> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> http://mailman.videolan.org/listinfo/vlc-devel
>




More information about the vlc-devel mailing list