22 минуты введение а где полезная информация с примерами
@Antonnel7 Жыл бұрын
Недостает обучающих примеров вроде таких @override Widget build(BuildContext context) { return Scaffold( body: Center( child: SizedBox( width: 400, height: 300, child: FutureBuilder( /// The surface size identifies the real texture size and /// it is not related to the above SizedBox size future: OpenGLController().openglPlugin.createSurface(300, 200), builder: (_, snapshot) { if (snapshot.hasError || !snapshot.hasData) { return const SizedBox.shrink(); } /// When the texture id is got, it will be possible /// to start renderer, set a shader and display it /// Start renderer thread OpenGLController().openglFFI.startThread(); /// Set the fragment shader OpenGLController().openglFFI.setShaderToy(fShader); /// build the texture widget return OpenGLTexture(id: snapshot.data!); }, ), ), ), ); }