Programmer Unveils OpenGL Bindings for Bash (opensource.com)
Slashdot reader silverdirk writes: Compiled languages have long provided access to the OpenGL API, and even most scripting languages have had OpenGL bindings for a decade or more. But, one significant language missing from the list is our old friend/nemesis Bash. But worry no longer! Now you can create your dazzling 3D visuals right from the comfort of your command line!
"You'll need a system with both Bash and OpenGL support to experience it firsthand," explains software engineer Michael Conrad, who created the first version 13 years ago as "the sixth in a series of 'Abuse of Technology' projects," after "having my technical sensibilities offended that someone had written a real-time video game in Perl.
"Back then, my primary language was C++, and I was studying OpenGL for video game purposes. I declared to my friends that the only thing worse would be if it had been 3D and written in Bash. Having said the idea out loud, it kept prodding me, and I eventually decided to give it a try to one-up the 'awfulness'..."
"You'll need a system with both Bash and OpenGL support to experience it firsthand," explains software engineer Michael Conrad, who created the first version 13 years ago as "the sixth in a series of 'Abuse of Technology' projects," after "having my technical sensibilities offended that someone had written a real-time video game in Perl.
"Back then, my primary language was C++, and I was studying OpenGL for video game purposes. I declared to my friends that the only thing worse would be if it had been 3D and written in Bash. Having said the idea out loud, it kept prodding me, and I eventually decided to give it a try to one-up the 'awfulness'..."
imagine Fortune at 60 fps with 16x SOAA, God rays on Ultra and hair works. It would be glorious.
Hi! I make Firefox Plug-ins. Check 'em out @ https://addons.mozilla.org/en-US/firefox/addon/youtube-mp3-podcaster/
I thought that the Gtk Server allowed one to use GtkGlArea in scripts.
Ezekiel 23:20
In the hands of responsible programmers. But what happens if you need to run a bash script from a character based console?
Too many simple utilities have morphed from: Here's a command-line tool, and here's an optional graphical UI that runs on top of it. Next, we'll merge the graphics right into the basic tool's codebase. So you need to link every hair-brained graphics lib to build it. Finally, the damned thing will refuse to run (even if you use all the text-only command line switches) if it can't find a bitmapped display.
Have gnu, will travel.
Command-line ads are coming
lucm, indeed.
Just imagine what 3D games would be like if they could be written in CMD batch language!
With the sarcasm.
I mean it is absurd that someone would use 64 bits to store a char, 40 times in a single program when they only have 10 gigabytes of ram!
They should really be repeating those declarations because there is NO WAY the compiler could ever figure that stuff out! Could you imagine what would happen if we didn't impose strict limits on how easy things were, people just wouldn't understand!
I MEAN WHAT WOULD THEY DO IF THEY HAD TO DECODE A PROTOCOL THAT WAS A SERIES OF BYTES WITH A CHECKSUM, THEY CERTAINLY WOULDN'T BE ABLE TO WRITE PROGRAMS AND SHARE THEM THAT ACTUALLY ACCOMPLISHED THAT ASTOUNDING FEAT!
And people NEVER having the chance to actually drive OFF ROAD!!!!
FOR SAFETY OF COURSE.
You fucking morons.
$ glxgears
(sees opengl)
Good enough for me!
Now lets see you do that in COBOL.
I for one, can't wait for someone to port Gorilla.BAS to 3D.
Or greater than 2.0 with shaders?
sed -e 's/Chuck Norris/Rajnikant/g' joke > fact
Anything but Direct3D!
Wasn't that the last piece of published code written by Bill Gates?
Can't we have more stories about "global warming" which invite us to share how we "feel" and how we are "concerened"? Stories about bash and OpenGL are too geeky for Slashdot.
Next step: OpenGL in emacs.
doesn't mean you should.
I mean if I was trying to make a joke about a C++ developer making shell scripts, I'd have used something like that.
I mean seriously, you don't write built-in commands for that. You create a specialized language and write an interpreter for it. Once you have that, you can easily access it from the shell.
You know how when you see the phrase for the first time in your life and you immediately realize how you have been missing this from your language for 30 years?
This is one of such phrases:
"comfort of my command line".
I do not believe in karma. "Funny"=-6. Do good and forbid evil. Yours, Oft-Offtopic Flamebaiting Troll.
Its called Blender, though it's "Python" and not "BASH." Matter of fact, a most of Linux programs have a headless mode. https://docs.blender.org/manua....
I prefer something more modern, like fish. ksh and zsh are ancient, obsolete garbage.
I might actually have a use for this. I'm part of a team developing scientific simulation software... we work a lot at the command-line and it is handy to be able to visualize solutions/inputs quickly. We have many tools for visualization - but having something built right into the command-line _might_ be useful (huge emphasis on *might*!).
I'll definitely check it out...
Proof-of-concept: OpenGL in emacs window
https://ncrmnt.org/2012/06/17/proof-of-concept-opengl-in-emacs-window/
Not that this should surprise anyone, of course...
fish looks extremely good - thanks!
What is this? News for nerds? I come here to read angry Americans telling other angry Americans how stupid they are. More Trump articles, please.
So I can open lots of terminal windows in my virtual house!
Perl's pretty stinky. It's like 10 languages all mashed together. To write it, you only need to know one of the 10. To read it, you never know which of the many duplicate features will be required. Also, it over-relies on regular expressions for doing things that could've taken less squinting.
Bash is more of a 4GL than a general purpose programming language. It's great at some things, and awful at others - but that's intentional. One thing about bash people often ignore: It's highly parallel on multicore systems, with a simple syntax - more so even than something like OCaml or Haskell. However, it's getting more line-noisy lately; it's not as elegant as plain old Bourne Shell was, which was remarkably similar to a Lisp variant if you think of a file's lines as being like the elements of a list.
I doubt Chet will be merging OpenGL patches to bash anytime soon. However, a GL-based zenity would be reasonable.
If you think this is what makes the unix shell superior to dos, you sure as hell don't know much about anything.
https://code.google.com/archiv...
I don't know fish but judging from what I've read here (https://www.slant.co/versus/523/1602/~zsh_vs_fish) I'm not convinced. The only benefit over zsh I really find good is a (supposedly) good default config. But I've configured zsh years ago and I'm still using that very efficient configuration today. That's what I call return of investment. Yes, it is not 100% intuitive to configure zsh but it's got a helpful community. I've even written my own completion extensions, so how hard can it be?
Calling zsh obsolete garbage implies you have not really used it.