#!/bin/sh PROGRAM=../bin/release/Preprocessor.exe #PROGRAM=../bin/Debug/Preprocessor.exe if [ $# -ne 3 ] then echo "Usage:" echo "preprocess_visibility scene_file.x3d viewcells_file.xml number_of_viewcells" exit fi SCENE=$1 VIEWCELLS=$2 NUM_VIEWCELLS=$3 NUM_SAMPLE_RAYS=500000 LOG_PREFIX=generate_viewcells ENVIRONMENT=generate_viewcells.env ############################################### METHOD=avs echo "$SCENE $METHOD" $PROGRAM $ENVIRONMENT \ -scene_filename=$SCENE \ -view_cells_type=vspBspTree \ -view_cells_construction_samples=0 \ -vsp_bsp_construction_samples=$NUM_SAMPLE_RAYS \ -vsp_bsp_term_max_view_cells=$NUM_VIEWCELLS \ -view_cells_evaluation_stats_prefix=$LOG_PREFIX-$METHOD \ -view_cells_merge_stats=$LOG_PREFIX-$METHOD-mergeStats.log \ -vsp_bsp_subdivision_stats=$LOG_PREFIX-$METHOD-subdivisionStats.log \ -view_cells_post_process_merge=false \ -view_cells_active=$NUM_VIEWCELLS \ -view_cells_filename=$VIEWCELLS \ -view_cells_export_pvs=true \ -view_cells_export_bounding_boxes=true \ -vsp_bsp_term_min_pvs=0 \ -view_cells_evaluate=false \ -vsp_bsp_use_cost_heuristics=true \ -vsp_bsp_max_poly_candidates=0 \ -vsp_bsp_use_split_cost_queue=true \ -view_cells_show_visualization=true \ -view_cells_construction_samples=0 \ -view_cells_evaluation_samples=2000000 \ -view_cells_evaluation_samples_per_pass=1000000 mv debug.log $LOG_PREFIX-$METHOD-debug.log mv merged_view_cells.wrl $LOG_PREFIX-$METHOD-merged_view_cells.wrl mv merged_view_cells_pvs.wrl $LOG_PREFIX-$METHOD-merged_view_cells_pvs.wrl #mv final_view_cells.x3d $LOG_PREFIX-$METHOD-final_view_cells.x3d