blob: a3d9b69ea97a66db4cd307afa954094d594b2dcd [file] [log] [blame]
// Copyright 2019 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <fuchsia/images/cpp/fidl.h>
#include <fuchsia/mem/cpp/fidl.h>
#include <png.h>
namespace forensics {
namespace feedback_data {
// Encodes |raw_image| in PNG.
// The only |pixel_format| supported today is BGRA_8.
bool RawToPng(const fuchsia::mem::Buffer& raw_image, size_t height, size_t width, size_t stride,
fuchsia::images::PixelFormat pixel_format, fuchsia::mem::Buffer* png_image);
} // namespace feedback_data
} // namespace forensics