summaryrefslogtreecommitdiff
path: root/src/android/post_processor.h
blob: 4ac74fcf778d3d0e711b303c8aaa0ebc004d31ea (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/* SPDX-License-Identifier: LGPL-2.1-or-later */
/*
 * Copyright (C) 2020, Google Inc.
 *
 * post_processor.h - CameraStream Post Processing Interface
 */
#ifndef __ANDROID_POST_PROCESSOR_H__
#define __ANDROID_POST_PROCESSOR_H__

#include <libcamera/base/signal.h>

#include <libcamera/framebuffer.h>
#include <libcamera/stream.h>

#include "camera_buffer.h"
#include "camera_request.h"

class PostProcessor
{
public:
	enum class Status {
		Error,
		Success
	};

	virtual ~PostProcessor() = default;

	virtual int configure(const libcamera::StreamConfiguration &inCfg,
			      const libcamera::StreamConfiguration &outCfg) = 0;
	virtual int process(Camera3RequestDescriptor::StreamBuffer *streamBuffer) = 0;

	libcamera::Signal<Camera3RequestDescriptor::StreamBuffer *, Status> processComplete;
};

#endif /* __ANDROID_POST_PROCESSOR_H__ */