microsoft/onnxruntime-extensions
Publicmirrored from https://github.com/microsoft/onnxruntime-extensionsAvailable
base/base64.h
10lines · modeblame
a98c29f6Xavier Dupré5 years ago | 1 | // Copyright (c) Microsoft Corporation. All rights reserved. |
| 2 | // Licensed under the MIT License. | |
| 3 | // Freely inspired from https://en.wikibooks.org/wiki/Algorithm_Implementation/Miscellaneous/Base64 | |
| 4 | #pragma once | |
| 5 | #include <string> | |
| 6 | #include <vector> | |
01e3a636Wenbing Li2 years ago | 7 | #include <cstdint> |
a98c29f6Xavier Dupré5 years ago | 8 | |
| 9 | bool base64_encode(const std::vector<uint8_t>& input, std::string& encoded); | |
| 10 | bool base64_decode(const std::string& encoded, std::vector<uint8_t>& raw); |