blob: 78a880720e9eb1081b05db76497492111a9a9463 [file] [log] [blame]
/*
* Copyright 2020 Google LLC
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "src/sksl/dsl/DSLCore.h"
#include "src/sksl/dsl/priv/DSLWriter.h"
namespace SkSL {
namespace dsl {
#if SK_SUPPORT_GPU && !defined(SKSL_STANDALONE)
void Start(SkSL::Compiler* compiler) {
DSLWriter::SetInstance(std::make_unique<DSLWriter>(compiler));
}
void End() {
DSLWriter::SetInstance(nullptr);
}
#endif // SK_SUPPORT_GPU && !defined(SKSL_STANDALONE)
void SetErrorHandler(ErrorHandler* errorHandler) {
DSLWriter::SetErrorHandler(errorHandler);
}
} // namespace dsl
} // namespace SkSL