Coder Social home page Coder Social logo

Comments (6)

boberfly avatar boberfly commented on August 15, 2024 1

Hi @fire actually I have it in a scratch branch here on my machine but unfortunately didn't continue on with it due to other commitments. I can push what I have to my fork when I get around to it if you'd like, so it's not wasted work.

Cheers

from materialx.

jstone-lucasfilm avatar jstone-lucasfilm commented on August 15, 2024

Hi @boberfly, this sounds like a very reasonable proposal to me, and I could imagine a wrapper mechanism similar to the one in SPIRV-Cross, where a library-wide helper function selects between throwing exceptions and exiting the program with an error message.

If we took this approach in MaterialX, we would likely want to add an Exception.h header to MaterialXCore, which would define the appropriate wrapper functions and include <exception> only when required.

Let us know how your plans proceed, and we'd be open to a pull request if you find that you need the ability to disable exceptions in your runtime.

from materialx.

boberfly avatar boberfly commented on August 15, 2024

Hi @jstone-lucasfilm

I've already started something similar to what SPIRV-Cross is doing locally here. I'll see how I go time-wise and propose a PR. Currently it is a bunch of macros everywhere and modifying MaterialXCore/Library.h, but I only modified the modules that were needed eg. Core/Format/GenGlsl/GenShader so far.

I'll continue with this with a test project to see how it works in practice.

Cheers

from materialx.

fire avatar fire commented on August 15, 2024

How is the progress on removing exceptions? This is still important for game engines like Godot Engine.

(This was in the wrong thread.)

from materialx.

fire avatar fire commented on August 15, 2024

@boberfly Thanks for your offer.

This is a notification! \o\

from materialx.

jstone-lucasfilm avatar jstone-lucasfilm commented on August 15, 2024

@boberfly I'm going to close out this issue for now, but it sounds like a good feature proposal, and feel free to revisit this issue if you have the bandwidth to move it forward.

from materialx.

Related Issues (20)

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.