Changeset 881 for trunk


Ignore:
Timestamp:
Feb 13, 2008, 6:53:34 AM (17 years ago)
Author:
dkearney
Message:

moving nanovis' camera object to nvcamera in preparation for a new dx file reader, the dx libraries also include an object called camera.

Location:
trunk/vizservers/nanovis
Files:
4 edited
2 moved

Legend:

Unmodified
Added
Removed
  • trunk/vizservers/nanovis/Command.cpp

    r877 r881  
    6363#include "HeightMap.h"
    6464#include "Grid.h"
    65 #include "Camera.h"
     65#include "NvCamera.h"
    6666#include <RenderContext.h>
    6767#include <NvLIC.h>
  • trunk/vizservers/nanovis/Makefile.in

    r851 r881  
    3030MATINC = ./newmat11
    3131
     32LIB_DX = -lDXcallm -lm
    3233LIB_NANOVIS = -L@RP_DIR@/lib -ltcl8.4 -lGL -lglut -lglui -lGLEW -lCg -lCgGL -pthread -lrappture2 -lb64 -lz
    3334INCLUDES = -I@RP_DIR@/include -I@RP2_INCL_DIR@ -I/usr/include/GL -I$(R2INC) -I. -I$(MATINC)
     
    4142        BMPImageLoaderImpl.o \
    4243        BucketSort.o \
    43         Camera.o \
     44        NvCamera.o \
    4445        Color.o \
    4546        ColorGradient.o \
     
    153154
    154155nanovis: $(OBJS)
    155         $(CC) $(CC_SWITCHES) -o $@ $^ $(LIB_NANOVIS)
     156        $(CC) $(CC_SWITCHES) -o $@ $^ $(LIB_NANOVIS) $(LIB_DX)
    156157
    157158client: Socket.o ClientSocket.o RenderClient.o Event.o
    158         $(CC) $(CC_SWITCHES) -o $(LIB_NANOVIS) $@ $^
     159        $(CC) $(CC_SWITCHES) -o $@ $^ $(LIB_NANOVIS) $(LIB_DX)
    159160
    160161.cpp.o:
     
    222223Texture3D.o: Texture3D.cpp Texture3D.h $(AUXSRC)
    223224Renderable.o: Renderable.cpp Renderable.h
    224 Camera.o: Camera.cpp Camera.h
     225NvCamera.o: NvCamera.cpp NvCamera.h
    225226ScreenSnapper.o: ScreenSnapper.cpp ScreenSnapper.h define.h
    226227Volume.o: Volume.cpp Volume.h $(AUXSRC)
  • trunk/vizservers/nanovis/NvCamera.cpp

    r876 r881  
    11/*
    22 * ----------------------------------------------------------------------
    3  * Camera.cpp : Camera class
     3 * NvCamera.cpp : NvCamera class
    44 *
    55 * ======================================================================
     
    1515
    1616#include <stdio.h>
    17 #include "Camera.h"
     17#include "NvCamera.h"
    1818
    19 Camera::Camera(int startx, int starty, int w, int h,
     19NvCamera::NvCamera(int startx, int starty, int w, int h,
    2020                double loc_x, double loc_y, double loc_z,
    2121                double target_x, double target_y, double target_z,
     
    2929         angle(Vector3(angle_x, angle_y, angle_z)) { }
    3030
    31 Camera::~Camera(){}     
     31NvCamera::~NvCamera(){} 
    3232
    33 void Camera::move(double loc_x, double loc_y, double loc_z)
     33void NvCamera::move(double loc_x, double loc_y, double loc_z)
    3434{
    3535  location = Vector3(loc_x, loc_y, loc_z);
    3636}
    3737
    38 void Camera::aim(double target_x, double target_y, double target_z)
     38void NvCamera::aim(double target_x, double target_y, double target_z)
    3939{
    4040  target = Vector3(target_x, target_y, target_z);
    4141}
    4242
    43 void Camera::rotate(double angle_x, double angle_y, double angle_z)
     43void NvCamera::rotate(double angle_x, double angle_y, double angle_z)
    4444{
    4545  angle = Vector3(angle_x, angle_y, angle_z);
    4646}
    4747
    48 void Camera::activate(){
     48void NvCamera::activate(){
    4949  //fprintf(stderr, "camera: %d, %d\n", width, height);
    5050  glViewport(startX, startY, width, height);
     
    6565}
    6666
    67 void Camera::set_screen_size(int sx, int sy, int w, int h){
     67void NvCamera::set_screen_size(int sx, int sy, int w, int h){
    6868  width = w; height = h;
    6969  startX = sx; startY = sy;
  • trunk/vizservers/nanovis/NvCamera.h

    r876 r881  
    11/*
    22 * ----------------------------------------------------------------------
    3  * Camera.h : Camera class
     3 * NvCamera.h : NvCamera class
    44 *
    55 * ======================================================================
     
    2121#include "Vector3.h"
    2222
    23 class Camera{
     23class NvCamera{
    2424
    2525public:
     
    3333    int startY;
    3434
    35         ~Camera();
    36         Camera(int startx, int starty, int w, int h,
     35        ~NvCamera();
     36        NvCamera(int startx, int starty, int w, int h,
    3737                double loc_x, double loc_y, double loc_z,
    3838                double target_x, double target_y, double target_z,
  • trunk/vizservers/nanovis/nanovis.cpp

    r862 r881  
    7676// STATIC MEMBER DATA
    7777int NanoVis::updir = Y_POS;
    78 Camera* NanoVis::cam = NULL;
     78NvCamera* NanoVis::cam = NULL;
    7979bool NanoVis::axis_on = true;
    8080//bool NanoVis::axis_on = false;
     
    658658
    659659   //create the camera with default setting
    660    cam = new Camera(0, 0, win_width, win_height,
     660   cam = new NvCamera(0, 0, win_width, win_height,
    661661                   live_obj_x, live_obj_y, live_obj_z,
    662662                   0., 0., 100.,
  • trunk/vizservers/nanovis/nanovis.h

    r861 r881  
    4343#include "global.h"
    4444#include "socket/Socket.h"
    45 #include "Camera.h"
     45#include "NvCamera.h"
    4646#include "ConvexPolygon.h"
    4747#include "Texture3D.h"
     
    122122    static int n_volumes;
    123123    static int updir;
    124     static Camera *cam;
     124    static NvCamera *cam;
    125125
    126126    static float lic_slice_x;
Note: See TracChangeset for help on using the changeset viewer.