summaryrefslogtreecommitdiffstats
path: root/third_party/jpeg-xl/lib/jxl/render_pipeline/render_pipeline.h
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/jpeg-xl/lib/jxl/render_pipeline/render_pipeline.h')
-rw-r--r--third_party/jpeg-xl/lib/jxl/render_pipeline/render_pipeline.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/third_party/jpeg-xl/lib/jxl/render_pipeline/render_pipeline.h b/third_party/jpeg-xl/lib/jxl/render_pipeline/render_pipeline.h
index bf3ad4975e..c61420be4b 100644
--- a/third_party/jpeg-xl/lib/jxl/render_pipeline/render_pipeline.h
+++ b/third_party/jpeg-xl/lib/jxl/render_pipeline/render_pipeline.h
@@ -32,7 +32,7 @@ class RenderPipelineInput {
}
RenderPipelineInput() = default;
- void Done();
+ Status Done();
const std::pair<ImageF*, Rect>& GetBuffer(size_t c) const {
JXL_ASSERT(c < buffers_.size());
@@ -63,7 +63,7 @@ class RenderPipeline {
// Finalizes setup of the pipeline. Shifts for all channels should be 0 at
// this point.
- std::unique_ptr<RenderPipeline> Finalize(
+ StatusOr<std::unique_ptr<RenderPipeline>> Finalize(
FrameDimensions frame_dimensions) &&;
private:
@@ -118,20 +118,20 @@ class RenderPipeline {
friend class RenderPipelineInput;
private:
- void InputReady(size_t group_id, size_t thread_id,
- const std::vector<std::pair<ImageF*, Rect>>& buffers);
+ Status InputReady(size_t group_id, size_t thread_id,
+ const std::vector<std::pair<ImageF*, Rect>>& buffers);
virtual std::vector<std::pair<ImageF*, Rect>> PrepareBuffers(
size_t group_id, size_t thread_id) = 0;
- virtual void ProcessBuffers(size_t group_id, size_t thread_id) = 0;
+ virtual Status ProcessBuffers(size_t group_id, size_t thread_id) = 0;
// Note that this method may be called multiple times with different (or
// equal) `num`.
- virtual void PrepareForThreadsInternal(size_t num, bool use_group_ids) = 0;
+ virtual Status PrepareForThreadsInternal(size_t num, bool use_group_ids) = 0;
// Called once frame dimensions and stages are known.
- virtual void Init() {}
+ virtual Status Init() { return true; }
};
} // namespace jxl