Descriptions and Examples for the POV-Ray Raytracer by Friedrich A. Lohmüller
    Include files with POV-Ray
How they work and How to make your own include files
Deutsch Deutsch

- POV-Ray Tutorial

  - POV-Ray Details

  - About Variables

  - A Short
    Include File Tutorial
      Why Include Files?
      Self-made Include Files
          and how to call them.
    >Special Notations, ".inc"
          "#local / #declare"
      Where to store
      Design of Include Files
      Adding a new item
        to the 'Insert Menu'


Special Notations for Include Files.

Include file extension:
  The standard extension for include files is: '.inc'
This is just a convention for making clear that this is not a independent text file!
(Basically the file is nothing else than a plain ASCII text, just like the scene file with the extension '.pov'.)
Some POV-Ray users prefer additionally to use the extension '.mcr' for include files containing macros.

Include file name:
  Don't use any names of include files delivered with POV-Ray.
Use pithy names, i.e.: '' if it contains a declaration for 'Table_01'
To avoid any collision with built-in identifiers or reserved words of POV-Ray,
it's strongly recommanded to use only words beginning with capital letters
for all identifiers of variables declared by the user.

Prefer '#local' rather than '#declare':
  Use '#local' instead of '#declare' for all declarations inside of an include file, that have no meaning outside the include file (excepted the object you want to declare by this include file!).
This prevents variables of the same name used outside (in a scene file or an other include file) to be changed by calling this include file.


© Friedrich A. Lohmüller, 2011