GithubHelp home page GithubHelp logo

wavefront-simple's Introduction

simple wavefront file writer

Build Status Coverage Status GPL 3+

about

This is a very simple writer for the Wavefront .obj file format describing 3D models.

The project homepage is at https://github.com/mmitch/wavefront-simple

example

This code

		// generate a cube at (0, 0, 0) with edge length 1
		Cube cube = new Cube(Coordinate.ORIGIN, 1);
		// write object to file
		cube.writeTo(new FileOutputStream("/tmp/cube.obj"));

creates an .obj file that looks like this:

V 0 0 0
V 0 0 1
V 0 1 0
V 0 1 1
V 1 0 0
V 1 0 1
V 1 1 0
V 1 1 1
f 1 3 4 2
f 1 3 7 5
f 1 5 6 2
f 2 4 8 6
f 3 7 8 4
f 5 7 8 6

usage

This is a library, no standalone program (although test executables are available in the de.cgarbs.wavefront.test.app package).

To include wavefront-simple in your project, add this to your build.gradle:

repositories {
    repositories {
        maven {
			name "cgarbs.de repo"
			url "https://www.cgarbs.de/maven2"
		}
	}
}

dependencies {
	compile 'de.cgarbs:wavefront-simple:0.6.0'
}

Note: You should propably update the version number (0.6.0 in the example above) to the most current version (see the HISTORY.md file).

The same coordinates should work for Maven projects, too.

build

Just run gradle, the project will configure, compile and then run the checks.

dependencies

  • Java 8
  • Gradle
  • further dependencies are fetched automatically, see build.gradle

further plans

  • centralize tests from Container subclasses into ContainerTest
  • add rotation operation(?)
  • add colors/textures(?)

copyright

wavefront-simple - generate simple 3D models in Wavefront .obj file format
Copyright (C) 2016 Christian Garbs <[email protected]>
Licensed under GNU GPL v3 (or later)

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

wavefront-simple's People

Contributors

mmitch avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.