glfw_dart 0.1.0

  • Readme
  • Changelog
  • Example
  • Installing
  • 65

GLFW Dart #

dart:ffi bindings for GLFW library

Install #

Add this to pubspec.yaml:

  glfw_dart: ^0.1.0

Import it:

import 'package:glfw_dart/glfw3.dart';

Notice #1: .\glfw3.dll or /usr/lib/x86_64-linux-gnu/ will be automatically opened.

For manual GLFW initialization:

import 'package:glfw_dart/glfw3.dart';
void main(){
  glfw = Glfw(
    customPath: '<path-to-glfw3.dll-file>'

Notice #2: It is recommended to specify the path to glfw3.dll:


import 'dart:io';
import 'package:glfw_dart/glfw3.dart';
void main(){
  glfw = Glfw(customPath: Platform.isWindows ? "lib\\glfw3.dll" : null);

Alternatives #

Need to do #

  • Vulkan support
  • High level api (with streams, objects)

See also #


Changelog #

[0.1.0] - 13.02.2020 #

Deleted #

  • Wrapper development is canceled.

Changed #

  • No new API will be added!

[0.0.1] - 13.02.2020 #

Added #

  • Bindings for GLFW 3
  • Windows and Ubuntu only supported


GLFW Example #

Original from

third-party/glfw3.dll from

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  glfw_dart: ^0.1.0

2. Install it

You can install packages from the command line:

with pub:

$ pub get

with Flutter:

$ flutter pub get

Alternatively, your editor might support pub get or flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:glfw_dart/glfw3.dart';
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Mar 30, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.7.1
  • pana: 0.13.6

Health issues and suggestions

Document public APIs. (-0.81 points)

471 out of 474 API elements have no dartdoc comment.Providing good documentation for libraries, classes, functions, and other API elements improves code readability and helps developers find and use your API.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0 <3.0.0
ffi ^0.1.3 0.1.3
Dev dependencies
gl_dart any
pedantic any
test ^1.12.0