Hi Tim-
Thanks for the interest. "bindings" to perl means
a module that you can use from perl to access an
API (usually an external library of some sort). To
install these modules there are two parts: installing
the underlying libraries on your linux system and
then installing the desired perl modules.
The original perl OpenGL module which supports
OpenGL versions 1.x-2.x and some extensions is
the Perl OpenGL module (POGL). You can get it
via the various CPAN download/install tools
such as 'cpanm OpenGL'. I'm currently the poc
for the module which has been stable for years.
To use the latest OpenGL API versions, the
module to use is OpenGL::Modern which provides
support for the current and legacy APIs. It is
still in development but does allow one to use
all modern OpenGL features.
POGL includes OpenGL::GLUT for the GLUT or
FreeGLUT GUI library to make windows and...
I would recommend OpenGL::GLFW which
uses the GLFW library which is very lightweight
and may be sufficient for your needs.
As usual, you can use the CPAN infrastructure to
find out more about perl modules. E.g.,
https://metacpan.org/pod/OpenGL::Modern
On 3/9/2018 14:11, po...@41... wrote:
> Greetings,
>
> I did a bunch of Perl programming in the 1990s and am now looking to
> get back into some casual software development. I've got a small
> project I want to have a go at (a camera that orbits around a low-poly
> 3D scene in which objects morph over time) and am trying to work out
> what language(s) to implement it in.
>
> I'm running Ubuntu 16.04 (upgrading to 18.04 soon) and was originally
> planning to use WebGL (via three.js) in a browser (Firefox).
> Restrictions on local file access, however, make some aspects of that
> approach tricky (unless I set up a web server — which I'd prefer not
> to do).
>
> I stumbled across POGL and POGL2 and am wondering if this approach may
> be viable. I have no prior experience with "bindings".
>
>
> Obstacles:
>
> I can't locate a POGL tutorial that's less than ~10 years old, and
> cloning the Git repo using the SourceForge link (at
> https://sourceforge.net/p/pogl/pogl2/ref/master/) resulted in:
>
> $ git clone https://git.code.sf.net/p/pogl/pogl2 pogl-pogl2
> Cloning into 'pogl-pogl2'...
> warning: You appear to have cloned an empty repository.
> Checking connectivity... done.
>
> Yes, the resultant directory was empty.
>
>
> So, in summary, what I'd like to do is write a program that creates a
> window on Ubuntu and renders into it a 3D OpenGL scene with a moving
> camera. Due to a lack of current online documentation and an empty
> repo, I'm not sure if Perl5/POGL2 will let me do that — so I'm looking
> for advice on whether that approach is viable and, if so, maybe some
> pointers on how to get things up and running.
>
The perl modules implement the OpenGL API so there is
a lot of tutorial and example information out there.
> Any help would be appreciated. :)
>
> Cheers,
>
> Tim
>
> PS: On https://en.wikipedia.org/wiki/Perl_OpenGL the "Stable release"
> is listed as "0.66 / July 29, 2011; 6 years ago" — that creates a
> discouraging first impression and /probably/ should be updated.
>
The current OpenGL is from Oct-2016 and the current OpenGL::Modern
is from Aug-2017. There is an IRC for perl opengl stuff at #pogl on
irc.perl.org.
Hope this helps!
Chris
|