Code Monkey home page Code Monkey logo

sprytile's Issues

Transparency Support for Unlit Material

Summary

Add alpha clip transparency to unlit shader. The graph should look similar to the below:

image

Notes

  1. The node setup is done by the SPRYTILE_OT_SetupMaterial operator.
  2. The material blend mode needs to be set to Alpha Clip.

Fix BGL Module Usage

Summary

Blender 2.80 removed several methods from the bgl module and has broken how Sprytile draws GUI elements in the 3D viewport.

Repro

Clicking on any of the Sprytile tools (Fill, Paint, Build) will cause the GUI to be drawn in the 3D viewport. This will crash Blender 2.80 as several module methods are missing entirely.

Sprytile GUI in Blender 2.79

image

  • Palette of selectable tiles in viewport.
  • Preview of tile to be placed (white outline + alpha transparency) in viewport.
  • Preview grid of where tiles will be placed (not pictured above).

Notes

  1. The usage of this module is mostly isolated to sprytile_gui.py except a single reference in sprytile_utils.py.

  2. The best practices going forward is to avoid using OpenGL directly (via the bgl module) and prefer the usage of the gpu module.

  3. Blender 2.80 prefers addon panels to live in the Properties panel on the right. Sprytile used to live in the Tools panel on the left. Placement of the tile palette might need more thought.

References

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.