blob: 3089929c2cef05bfce6303308fa61cfc8de4cf30 [file] [log] [blame]
jwwang8247eef2014-01-14 15:48:20 +08001#ifndef __BASEENCODERTEST_H__
2#define __BASEENCODERTEST_H__
3
4#include "codec_api.h"
5#include "codec_app_def.h"
jwwang0c2227e2014-01-18 19:31:54 +08006#include "utils/InputStream.h"
jwwang8247eef2014-01-14 15:48:20 +08007
8class BaseEncoderTest {
9 public:
10 struct Callback {
11 virtual void onEncodeFrame(const SFrameBSInfo& frameInfo) = 0;
12 };
13
14 BaseEncoderTest();
15 void SetUp();
16 void TearDown();
Martin Storsjö04ca4ba2014-04-14 15:35:34 +030017 void EncodeFile(const char* fileName, int width, int height, float frameRate, SliceModeEnum slices, bool denoise, int layers, Callback* cbk);
18 void EncodeStream(InputStream* in, int width, int height, float frameRate, SliceModeEnum slices, bool denoise, int layers, Callback* cbk);
jwwang8247eef2014-01-14 15:48:20 +080019
20 private:
21 ISVCEncoder* encoder_;
22};
23
24#endif //__BASEENCODERTEST_H__