| 7 |  | #       G. Ward | 
| 8 |  | # | 
| 9 |  | use strict; | 
| 10 | + | my $windoz = ($^O eq "MSWin32" or $^O eq "MSWin64"); | 
| 11 |  | # we'll run rpict if no -n or -o* option | 
| 12 |  | my $nprocs = 1; | 
| 13 |  | # rtrace options and the associated number of arguments | 
| 146 |  | } | 
| 147 |  | } | 
| 148 |  | die "Number of processes must be positive" if ($nprocs <= 0); | 
| 149 | + | if ($windoz && $nprocs > 1) { | 
| 150 | + | print STDERR "Only one process supported under Windows\n"; | 
| 151 | + | $nprocs = 1; | 
| 152 | + | } | 
| 153 |  | if ($specout) { | 
| 154 |  | $specout = ($ncsamp > 3); | 
| 155 |  | } | 
| 184 |  | system "@vwraysA -ff -i < /tmp/ord$$.txt " . | 
| 185 |  | "| @rtraceA -ffa -ov '$oct' > /tmp/pix$$.txt"; | 
| 186 |  | die "Error running rtrace\n" if ( $? ); | 
| 187 | < | system "( getinfo < /tmp/pix$$.txt | getinfo -a 'VIEW=$view'; " . | 
| 187 | > | system "( getinfo < /tmp/pix$$.txt | getinfo -r NCOMP " . | 
| 188 | > | "| getinfo -a 'VIEW=$view'; " . | 
| 189 |  | "getinfo - < /tmp/pix$$.txt | rlam /tmp/ord$$.txt - " . | 
| 190 |  | "| sort -k2rn -k1n ) | @pvalueA -Y $res[3] +X $res[1]"; | 
| 191 |  | die "rlam error\n" if ( $? ); | 
| 205 |  | ##### Generating picture with depth buffer? | 
| 206 |  | if (defined $outzbf) { | 
| 207 |  | my $picvt = $specout ? 'rcomb -fc -' : "@pvalueA -df"; | 
| 208 | < | exec "@vwraysA -ff | @rtraceA -fff -olv @res '$oct' | " . | 
| 209 | < | "rsplit -ih -iH -f -of '$outzbf' -oh -oH -of$ncsamp - | " . | 
| 210 | < | $picvt . " | getinfo -a 'VIEW=$view'"; | 
| 208 | > | exec qq{@vwraysA -ff | @rtraceA -fff -olv @res "$oct" | } . | 
| 209 | > | qq{rsplit -ih -iH -f -of "$outzbf" -oh -oH -of$ncsamp - | } . | 
| 210 | > | $picvt . qq{ | getinfo -a "VIEW=$view"}; | 
| 211 |  | } | 
| 212 |  | ##################################################################### | 
| 213 |  | ##### Base case with output picture only? | 
| 214 |  | if (! defined $outdir) { | 
| 215 | < | exec "@vwraysA -ff | @rtraceA -ffc @res '$oct' | getinfo -a 'VIEW=$view'"; | 
| 215 | > | exec qq{@vwraysA -ff | @rtraceA -ffc @res "$oct" | getinfo -a "VIEW=$view"}; | 
| 216 |  | } | 
| 217 |  | ##################################################################### | 
| 218 |  | ##### Layered image output case | 
| 267 |  | delete $rtoutC{$oval}; | 
| 268 |  | } | 
| 269 |  | # call rtrace + rsplit | 
| 270 | < | exec "@vwraysA -ff | @rtraceA -fff @res '$oct' | getinfo -a 'VIEW=$view' | @rsplitA"; | 
| 270 | > | exec qq{@vwraysA -ff | @rtraceA -fff @res "$oct" | getinfo -a "VIEW=$view" | @rsplitA}; |