Switch runtime effect fuzzer to use MakeForShader
New entry point that does stricter checking on SkSL validity. Bug: skia:11813 Change-Id: Icc8501c108af278e2fe1029859a552ea6ab6eb08 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/401056 Reviewed-by: Kevin Lubick <kjlubick@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
This commit is contained in:
parent
e3fa745a5a
commit
fbc06d831f
@ -36,7 +36,7 @@ static bool FuzzSkRuntimeEffect_Once(sk_sp<SkData> bytes, const SkRuntimeEffect:
|
||||
sk_sp<SkData> codeBytes = SkData::MakeSubset(bytes.get(), 0, bytes->size() - kReservedBytes);
|
||||
|
||||
SkString shaderText{static_cast<const char*>(codeBytes->data()), codeBytes->size()};
|
||||
SkRuntimeEffect::Result result = SkRuntimeEffect::Make(shaderText, options);
|
||||
SkRuntimeEffect::Result result = SkRuntimeEffect::MakeForShader(shaderText, options);
|
||||
SkRuntimeEffect* effect = result.effect.get();
|
||||
|
||||
if (!effect || effect->uniformSize() > kReservedBytes) { // if there is not enough uniform bytes
|
||||
|
Loading…
Reference in New Issue
Block a user