Skip to content
A Flutter 3D widget that renders Wavefront's object files.
Dart Swift Ruby Kotlin Objective-C
Branch: master
Clone or download
Latest commit 6b38255 Dec 25, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.vscode update example Dec 19, 2019
example add and example Dec 25, 2019
lib change package name Dec 23, 2019
resource add and example Dec 25, 2019
test initial commit Dec 13, 2019
.gitignore initial commit Dec 13, 2019
CHANGELOG.md change package name Dec 23, 2019
LICENSE initial commit Dec 13, 2019
README.md add and example Dec 25, 2019
pubspec.lock change package name Dec 23, 2019
pubspec.yaml change package name Dec 23, 2019

README.md

Flutter Cube

pub package A Flutter 3D widget that renders Wavefront's object files.

Getting Started

Add flutter_cube as a dependency in your pubspec.yaml file.

dependencies:
  flutter_cube: ^0.0.1

Add Wavefront's object files to assets.

flutter:
  assets:
    - assets/cube/cube.obj
    - assets/cube/cube.mtl
    - assets/cube/flutter.png
import 'package:flutter_cube/flutter_cube.dart';
... ...
  
@override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Center(
        child: Cube(
          onSceneCreated: (Scene scene) {
            scene.world.add(Object(fileName: 'assets/cube/cube.obj'));
          },
        ),
      ),
    );
  }

Screenshot

screenshot screenshot

You can’t perform that action at this time.