Acme-MITHALDU-BleedingOpenGL
    
    
  
  
  
view release on metacpan or search on metacpan
FreeGLUT/freeglut-Readme.txt view on Meta::CPAN
Installation
Create a folder on your PC which is readable by all users, for example
C:\Program Files\Common Files\MSVC\freeglut\ on a typical Windows system. Copy
the lib\ and include\ folders from this zip archive to that location.
The appropriate freeglut DLL can either be placed in the same folder as your
application, or can be installed in a system-wide folder which appears in your
%PATH% environment variable. Be careful not to mix the 32 bit DLL up with the 64
bit DLL, as they are not interchangeable.
Compiling 32 bit Applications
To create a 32 bit freeglut application, create a new Win32 C++ project in MSVC.
From the Win32 Application Wizard, choose a Windows application, check the
Empty project box, and submit.
Youll now need to configure the compiler and linker settings. Open up the
project properties, and select All Configurations (this is necessary to ensure
our changes are applied for both debug and release builds). Open up the
general section under C/C++, and configure the include\ folder you created
above as an Additional Include Directory. If you have more than one GLUT
package which contains a glut.h file, its important to ensure that the
freeglut include folder appears above all other GLUT include folders.
Now open up the general section under Linker, and configure the lib\
folder you created above as an Additional Library Directory. A freeglut
application depends on the import libraries freeglut.lib and opengl32.lib,
which can be configured under the Input section. However, it shouldnt be
necessary to explicitly state these dependencies, since the freeglut headers
FreeGLUT/freeglut-Readme.txt view on Meta::CPAN
Dont forget to either include the freeglut DLL when distributing applications,
or provide your users with some method of obtaining it if they dont already
have it!
Compiling 64 bit Applications
Building 64 bit applications is almost identical to building 32 bit applications.
When you use the configuration manager to add the x64 platform, its easiest to
copy the settings from the Win32 platform. If you do so, its then only necessary
to change the Additional Library Directories configuration so that it
references the directory containing the 64 bit import library rather
than the 32 bit one.
Problems?
If you have problems using this package (compiler / linker errors etc.), please
check that you have followed all of the steps in this readme file correctly.
Almost all of the problems which are reported with these packages are due to
missing a step or not doing it correctly, for example trying to build a 32 bit
FreeGLUT/freeglut-Readme.txt view on Meta::CPAN
unless youre sure its a freeglut bug, and have reproduced the issue after
compiling freeglut from the latest SVN versionif thats still the case, Im sure
they would appreciate a bug report or a patch.
Changelog
20130511: Release 2.8.1-1.mp
   First 2.8.1 MSVC release. Ive built the package using Visual Studio 2012,
    and the only change Ive made is to the DLL version resourceIve changed
    the description so that my MinGW and MSVC builds are distinguishable from
    each other (and other builds) using Windows Explorer.
Martin Payne
20130511
http://www.transmissionzero.co.uk/
	Added documentation comments to OpenGL.xs
	Added glpHasGLUT
	Updated test.pl to run texhack if no GLUT
	Added a countdown timer to examples/texhack
	Fixed GL_X_BYTES in assign
	Fixed vertex.glsl to work on newer nvidia cards
	Implemented glutIgnoreKeyRepeat
	Implemented glutSetKeyRepeat
	Implemented glutForceJoystickFunc
	Added FreeGLUT support for cygwin builds
	Fixed builds for Apple's recent Mac OS changes
	Added README for building on Mac OS
	Chris Marshall
	Added support for building POGL within cygwin
	Added Config.pm support
	Sisyphus
	Added partial support for MinGW/dmake - not yet fully functional
	Added "clean" target to Makefile.PL
	Added MacOSX support
	Daiki Nomura
	Helped add FreeBSD support
0.54:	Martien Verbruggen fixed another Mesa limitation.
	#ifdef out unglob'ing: symbol not found on Solaris...
0.53:	Correct vertex_array detection in isosample.pl.
	Add more vertex_array constants (and move the definition earlier).
	Exchange (default) arguments for glp*: move display after window
	  (should not break old stuff, since there was/is no way to query
	   the display and window).
	New function $d = glpDisplay() (croaks on failure).
	Make glpOpenWindow() return the window handle.
	New functions with signatures
 void glpMoveResizeWindow(int x, int y, unsigned int width, unsigned int height, Window w, Display* display);
 void glpMoveWindow(int x, int y, Window w, Display* display);
 void glpResizeWindow(unsigned int width, unsigned int height, Window w, Display* display);
	  (w and display are optional).
Release_Notes view on Meta::CPAN
Highlights:
  * Paul Seamons contributed full tessellation support,
    documentation for OpenGL::Tessellation, and a *major* set
    of fixes and POD for the existing OpenGL::Array module.
  * The cygwin build of POGL now supports either the native
    win32 platform drivers or the X11/GLX bindings (default).
    Use interface=w32api or interface=wgl as args to the
    perl Makefile.PL to select.  NOTE: you have to pick one
    or the other.  If you change, any dependencies such as
    PDL::Graphics::TriD will need to be recompiled.
  * The included FreeGLUT DLL has been upgraded to 2.6.0
    thanks to Rob/sisyphus.
  * Prima::OpenGL has been released by Dmitry Karasik which
    adds support for Perl OpenGL to his cross-platform GUI
    toolkit in addition to bug fixes and code cleanup.
    Thanks, Dmitry!  See http://search.cpan.org/~karasik/Prima-1.30/
    for details.
    
    GLUT, with full support up to API version 3.
    
    GLX is only supported to the degree that Stan's original module
    supported it. Without an entire X binding it is of limited use, and I
    recommend using glut or Gtk::GLArea instead.
    
    
    Most functions that have no pointer arguments are called identically in
    Perl as in C, and the same name is used. Functions that use array
    arguments and have been changed in "the obvious way" -- to take a
    variable number of arguments and/or to return an array -- have the
    the same names as their C counterparts, but with a _p suffix.
    
    All functions that take pointers are available with their original
    calling syntax and a _c suffix. These are most useful when combined with
    the OpenGL::Array module, which lets you allocate C arrays from Perl.
    
    A third variant, _s, exists for most pointer functions, and takes a string
    argument for each pointer. The underlying OpenGL function will be passed
    a pointer to that string.  If these variants are passed a reference to a
include/GL/glu.h view on Meta::CPAN
/*++ BUILD Version: 0004    // Increment this if a change has global effects
Copyright (c) 1985-95, Microsoft Corporation
Module Name:
    glu.h
Abstract:
    Procedure declarations, constant definitions and macros for the OpenGL
#define GLX_TRANSPARENT_TYPE_EXT	PGL_TRANSPARENT_TYPE_EXT
#define GLX_TRANSPARENT_INDEX_VALUE_EXT	PGL_TRANSPARENT_INDEX_VALUE_EXT
#define GLX_TRANSPARENT_RED_VALUE_EXT	PGL_TRANSPARENT_RED_VALUE_EXT
#define GLX_TRANSPARENT_GREEN_VALUE_EXT	PGL_TRANSPARENT_GREEN_VALUE_EXT
#define GLX_TRANSPARENT_BLUE_VALUE_EXT	PGL_TRANSPARENT_BLUE_VALUE_EXT
#define GLX_TRANSPARENT_ALPHA_VALUE_EXT	PGL_TRANSPARENT_ALPHA_VALUE_EXT
typedef HWND Window;
typedef HAB Display;
typedef VISUALCONFIG XVisualInfo;	/* Exchange this with config */
typedef HGC GLXContext;	/* Exchange this with config */
typedef struct XSetWindowAttributes {
    int colormap;
    int border_pixel;
    long event_mask;
} XSetWindowAttributes;			/* Not used! */
typedef long Colormap;			/* Not used! */
typedef HWND Drawable;			/* Not used! */
typedef HWND GLXDrawable;
typedef int KeySym;
typedef bool	Bool;
typedef struct {
	int type;
	unsigned long serial;	/* # of last request processed by server */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;	/* Display the event was read from */
	Window window;		/* unused */
	int request;		/* one of MappingModifier, MappingKeyboard,
				   MappingPointer */
	int first_keycode;	/* first keycode */
	int count;		/* defines range of change w. first_keycode*/
} XMappingEvent;
typedef struct {
	int type;
	Display *display;	/* Display the event was read from */
	XID resourceid;		/* resource id */
	unsigned long serial;	/* serial number of failed request */
	unsigned char error_code;	/* error code of failed request */
	unsigned char request_code;	/* Major op-code of failed request */
	unsigned char minor_code;	/* Minor op-code of failed request */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;/* Display the event was read from */
	Window window;	/* window on which event was requested in event mask */
} XAnyEvent;
/*
 * this union is defined so Xlib can always use the same sized
 * event structure internally, to avoid memory fragmentation.
 */
typedef union _XEvent {
        int type;		/* must not be changed; first element */
	XAnyEvent xany;
	XKeyEvent xkey;
	XButtonEvent xbutton;
	XMotionEvent xmotion;
	XCrossingEvent xcrossing;
	XFocusChangeEvent xfocus;
	XExposeEvent xexpose;
	XGraphicsExposeEvent xgraphicsexpose;
	XNoExposeEvent xnoexpose;
	XVisibilityEvent xvisibility;
=head1 SYNOPSIS
  perl newppp.h [options] [source files]
  Searches current directory for files if no [source files] are given
  --help                      show short help
  --version                   show version
  --patch=file                write one patch file with changes
  --copy=suffix               write changed copies with suffix
  --diff=program              use diff program and options
  --compat-version=version    provide compatibility with Perl version
  --cplusplus                 accept C++ comments
  --quiet                     don't output anything except fatal errors
  --nodiag                    don't show diagnostics
  --nohints                   don't show hints
  --nochanges                 don't suggest changes
  --nofilter                  don't filter input files
  --strip                     strip all script and doc functionality from
                              newppp.h
  --list-provided             list provided API
  --list-unsupported          list unsupported API
  --api-info=name             show Perl API portability information
=head1 COMPATIBILITY
Display a brief usage summary.
=head2 --version
Display the version of F<newppp.h>.
=head2 --patch=I<file>
If this option is given, a single patch file will be created if
any changes are suggested. This requires a working diff program
to be installed on your system.
=head2 --copy=I<suffix>
If this option is given, a copy of each file will be saved with
the given suffix that contains the suggested changes. This does
not require any external programs. Note that this does not
automagially add a dot between the original filename and the
suffix. If you want the dot, you have to include it in the option
argument.
If neither C<--patch> or C<--copy> are given, the default is to
simply print the diffs for each file. This requires either
C<Text::Diff> or a C<diff> program to be installed.
=head2 --diff=I<program>
=head2 --nodiag
Don't output any diagnostic messages. Only portability
alerts will be printed.
=head2 --nohints
Don't output any hints. Hints often contain useful portability
notes. Warnings will still be displayed.
=head2 --nochanges
Don't suggest any changes. Only give diagnostic output and hints
unless these are also deactivated.
=head2 --nofilter
Don't filter the list of input files. By default, files not looking
like source code (i.e. not *.xs, *.c, *.cc, *.cpp or *.h) are skipped.
=head2 --strip
Strip all script and documentation functionality from F<newppp.h>.
    sv_2pvbyte()              NEED_sv_2pvbyte              NEED_sv_2pvbyte_GLOBAL
    sv_catpvf_mg()            NEED_sv_catpvf_mg            NEED_sv_catpvf_mg_GLOBAL
    sv_catpvf_mg_nocontext()  NEED_sv_catpvf_mg_nocontext  NEED_sv_catpvf_mg_nocontext_GLOBAL
    sv_pvn_force_flags()      NEED_sv_pvn_force_flags      NEED_sv_pvn_force_flags_GLOBAL
    sv_setpvf_mg()            NEED_sv_setpvf_mg            NEED_sv_setpvf_mg_GLOBAL
    sv_setpvf_mg_nocontext()  NEED_sv_setpvf_mg_nocontext  NEED_sv_setpvf_mg_nocontext_GLOBAL
    vload_module()            NEED_vload_module            NEED_vload_module_GLOBAL
    vnewSVpvf()               NEED_vnewSVpvf               NEED_vnewSVpvf_GLOBAL
    warner()                  NEED_warner                  NEED_warner_GLOBAL
To avoid namespace conflicts, you can change the namespace of the
explicitly exported functions / variables using the C<DPPP_NAMESPACE>
macro. Just C<#define> the macro before including C<newppp.h>:
    #define DPPP_NAMESPACE MyOwnNamespace_
    #include "newppp.h"
The default namespace is C<DPPP_>.
=back
The good thing is that most of the above can be checked by running
F<newppp.h> on your source code. See the next section for
details.
=head1 EXAMPLES
To verify whether F<newppp.h> is needed for your module, whether you
should make any changes to your code, and whether any special defines
should be used, F<newppp.h> can be run as a Perl script to check your
source code. Simply say:
    perl newppp.h
The result will usually be a list of patches suggesting changes
that should at least be acceptable, if not necessarily the most
efficient solution, or a fix for all possible problems.
If you know that your XS module uses features only available in
newer Perl releases, if you're aware that it uses C++ comments,
and if you want all suggestions as a single patch file, you could
use something like this:
    perl newppp.h --compat-version=5.6.0 --cplusplus --patch=test.diff
If you only want your code to be scanned without any suggestions
for changes, use:
    perl newppp.h --nochanges
You can specify a different C<diff> program or options, using
the C<--diff> option:
    perl newppp.h --diff='diff -C 10'
This would output context diffs with 10 lines of context.
If you want to create patched copies of your files instead, use:
# Disable broken TRIE-optimization
BEGIN { eval '${^RE_TRIE_MAXBUF} = -1' if $] >= 5.009004 && $] <= 5.009005 }
my $VERSION = 3.20;
my %opt = (
  quiet     => 0,
  diag      => 1,
  hints     => 1,
  changes   => 1,
  cplusplus => 0,
  filter    => 1,
  strip     => 0,
  version   => 0,
);
my($ppport) = $0 =~ /([\w.]+)$/;
my $LF = '(?:\r\n|[\r\n])';   # line feed
my $HS = "[ \t]";             # horizontal whitespace
# Never use C comments in this file!
my $ccs  = '/'.'*';
my $cce  = '*'.'/';
my $rccs = quotemeta $ccs;
my $rcce = quotemeta $cce;
eval {
  require Getopt::Long;
  Getopt::Long::GetOptions(\%opt, qw(
    help quiet diag! filter! hints! changes! cplusplus strip version
    patch=s copy=s diff=s compat-version=s
    list-provided list-unsupported api-info=s
  )) or usage();
};
if ($@ and grep /^-/, @ARGV) {
  usage() if "@ARGV" =~ /^--?h(?:elp)?$/;
  die "Getopt::Long not found. Please don't use any options.\n";
}
mod|||
more_bodies|||
more_sv|||
moreswitches|||
mro_clean_isarev|||
mro_gather_and_rename|||
mro_get_from_name||5.010001|
mro_get_linear_isa_dfs|||
mro_get_linear_isa||5.009005|
mro_get_private_data||5.010001|
mro_isa_changed_in|||
mro_meta_dup|||
mro_meta_init|||
mro_method_changed_in||5.009005|
mro_package_moved|||
mro_register||5.010001|
mro_set_mro||5.010001|
mro_set_private_data||5.010001|
mul128|||
mulexp10|||n
munge_qwlist_to_paren_list|||
my_atof2||5.007002|
my_atof||5.006000|
my_attrs|||
  unless (open IN, "<$filename") {
    warn "Unable to read from $filename: $!\n";
    next;
  }
  info("Scanning $filename ...");
  my $c = do { local $/; <IN> };
  close IN;
  my %file = (orig => $c, changes => 0);
  # Temporarily remove C/XS comments and strings from the code
  my @ccom;
  $c =~ s{
    ( ^$HS*\#$HS*include\b[^\r\n]+\b(?:\Q$ppport\E|XSUB\.h)\b[^\r\n]*
    | ^$HS*\#$HS*(?:define|elif|if(?:def)?)\b[^\r\n]* )
  | ( ^$HS*\#[^\r\n]*
    | "[^"\\]*(?:\\.[^"\\]*)*"
    | '[^'\\]*(?:\\.[^'\\]*)*'
  info("=== Analyzing $filename ===");
  my %file = %{$files{$filename}};
  my $func;
  my $c = $file{code};
  my $warnings = 0;
  for $func (sort keys %{$file{uses_Perl}}) {
    if ($API{$func}{varargs}) {
      unless ($API{$func}{nothxarg}) {
        my $changes = ($c =~ s{\b(Perl_$func\s*\(\s*)(?!aTHX_?)(\)|[^\s)]*\))}
                              { $1 . ($2 eq ')' ? 'aTHX' : 'aTHX_ ') . $2 }ge);
        if ($changes) {
          warning("Doesn't pass interpreter argument aTHX to Perl_$func");
          $file{changes} += $changes;
        }
      }
    }
    else {
      warning("Uses Perl_$func instead of $func");
      $file{changes} += ($c =~ s{\bPerl_$func(\s*)\((\s*aTHX_?)?\s*}
                                {$func$1(}g);
    }
  }
  for $func (sort keys %{$file{uses_replace}}) {
    warning("Uses $func instead of $replace{$func}");
    $file{changes} += ($c =~ s/\b$func\b/$replace{$func}/g);
  }
  for $func (sort keys %{$file{uses_provided}}) {
    if ($file{uses}{$func}) {
      if (exists $file{uses_deps}{$func}) {
        diag("Uses $func, which depends on ", join(', ', @{$file{uses_deps}{$func}}));
      }
      else {
        diag("Uses $func");
      }
  for $func (sort keys %{$file{needed_static}}) {
    my $message = '';
    if (not exists $file{uses}{$func}) {
      $message = "No need to define NEED_$func if $func is never used";
    }
    elsif (exists $file{needs}{$func} && $file{needs}{$func} ne 'static') {
      $message = "No need to define NEED_$func when already needed globally";
    }
    if ($message) {
      diag($message);
      $file{changes} += ($c =~ s/^$HS*#$HS*define$HS+NEED_$func\b.*$LF//mg);
    }
  }
  for $func (sort keys %{$file{needed_global}}) {
    my $message = '';
    if (not exists $global{uses}{$func}) {
      $message = "No need to define NEED_${func}_GLOBAL if $func is never used";
    }
    elsif (exists $file{needs}{$func}) {
      if ($file{needs}{$func} eq 'extern') {
        $message = "No need to define NEED_${func}_GLOBAL when already needed globally";
      }
      elsif ($file{needs}{$func} eq 'static') {
        $message = "No need to define NEED_${func}_GLOBAL when only used in this file";
      }
    }
    if ($message) {
      diag($message);
      $file{changes} += ($c =~ s/^$HS*#$HS*define$HS+NEED_${func}_GLOBAL\b.*$LF//mg);
    }
  }
  $file{needs_inc_ppport} = keys %{$file{uses}};
  if ($file{needs_inc_ppport}) {
    my $pp = '';
    for $func (sort keys %{$file{needs}}) {
      my $type = $file{needs}{$func};
        }
        else {
          diag("File needs $func, adding static request");
        }
        $pp .= "#define NEED_$func$suffix\n";
      }
    }
    if ($pp && ($c =~ s/^(?=$HS*#$HS*define$HS+NEED_\w+)/$pp/m)) {
      $pp = '';
      $file{changes}++;
    }
    unless ($file{has_inc_ppport}) {
      diag("Needs to include '$ppport'");
      $pp .= qq(#include "$ppport"\n)
    }
    if ($pp) {
      $file{changes} += ($c =~ s/^($HS*#$HS*define$HS+NEED_\w+.*?)^/$1$pp/ms)
                     || ($c =~ s/^(?=$HS*#$HS*include.*\Q$ppport\E)/$pp/m)
                     || ($c =~ s/^($HS*#$HS*include.*XSUB.*\s*?)^/$1$pp/m)
                     || ($c =~ s/^/$pp/);
    }
  }
  else {
    if ($file{has_inc_ppport}) {
      diag("No need to include '$ppport'");
      $file{changes} += ($c =~ s/^$HS*?#$HS*include.*\Q$ppport\E.*?$LF//m);
    }
  }
  # put back in our C comments
  my $ix;
  my $cppc = 0;
  my @ccom = @{$file{ccom}};
  for $ix (0 .. $#ccom) {
    if (!$opt{cplusplus} && $ccom[$ix] =~ s!^//!!) {
      $cppc++;
      $file{changes} += $c =~ s/$rccs$ix$rcce/$ccs$ccom[$ix] $cce/;
    }
    else {
      $c =~ s/$rccs$ix$rcce/$ccom[$ix]/;
    }
  }
  if ($cppc) {
    my $s = $cppc != 1 ? 's' : '';
    warning("Uses $cppc C++ style comment$s, which is not portable");
  }
  my $s = $warnings != 1 ? 's' : '';
  my $warn = $warnings ? " ($warnings warning$s)" : '';
  info("Analysis completed$warn");
  if ($file{changes}) {
    if (exists $opt{copy}) {
      my $newfile = "$filename$opt{copy}";
      if (-e $newfile) {
        error("'$newfile' already exists, refusing to write copy of '$filename'");
      }
      else {
        local *F;
        if (open F, ">$newfile") {
          info("Writing copy of '$filename' with changes to '$newfile'");
          print F $c;
          close F;
        }
        else {
          error("Cannot open '$newfile' for writing: $!");
        }
      }
    }
    elsif (exists $opt{patch} || $opt{changes}) {
      if (exists $opt{patch}) {
        unless ($patch_opened) {
          if (open PATCH, ">$opt{patch}") {
            $patch_opened = 1;
          }
          else {
            error("Cannot open '$opt{patch}' for writing: $!");
            delete $opt{patch};
            $opt{changes} = 1;
            goto fallback;
          }
        }
        mydiff(\*PATCH, $filename, $c);
      }
      else {
fallback:
        info("Suggested changes:");
        mydiff(\*STDOUT, $filename, $c);
      }
    }
    else {
      my $s = $file{changes} == 1 ? '' : 's';
      info("$file{changes} potentially required change$s detected");
    }
  }
  else {
    info("Looks good");
  }
}
close PATCH if $patch_opened;
exit 0;
yy_parser DPPP_(dummy_PL_parser);
#else
extern yy_parser DPPP_(dummy_PL_parser);
#endif
# endif
/* PL_expect, PL_copline, PL_rsfp, PL_rsfp_filters, PL_linestr, PL_bufptr, PL_bufend, PL_lex_state, PL_lex_stuff, PL_tokenbuf depends on PL_parser */
/* Warning: PL_expect, PL_copline, PL_rsfp, PL_rsfp_filters, PL_linestr, PL_bufptr, PL_bufend, PL_lex_state, PL_lex_stuff, PL_tokenbuf
 * Do not use this variable unless you know exactly what you're
 * doint. It is internal to the perl parser and may change or even
 * be removed in the future. As of perl 5.9.5, you have to check
 * for (PL_parser != NULL) for this variable to have any effect.
 * An always non-NULL PL_parser dummy is provided for earlier
 * perl versions.
 * If PL_parser is NULL when you try to access this variable, a
 * dummy is being accessed instead and a warning is issued unless
 * you define DPPP_PL_parser_NO_DUMMY_WARNING.
 * If DPPP_PL_parser_NO_DUMMY is defined, the code trying to access
 * this variable will croak with a panic message.
 */
  glDisableClientState(GL_TEXTURE_COORD_ARRAY);
  glDisableClientState(GL_COLOR_ARRAY);
  glDisableClientState(GL_NORMAL_ARRAY);
  glDisableClientState(GL_VERTEX_ARRAY);
  # Move back to the origin (for the text, below).
  glLoadIdentity();
  # We need to change the projection matrix for the text rendering.
  glMatrixMode(GL_PROJECTION);
  # But we like our current view too; so we save it here.
  glPushMatrix();
  # Now we set up a new projection for the text.
  glLoadIdentity();
  glOrtho(0,$Window_Width,0,$Window_Height,-1.0,1.0);
  # Lit or textured text looks awful.
utils/glversion.c view on Meta::CPAN
#include "../include/GL/freeglut.h"
#else
#include <GL/freeglut.h>
#endif
#else
#ifdef __APPLE__
/* NB: not ideal -- this assumes that we always build with AGL interface on Mac OS X
 * Ideally, the flag HAVE_AGL_GLUT should be set appropriately by Makefile.PL when building glversion
 * and used to check here, but this will require substantial changes to the get_extensions() there
 */
#include <GLUT/glut.h>
#else
#include <GL/glut.h>
#endif
#endif
#define PROGRAM "glversion"
( run in 0.305 second using v1.01-cache-2.11-cpan-5dc5da66d9d )