oid

Version, currently master branch1 version
  • master branchlatestSep 14, 2022

github.com/spoved/oid.cr

No description declared in shard.yml.

0 stars
0 dependents
License: MIT

Installation

# Add this to your shard.yml
dependencies:
  oid:
    github: spoved/oid.cr
    branch: master

master is a branch, not a release, so this tracks it rather than pinning a version.

Then run:

shards install

shard.yml

Crystal
>= 1.4.0, < 2.0.0
License
MIT
Author
Holden Omans
Targets
  • oid-cli from src/bin/oid.cr
  • example_01 from examples/01/main.cr
  • example_02 from examples/02/main.cr
  • example_03 from examples/03/main.cr
  • example_04 from examples/04/main.cr
  • example_05 from examples/05/main.cr

Dependencies

Runtime Dependencies

  • crinja*github: straight-shoota/crinja
  • spoved~> 0.6.0github: spoved/spoved.cr
  • admiral*github: jwaldrip/admiral.cr
  • entitas~> 1.4.5github: spoved/entitas.cr
  • entitas-web~> 0.1.2github: kalinon/entitas-web
  • baked_file_system*github: schovi/baked_file_system, branch: master

Development Dependencies

  • sentry*github: samueleaton/sentry, branch: masterdev

README

OID

A graphics library that is designed from the ground up to use Entity based architecture (entitas.cr). Still a work in progress.

Installation

  1. Add the dependency to your shard.yml:
dependencies:
  oid:
    github: spoved/oid.cr
  1. Run shards install

Usage

To generate an app shell, use the oid-cli to generate the base system and controllers.

From the root of your project:

cd ./lib/oid
./bin/oid-cli gen <project_name> ../../src

Then simply require the generated main.cr into your entrypoint. Check the TODOs in each of the generated files for places to add your code and examples.

Development

Required tools/libs:

  • llvm >= 8
  • cmake >= 3.14
  • raylib ~> 3.4.0

Mac OSX

brew install llvm cmake raylib

Build raylib bindings:

git submodule update --init --recursive
export CLANG_BINARY=/usr/local/opt/llvm/bin/clang++
cmake .
make bindings

or run ./build.sh

Linux

Will add instructions in the future

Windows

Not supported at this time

Contributing

  1. Fork it (https://github.com/spoved/oid/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Credit

Vector logic/code:

https://github.com/ajselvig/crystal_vector_math https://github.com/garnet-engine/math https://github.com/unn4m3d/crystaledge

Contributors