umbra icon indicating copy to clipboard operation
umbra copied to clipboard

fix: Error: Member not found: 'FragmentProgram.compile'

Open cdmunoz opened this issue 1 year ago • 2 comments

Description

I'm getting a FragmentProgram.compile error after generate the flutter-widget through the CLI. This prevents to run the code.

The whole error:

lib/widgets/water_ripple.dart:41:25: Error: Member not found: 'FragmentProgram.compile'.
        FragmentProgram.compile(
                        ^^^^^^^
../../.pub-cache/hosted/pub.dev/umbra_flutter-0.1.0-dev.4/lib/src/umbra_widget.dart:88:32: Error: The method 'shader' isn't defined for the class 'FragmentProgram'.
 - 'FragmentProgram' is from 'dart:ui'.
Try correcting the name to the name of an existing method, or defining a method named 'shader'.
                return program.shader(
                               ^^^^^^
Target kernel_snapshot failed: Exception

Steps To Reproduce

  1. Add umbra_cli: 0.1.0-dev.4 and umbra_flutter: 0.1.0-dev.4 to pubspec.yaml
  2. Generate a flutter widget from any glsl file. (it could be the most basic one)
  3. Run the app.
  4. See error

image

Expected Behavior

No error after generating either a flutter widget or a pure dart shader

Additional Context

Flutter version: 3.13.4

Flutter 3.13.4 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 367f9ea16b (4 weeks ago) • 2023-09-12 23:27:53 -0500
Engine • revision 9064459a8b

cdmunoz avatar Oct 11 '23 21:10 cdmunoz