Code Monkey home page Code Monkey logo

model3d's Introduction

model3d

Casa de la Muntanya's model3d is a blank canvas to project digital data layers and custom simulations over a physical 3D representation of the Andorran orography, using the Processing environment.

This library provides the base interfaces and classes to develop visualizations.

Getting started

Clone this repo into the Processing libraries directory.

[re]start Processing and include desired packages.

import ad.casadelamuntanya.model3d.*;
import ad.casadelamuntanua.model3d.feature.*;
import ad.casadelamuntanua.model3d.surface.*;

import com.vividsolutions.jts.geom.CoordinateSequenceFilter;

There is a known issue with the sketch requiring to import CoordinateSequenceFilter from jts.

Development

This code is intended to keep as much generic as possible and not all functionalities developed in a custom sketch must be included. Cool stuff may be, though.

To include new features into the library, add/edit files in the src directory and un the provided bash build script the compile it.

./build

Note that src/code must contain jts.jar and warp.jar files

New .jar file will be generated and moved to the appropriate directory. Commit changes and open a Pull Request.

model3d's People

Watchers

 avatar  avatar

model3d's Issues

Include WarpSurface (+ fellow)

WarpSurface (and all fellow classes) are in a standalone OBSA's package. For convenience it should be in this one.
Some rewrite will be necessary before bundling it here.

Break when Dictionary language or entry does not exist

Trying to use a language not existing in the dictionaries list, or an invalid key breaks the whole sketch.

Options:

  • Throw an exception
  • Return a blank string
  • Return the language.key string to indicate that there must go a text
  • Return a fallback string in the default language

Draw implementation should not be in library classes

Library classes (like SceneCollection or ScenesIterators) are absolutely tied to their draw implementation.

This is a huge NO-NO

A Drawer should that takes the responsibility of the drawing implementation should be injected for every drawable element.
Actually the Drawable interface is already defined, and all generic / abstract classes should implement it.

Add Scene life hooks

Include at least onEnter and onLeave life hooks for Scene classes to allow any kind of initialization or finalization actions, specially when changing is in SceneCollection

SceneIterator not very flexible

SceneIterator is defined as a decorator class for ScenesCollection class, making it very unflexible for extension.

Proposed solution:

  • SceneIterator to be an interface abstract class
  • SceneIterator to have defined lifecycle hooks
  • SceneIterator classes to be injected into ScenesCollection as a dependency.
  • SceneIterator classes to be decorable to themselves, but not to ScenesCollection.

CoordinateSequenceFilter dependency is needed

Sketch requires to import CoordinateSequenceFilter. Any of the other jts classes are required after compiling, only this one.

The type com.vividsolutions.jts.geom.CoordinateSequenceFilter cannot be resolved. It is indirectly referenced from required .class files

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.