#!/usr/bin/env ruby # # 表題: ape お絵描きサムネイル HTML 作成スクリプト # # 履歴: 2003/09/28 やまだ由 # # 注意: 本プログラムは, # dcphoto.pl Ver 1.02 - 写真用 HTML作成スクリプト # Mitsuda Chihiro # を ruby で写経し, やまだ由用にカスタマイズしたものである # # # # END{ rezol_exp = [ "T39L48_eml", "T39L24_eml", "T39L96_eml","T79L48_eml", "T159L48_eml", "T39L48_non", "T39L24_non", "T39L96_non","T79L48_non", "T159L48_non", "T39L48_ias", "T39L48_kuo", "T39L48_ksc", "T39L48_mca", "T39L48_non" ] rezol_exp.each{ |rezol| rezol_jikkou(rezol) } sonota_jikkou } ######################################################## ## ユーザ設定 ######################################################## def jikkou # インデックスファイル $PWD/../html/${index}.html, $PWD/../html/table_${index}.rd # $index = "T39L48_eml_radiation_3hour_control_sh" # $index = "#{$head}#{$figdir}" # 情報ファイル, $PWD/${infofile} # $infofile = $index + ".txt" # $infofile = "T39L48_eml_#{$figdir}.txt" # 拡張子 $base = ".gif" # 接頭子 # $head = "T39L48_eml_control_" # 絵のあるディレクトリ名, $PWD/../${figdir} # $figdir = "sh" # 横にならべるファイル数 # $figtable_num = 3 #画像ファイルサイズ # $width = "160" ; $height = "120" # $width = "200" ; $height = "150" # $width = "280" ; $height = "210" # テーブル, フォントの色 $color_table = "#ADD8E6" $color_font = "#000080" $color_link = "#269900" $color_visited = "#269900" $color_hover = "#99FF33" # html ヘッダタイトル #$title = "time-mean calculated for APE SH standard output [control]" # サムネイルタイトル $header1 = $title $header2 = "#{$header2pre} [Filter Settings] T39L48_eml: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T39L24_eml: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T39L96_eml: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T79L48_eml: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T159L48_eml: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T319L48_eml: T39L48_non: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T39L24_non: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T39L96_non: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T79L48_non: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T159L48_non: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T319L48_non: T39L48_ias: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T39L48_ksc: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T39L48_kuo: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] T39L48_mca: [xt] [xtop] [spct] [anim] [comp-xz] [comp-xy] [realcomp-xz] [realcomp-xy] control: [anim2hourly] [composite] [spctfilt] [Resolution (Emanuel)] [Resolution (nocumulus)] [Cumulus scheme] [SST distribution] [HOME] " # サムネイルフッタ ; $footer = "Last update: #{Time.now} Copyright ©\; AGU for APE 2006 (YAMADA Yukiko)" # ファイル生成実行 print $title, "\n" ; apethum end ######################################################## ## include ファイル ######################################################## require 'date' require '/home/yukiko/lib/ape-thum.rb' $KCODE = "e" ######################################################## ## ローカル生成ルーチン ######################################################## def rezol_jikkou(rezol) $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_xt" $infofile = "spctfilt_xt.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "filtered x-t diagram" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_xtop" $infofile = "spctfilt_xtop.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "filtered x-t diagram overploted realdata" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_spct" $infofile = "spctfilt_spct.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "filtered x-t spctrum" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_anim" $infofile = "spctfilt_anim.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "filtered animation" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou anim_sed($index) $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_comp-xy" $infofile = "spctfilt_comp-xy.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "filtered composite x-y diagram" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_comp-xz" $infofile = "spctfilt_comp-xz.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "filtered composite x-z diagram" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_realcomp-xy" $infofile = "spctfilt_realcomp-xy.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "composite x-y diagram used the filtered reference point" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou $head = "#{rezol}_control_" $figdir = "spctfilt" $index = "#{rezol}_control_#{$figdir}_realcomp-xz" $infofile = "spctfilt_realcomp-xz.txt" $title = "#{rezol}_control spectral filtering" $header2pre = "composite x-z diagram used the filtered reference point" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou end def sonota_jikkou $head = "" $figdir = "spctfilt" $index = "spctfilt_setting" $infofile = "spctfilt_setting.txt" $title = "spectral filtering" $header2pre = "setting" $width = "200" ; $height = "150" ; $figtable_num = 4 jikkou end def anim_sed(index) `sed s/-t0.gif\\"\\>/-anim.gif\\"\\>/ ../#{index}.html > tmp.html` `mv tmp.html ../#{index}.html` end