Changeset 902


Ignore:
Timestamp:
Feb 23, 2008 3:56:31 PM (15 years ago)
Author:
kostmo
Message:

extended bmp_write_to_file()

Location:
trunk/vizservers/nanovis
Files:
3 edited

Legend:

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

    r900 r902  
    12411241                    glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);
    12421242           
    1243                     NanoVis::bmp_write_to_file(frame_num);
     1243//                  NanoVis::bmp_write_to_file(frame_num, directory_name);
     1244                    NanoVis::bmp_write_to_file(frame_num, NULL);
    12441245                }
    12451246            }
     
    14161417            glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);
    14171418           
    1418             NanoVis::bmp_write_to_file(frame_count);
    1419             //          printf("Writing to file...\n");
     1419            NanoVis::bmp_write_to_file(frame_count, NULL);
     1420//            NanoVis::bmp_write_to_file(frame_count, directory_name);
    14201421        }
    14211422        // put your code...
  • trunk/vizservers/nanovis/nanovis.cpp

    r900 r902  
    791791// FOR DEBUGGING
    792792void
    793 NanoVis::bmp_write_to_file(int frame_number)
     793NanoVis::bmp_write_to_file(int frame_number, char* directory_name)
    794794{
    795795    unsigned char header[54];
     
    857857    char filename[100];
    858858    if (frame_number >= 0) {
    859         sprintf(filename, "/tmp/flow_animation1/image%03d.bmp", frame_number);
     859        if (directory_name)
     860                sprintf(filename, "%s/image%03d.bmp", directory_name, frame_number);
     861        else
     862                sprintf(filename, "/tmp/flow_animation/image%03d.bmp", frame_number);
     863
    860864        printf("Writing %s\n", filename);
    861865        f = fopen(filename, "wb");
  • trunk/vizservers/nanovis/nanovis.h

    r884 r902  
    150150    static void offscreen_buffer_capture(void);
    151151    static void bmp_write(const char* cmd);
    152     static void bmp_write_to_file(int frame_number);
     152    static void bmp_write_to_file(int frame_number, char* directory_name);
    153153    static void display(void);
    154154    static void update(void);
Note: See TracChangeset for help on using the changeset viewer.