i42output / neoGFX

Cross-platform GPU-oriented C++ application/game framework
http://neogfx.org/
GNU General Public License v3.0
542 stars 51 forks source link

Please drop any though about scripting! #109

Closed SzykCech4 closed 5 months ago

SzykCech4 commented 5 years ago

Hi First of all: I am amazed by your project! In my opinion there is huge need for true C++ cross platform library (desktop, mobile and embeded). I like every you do, but one thing I hate: Scripting language. Please drop this mad idea entirely! This kill Qt in my eyes an in my heart. There are at least few reasons to not implement this:

  1. It consumes a lot of time. You have more important things to do: multiplatform and first release.
  2. It require from C++ programmer write mad code - please do not force us to this night mare like in Qt.
  3. It works slow - we are C++ programmers because of unbeatable speed (among others advantages).

keep working and best regards Szyk Cech

i42output commented 5 years ago

Hi Szyk,

Thanks for you interest in neogfx!

Originally neogfx was just going to be a C++ GUI library for which, I agree with you, has little need for a scripting engine however the scope of neogfx has changed. neogfx is now a C++ app/game engine for which a scripting language is more appropriate but you should not be concerned for three reasons:

  1. Using a scripting language is entirely optional: there is nothing you can do with a scripting language that you cannot do easily using native C++; a scripting language is just a convenience for those who want a more dynamic approach.
  2. The scripting engine neogfx will use, "neos", will support multiple "standard" scripting/programming languages in addition to the neogfx scripting language "neoscript". neos will also have a JIT which should alleviate concerns about it being slow.
  3. I will resume mainline neogfx development once neos and neoscript are in a usable state; work on support for other languages in neos will be done in slow time.

Regards, Leigh Johnston.

blockspacer commented 5 years ago

cling based C++ as scripting language / hot code reload Why? Able to run C++ script in runtime or compile it for max speed ( as in example https://github.com/derofim/cling-cmake ) Also: May be used to improve modules compile time

HOT code reload possible approaches:

store app state fix cling undo for files https://root-forum.cern.ch/t/loading-unloading-class-as-interpreted-macro-in-cling-multiple-times/32976/2

execute cling code to change callbacks & variables nested cling::Interpreter with multiple cling::MetaProcessor IDK how to do it, but you can create child cling::Interpreter

i42output commented 5 years ago

Hi blockspacer,

neoGFX will be using neos (https://neos.dev) for its scripting.

Regards, Leigh Johnston.

blockspacer commented 5 years ago

neos seems very cool.

Note that Cling may be used to improve development workflow, not only as scripting engine.

Develop much faster with Cling help (dev/debug build of existing code), release same code compiled without Cling at all (release build).