/*****************************************************************************1*2* Elmer, A Finite Element Software for Multiphysical Problems3*4* Copyright 1st April 1995 - , CSC - IT Center for Science Ltd., Finland5*6* This program is free software; you can redistribute it and/or7* modify it under the terms of the GNU General Public License8* as published by the Free Software Foundation; either version 29* of the License, or (at your option) any later version.10*11* This program is distributed in the hope that it will be useful,12* but WITHOUT ANY WARRANTY; without even the implied warranty of13* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the14* GNU General Public License for more details.15*16* You should have received a copy of the GNU General Public License17* along with this program (in file fem/GPL-2); if not, write to the18* Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,19* Boston, MA 02110-1301, USA.20*21*****************************************************************************/2223/*******************************************************************************24*25* Camera main module includes26*27*******************************************************************************28*29* Author: Juha Ruokolainen30*31* Address: CSC - IT Center for Science Ltd.32* Keilaranta 14, P.O. BOX 40533* 02101 Espoo, Finland34* Tel. +358 0 457 272335* Telefax: +358 0 457 230236* EMail: [email protected]37*38* Date: 27 Sep 199539*40* Modified by:41*42* Date of modification:43*44******************************************************************************/454647/*48* $Id: camera.h,v 1.1.1.1 2005/05/31 06:29:21 vierinen Exp $49*50* $Log: camera.h,v $51* Revision 1.1.1.1 2005/05/31 06:29:21 vierinen52* ads53*54* Revision 1.2 1998/08/01 12:34:10 jpr55*56* Added Id, started Log.57*58*59*/6061#ifdef MODULE_CAMERAS62# define CAM_EXT63#else64# define CAM_EXT extern65#endif6667CAM_EXT int GlobalPass,GlobalMakeSecondPass;6869#define CAM_MAX_OBJECTS_MASKED 1007071typedef enum72{73camera_proj_ortho, camera_proj_perspective74} camera_proj_t;7576typedef struct camera_s77{78struct camera_s *Next;79char *Name;8081float ViewportLowX, ViewportHighX,82ViewportLowY,ViewportHighY;8384float LookAtX,LookAtY,LookAtZ;85float UpX,UpY,UpZ;86float LookFromX,LookFromY,LookFromZ;87float ClipNear,ClipFar;8889float FieldAngle;90camera_proj_t ProjectionType;9192object_t *ObjMask[CAM_MAX_OBJECTS_MASKED];9394logical_t OnOff,DrawFrame;95} camera_t;9697CAM_EXT camera_t *Camera;9899100void cam_set_viewport(camera_t *camera,double lx,double ly,double hx,double hy);101void cam_set_projection( camera_t *camera,camera_proj_t projection );102void cam_set_field_angle( camera_t *camera, double angle );103void cam_set_look_from(camera_t *camera,double x,double y,double z,int relative);104void cam_set_up_vector(camera_t *camera,double x,double y,double z );105void cam_set_clip(camera_t *camera,double n,double f);106void cam_set_look_to(camera_t *camera,double x,double y,double z,int relative);107void cam_set_onoff( camera_t *camera,int onoff);108camera_t *cam_add_camera( camera_t *camera,char *name );109void cam_delete_list( camera_t *camera );110int cam_display_list( camera_t *camera, object_t *object );111112113