umc_h264_thread.h

来自「audio-video-codecs.rar语音编解码器」· C头文件 代码 · 共 76 行

H
76
字号
/*
//
//              INTEL CORPORATION PROPRIETARY INFORMATION
//  This software is supplied under the terms of a license  agreement or
//  nondisclosure agreement with Intel Corporation and may not be copied
//  or disclosed except in  accordance  with the terms of that agreement.
//        Copyright (c) 2003-2007 Intel Corporation. All Rights Reserved.
//
//
*/
#include "umc_defs.h"
#if defined (UMC_ENABLE_H264_VIDEO_DECODER)

#ifndef __UMC_H264_THREAD_H
#define __UMC_H264_THREAD_H

#include "umc_event.h"
#include "umc_thread.h"

namespace UMC
{

class H264Thread : public Thread
{
public:
    // Default constructor
    H264Thread();
    // Destructor
    virtual ~H264Thread();

    void Reset();

    // Initialize slice decoder
    Status Init(Ipp32s iNumber);

    virtual Status ProcessSegment() = 0;

    // Start decoding asynchronously
    Status StartProcessing();
    // Wait for end of asynchronous decoding
    Status WaitForEndOfProcessing();

protected:
    // Release slice decoder
    void Release(void);

    Ipp32s m_iNumber;                                           // ordinal number of decoder

    //
    // Threading routines
    //

    // Starting routine for decoding thread
    static Ipp32u VM_THREAD_CALLCONVENTION DecodingThreadRoutine(void *p);

    Event m_startProcessing;                                   // event to start asynchronous processing
    Event m_doneProcessing;                                    // event to show end of processing

    volatile bool m_bQuit;                                     // quit flag for additional thread(s)
    Status m_Status;                                           // async return value

private:
    // we lock assignment operator to avoid any
    // accasionaly assignments
    H264Thread & operator = (H264Thread &)
    {
        return *this;
    } // H264SliceDecoder & operator = (H264SliceDecoder &)

};

} // namespace UMC

#endif // __UMC_H264_THREAD_H
#endif // UMC_ENABLE_H264_VIDEO_DECODER

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?