Go to the source code of this file.
Functions | |
out1x1gif () | |
Variables | |
$init_pars | |
$aexp_arr | |
$keep_pars | |
$wb_thrsh = 0.98 | |
$wb_minfrac = 0.01 | |
$wb_rscale = 1.0 | |
$wb_bscale = 1.0 | |
$white_balance = false | |
$wbrslt = -1 | |
$autoexp_set = false | |
$sleep = ($_GET["sleep"]) | |
$usleep = ($_GET["usleep"]) | |
$autoexp = elphel_get_P_value (ELPHEL_AUTOEXP_ON) | |
$pars = array() | |
$mode = $_GET["mode"] | |
$keep_pars = elphel_get_P_arr($keep_pars) | |
$timeout = 500 | |
$hist_in_thresh = 0.0 | |
$hist_out_thresh = 0.0 | |
$autoexp_get = false | |
$streamer_get = false | |
$show_written = false | |
$exif_get = false | |
$circbuf_get = false | |
$debug_arr = array() | |
$toRead = array() | |
case | _stime |
break | |
case | timeout |
case | mode |
case | color |
break | |
case | color |
break | |
case | mono |
break | |
$keep_pars ["COLOR"] = $pars["COLOR"]=((integer) $value) | ($keep_pars["COLOR"] & ~7) | |
break | |
case | test |
break | |
case | sensor |
break | |
$keep_pars ["COLOR"] = $pars["COLOR"]=(((integer) $value) << 8) | ($keep_pars["COLOR"] & ~0x700) | |
break | |
case | flip |
case | x = ==false)?0:1)+((strpos($value,"y")===false)?0:2) |
break | |
case | trig |
break | |
case | async |
break | |
$keep_pars ["TRIG"] = $pars["TRIG"]=($value? 4: 0) | ($keep_pars["TRIG"] & ~0x4) | |
break | |
case | gam |
break | |
case | pxl |
break | |
case | pxh |
break | |
case | iq |
break | |
case | iq |
break | |
case | byr |
$pars ["BAYER"] = (integer) $value | |
break | |
case | fpns |
break | |
case | fpnm |
break | |
case | expos |
case | e |
$autoexp_set = true | |
break | |
case | manual |
$autoexp_set = true | |
break | |
default | __pad0__ |
break | |
case | vw |
break | |
case | vh |
break | |
case | wl |
break | |
case | wt |
break | |
case | ww |
break | |
case | wh |
break | |
case | pfh |
break | |
case | fsd |
break | |
case | dh |
break | |
case | dv |
break | |
case | bh |
break | |
case | bv |
break | |
case | clk |
case | bit |
break | |
case | gr |
break | |
case | gg |
break | |
case | gb |
break | |
case | ggb |
break | |
case | sens |
$pars ["GAINR"] = $value | |
$pars ["GAING"] = $value | |
$pars ["GAINB"] = $value | |
$pars ["GAINGB"] = $value | |
break | |
case | rscale |
break | |
case | bscale |
break | |
case | csb |
break | |
case | saturation_blue |
break | |
case | csr |
break | |
case | saturation_red |
break | |
case | eol |
break | |
case | vtrig |
break | |
case | fclk |
break | |
case | sclk |
break | |
case | xtra |
break | |
case | fps |
$pars ["FP1000SLIM"] = $value | |
else | $pars ["FPSFLAGS"] = 1 |
break | |
case | fpslm |
break | |
case | wb_thrsh |
white balance parameters - if calculated OK, they will overwrite manual rscale, bscale if any | |
$white_balance = true | |
break | |
case | wb_minfrac |
$white_balance = true | |
break | |
case | wb_rscale |
$white_balance = true | |
break | |
case | wb_bscale |
$white_balance = true | |
break | |
case | wbalance |
break | |
case | aexp_get |
break | |
case | aexp_on |
additional autoexposure parameters. Support both integer values (same as internal) and fractions of 1.0, seconds, etc. | |
$autoexp_set = true | |
break | |
case | aexp_width |
$pars ["HISTWND_RWIDTH"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_height |
$pars ["HISTWND_RHEIGHT"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_left |
$pars ["HISTWND_RLEFT"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_top |
$pars ["HISTWND_RTOP"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_exp_max |
$pars ["AUTOEXP_EXP_MAX"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_overexp |
$pars ["AUTOEXP_OVEREXP_MAX"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_below |
$pars ["AUTOEXP_OVEREXP_MAX"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_threshold |
$pars ["AUTOEXP_S_INDEX"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_frac |
$pars ["AUTOEXP_S_PERCENT"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_chng_min |
$pars ["AUTOEXP_SKIP_PMIN"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | aexp_chng_minabs |
$autoexp_set = true | |
break | |
case | aexp_chng_max |
$pars ["AUTOEXP_SKIP_PMAX"] = (integer) $value | |
$autoexp_set = true | |
break | |
case | written |
break | |
case | streamer_get |
break | |
case | exif |
break | |
case | description |
break | |
case | circbuf |
break | |
default | __pad1__ |
$npars = elphel_set_P_arr($pars) | |
$was_running = (elphel_get_state()>7) | |
add mode=safe. "set" if not running, otherwise return error (not needed - mode=safe&STATE is enough) | |
else | break |
$debug_arr ["stopping_force"] = $i | |
$aexp_arr = elphel_get_P_arr ($aexp_arr) | |
$balance_pars = elphel_get_P_arr(array("RSCALE"=>0,"BSCALE"=>0,"GSCALE"=>0)) | |
$streamer_run = false | |
$streamer_conf = file($streamer_run?'/var/state/streamer.conf':'/etc/streamer.conf') | |
$streamer_run = ($retv==0) | |
$circbuf = elphel_get_circbuf_pointers() | |
break | |
$rslt = $xml->asXML() |
out1x1gif | ( | void | ) |
******************************************************************************* ! FILE NAME : ccam.php ! DESCRIPTION: Programs major sensor parameters similar (not exactly) to ccam.cgi, ! returns xml OK ! Copyright (C) 2008 Elphel, Inc ! -----------------------------------------------------------------------------** ! ! This program is free software: you can redistribute it and/or modify ! it under the terms of the GNU General Public License as published by ! the Free Software Foundation, either version 3 of the License, or ! (at your option) any later version. ! ! This program is distributed in the hope that it will be useful, ! but WITHOUT ANY WARRANTY; without even the implied warranty of ! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ! GNU General Public License for more details. ! ! You should have received a copy of the GNU General Public License ! along with this program. If not, see <http://www.gnu.org/licenses/>. ! -----------------------------------------------------------------------------** !
we have zeros in the string
always good
Definition at line 52 of file ccam.php.
References header, s, and stdout.
Referenced by listener_loop().
$aexp_arr |
Initial value:
array( "AUTOEXP_ON"=>0, "HISTWND_RWIDTH"=>0, "HISTWND_RHEIGHT"=>0, "HISTWND_RLEFT"=>0, "HISTWND_RTOP"=>0, "AUTOEXP_EXP_MAX"=>0, "AUTOEXP_OVEREXP_MAX"=>0, "AUTOEXP_S_PERCENT"=>0, "AUTOEXP_S_INDEX"=>0, "AUTOEXP_EXP"=>0, "AUTOEXP_SKIP_PMIN"=>0, "AUTOEXP_SKIP_PMAX"=>0, "AUTOEXP_SKIP_T"=>0, "HISTWND_WIDTH"=>0, "HISTWND_HEIGHT"=>0, "HISTWND_TOP"=>0, "HISTWND_LEFT"=>0 )
$balance_pars = elphel_get_P_arr(array("RSCALE"=>0,"BSCALE"=>0,"GSCALE"=>0)) |
$hist_in_thresh = 0.0 |
$hist_out_thresh = 0.0 |
$init_pars |
Initial value:
array( "FLIP"=>3, "COLOR"=>1, "DCM_HOR" => 1, "DCM_VERT" => 1, "BIN_HOR" => 1, "BIN_VERT" => 1, "QUALITY" => 90, "COLOR_SATURATION_BLUE" => 200 , "COLOR_SATURATION_RED" => 200 , "BITS" => 8, "GAMMA" => 57, "PIXEL_LOW" => 10, "PIXEL_HIGH" => 254, "EXPOS" => 100, "WOI_LEFT" => 0, "WOI_TOP" => 0, "WOI_WIDTH" => 10000, "WOI_HEIGHT" => 10000, "RSCALE" => 256, "BSCALE" => 256, "GAINR" => 512, "GAING" => 512, "GAINB" => 512, "GAINGB" => 512, "BAYER" => 4 )
$keep_pars["TRIG"] = $pars["TRIG"]=($value? 4: 0) | ($keep_pars["TRIG"] & ~0x4) |
$keep_pars["COLOR"] = $pars["COLOR"]=(((integer) $value) << 8) | ($keep_pars["COLOR"] & ~0x700) |
$keep_pars["COLOR"] = $pars["COLOR"]=((integer) $value) | ($keep_pars["COLOR"] & ~7) |
$pars = array() |
Definition at line 128 of file ccam.php.
Referenced by addGammas(), apply_triggers(), applyPost(), print_triggers(), and readCurrentParameterValues().
$streamer_conf = file($streamer_run?'/var/state/streamer.conf':'/etc/streamer.conf') |
$streamer_get = false |
$timeout = 500 |
$was_running = (elphel_get_state()>7) |
$wb_minfrac = 0.01 |
case aexp_below |
case aexp_chng_max |
case aexp_chng_min |
case aexp_chng_minabs |
case aexp_exp_max |
case aexp_height |
case aexp_on |
case aexp_overexp |
case aexp_threshold |
case aexp_width |
case async |
Definition at line 191 of file ccam.php.
Referenced by pgm_limitfps(), pgm_recalcseq(), and pgm_triggermode().
case bh |
Definition at line 296 of file ccam.php.
Referenced by mt9x001_pgm_window_common(), and pgm_window_common().
case bit |
Definition at line 306 of file ccam.php.
Referenced by createDefaultConfig(), and nand_correct_data().
case bscale |
case bv |
Definition at line 299 of file ccam.php.
Referenced by mt9x001_pgm_window_common(), and pgm_window_common().
case color |
Definition at line 174 of file ccam.php.
Referenced by createDefaultConfig(), gammas_write(), pgm_gamma(), pgm_gammaload(), PHP_FUNCTION(), showImgData(), showUsage(), and whiteBalanceCorr().
case csb |
case csr |
case description |
case dh |
Definition at line 290 of file ccam.php.
Referenced by mt9x001_pgm_limitfps(), mt9x001_pgm_window_common(), and pgm_window_common().
case dv |
Definition at line 293 of file ccam.php.
Referenced by mt9x001_pgm_limitfps(), mt9x001_pgm_window_common(), and pgm_window_common().
case e |
Definition at line 236 of file ccam.php.
Referenced by add_alarm_event(), add_always_event(), add_fd_event(), add_timer_event(), calc_pll_params(), cleanup(), event_loop(), exif_getutc(), find_filesystem_entry(), get_event_enabled(), new_event(), recursive_populate_directory(), remove_event(), resched_event(), set_event_enabled(), set_event_interval(), strip_events(), write_dirent(), write_pipe(), write_regular_file(), write_special_file(), and write_symlink().
case flip |
case fps |
Definition at line 370 of file ccam.php.
Referenced by opt_parse(), Streamer::Streamer(), and write_sdp().
case gam |
case mode |
Definition at line 171 of file ccam.php.
Referenced by createDefaultConfig(), fpga_jtag_lseek(), fpga_jtag_open(), fpga_jtag_read(), gammas_open(), gammas_write(), interpret_table_entry(), JTAG_whatopen(), main(), mainJavascript(), parse_def(), printDefaultPage(), and rtsp_udp_setup().
case mono |
case pfh |
case pxl |
case rscale |
case saturation_blue |
case saturation_red |
case sclk |
Definition at line 361 of file ccam.php.
Referenced by mt9x001_pgm_exposure(), and mt9x001_pgm_limitfps().
case sensor |
Definition at line 183 of file ccam.php.
Referenced by createDefaultConfig(), mt9x001_pgm_detectsensor(), mt9x001_pgm_exposure(), mt9x001_pgm_gains(), mt9x001_pgm_initsensor(), mt9x001_pgm_limitfps(), mt9x001_pgm_sensorregs(), mt9x001_pgm_triggermode(), mt9x001_pgm_window(), mt9x001_pgm_window_common(), mt9x001_pgm_window_safe(), pgm_afterinit(), pgm_detectsensor(), pgm_sensorin(), pgm_sensorphase(), pgm_window(), pgm_window_common(), pgm_window_safe(), and showUsage().
case streamer_get |
case test |
Definition at line 182 of file ccam.php.
Referenced by create_elphel353_kdevelop(), createDefaultConfig(), parseGetNames(), and printDefaultPage().
case wb_minfrac |
case wb_thrsh |
case wh |
Definition at line 280 of file ccam.php.
Referenced by mt9x001_pgm_limitfps(), and mt9x001_pgm_window_common().
case wl |
case written |
case wt |
case ww |
Definition at line 276 of file ccam.php.
Referenced by mt9x001_pgm_limitfps(), and mt9x001_pgm_window_common().
Definition at line 187 of file ccam.php.
Referenced by _Request::_Request(), exif_getutc(), gamma_calc(), gamma_calc_reverse(), histogram_calc_percentiles(), i2c_outbyte(), and showJpegHeader().