video release

This commit is contained in:
Tonton Th 2024-12-20 14:24:45 +01:00
parent ff8ccfea55
commit e51921d212
7 changed files with 85 additions and 28 deletions

4
.gitignore vendored
View File

@ -2,8 +2,8 @@
frames/*
datas/*.xcf
WS/timing
WS/*.timing
WS/*timing
WS/log*
*.png
*.gif

View File

@ -1,6 +1,6 @@
POVOPT = +q9 +a0.01 -d
POVOPT = +q9 +a0.02 -d
POVDEP = contexte.inc elements.inc datas/hf.png
@ -10,7 +10,7 @@ PNG: essai.png scene.png
essai.png: essai.pov Makefile $(POVDEP)
povray $(POVOPT) -W640 -H480 -i$< -o$@
CK=30
CK=130
scene.png: scene.pov Makefile $(POVDEP)
povray $(POVOPT) -W1280 -H1024 +K${CK} -i$< -o$@

View File

@ -34,8 +34,8 @@ union {
cylinder {-z, z, 0.10 }
}
light_source { 0, rgb <0.99, 0.05, 0.05>
fade_distance 1.29
fade_power 1.5
fade_distance 0.99
fade_power 1.58
}
}
texture { New_Penny }
@ -84,10 +84,10 @@ texture { Soft_Silver scale 6.0 }
{
difference {
merge {
sphere { 0, 0.008 scale <1, 1, 4.70>
sphere { 0, 0.009 scale <1, 1, 4.70>
translate <0, 0.26, -0.17> }
cone { <0, -0.1, 0>, 0.09, <0, 0.26, -0.17>, 0.009
scale <0.10, 1, 1> }
cone { <0, -0.1, 0>, 0.09, <0, 0.26, -0.17>, 0.0096
scale <0.14, 1, 1> }
}
box { <-1, -1, -1>, <1, 0, 1> }
}
@ -119,14 +119,55 @@ merge {
texture { Orange_Glass }
}
/*
*
*/
#local Rtuy = 0.06;
#local Ltuy = 0.09;
#local Etuy = 0.01; // epaisseur des parois
#declare Tuyere = object
{
#local dX = Ltuy;
merge {
#local R2 = Rtuy - (Etuy/2.0);
intersection {
torus { R2, Etuy/2 scale <1, 18, 1> }
box { <-1, 0, -1>, <1, 1, 1> }
rotate 90*z translate -dX*x
}
torus { R2, Etuy/2 scale <1, 0.75, 1> rotate 90*z translate dX*x }
#if (1)
#difference {
cylinder { <-dX, 0, 0>, <dX, 0, 0>, Rtuy }
cylinder { <-(dX+1), 0, 0>, <dX+2, 0, 0>, Rtuy-Etuy }
}
#end
cylinder { y*Rtuy, y*(Rtuy+0.08), 0.010 scale <2.95, 1, 1> }
}
texture { T_Brass_1C }
}
#declare Les_Tuyeres = object
{
union {
#local E = 0.59;
object { Tuyere translate -E*z }
object { Tuyere translate E*z }
}
rotate -y*90
}
#declare HexaCone = object
{
union {
object { HexaCone_body }
#local T = 0.55;
object { HexaCone_head translate <0, 0, T+DTa> }
object { HexaCone_radar translate <0, T+0.16, 0> }
object { HexaCone_radar translate <0, T+0.18, 0> }
object { HexaCone_derives translate <0, 0, -0.67> }
object { Les_Tuyeres translate -0.18*y }
}
rotate <-7, 0, -9>
rotate <-7, 0, -4>
}

View File

@ -6,19 +6,25 @@
global_settings {
assumed_gamma 1.0
ambient_light 0
max_trace_level 10
}
#include "colors.inc"
#include "metals.inc"
#include "textures.inc"
#include "elements.inc"
#include "contexte.inc"
object { HexaCone_radar translate y*0.6 }
object { HexaCone translate y }
light_source { <-6, 7, -4>, rgb <0.81, 0.65, 0.40> }
light_source { <-6, 7, 4>, rgb <0.31, 0.65, 0.80> }
camera {
location <-3, 1, 1>
look_at <0, 0.6, 0>
angle 10
location <-1.8, 1.1, 0.3>
look_at <0, 1.0, 0>
angle 38
}

View File

@ -4,37 +4,43 @@ source fonctions.sh
set -e ; set -u
TYPE="gif89a"
TYPE="mp4"
NBFRAMES=180
case $TYPE in
"gif89a") DIMS="-W640 -H480" ;;
"mp4") DIMS="-W1280 -H1024" ;;
"mp4") DIMS="-W1024 -H768" ;;
esac
POVOPT="+q9 +a0.02 -d ${DIMS} -WT6"
POVOPT="+q9 +a0.02 -d ${DIMS} -WT8"
echo $POVOPT ; echo ; sleep 2
TMPIMG=/dev/shm/tmpimg.png
for frame in $(seq 0 $((NBFRAMES-1)))
for frame in $(seq 0 $((NBFRAMES-1)))
do
img=$(printf "frames/%05d.png" $frame)
debut=$(date +%s)
set +e
povray ${POVOPT} +K${frame} -iscene.pov -o${TMPIMG}
err=$?
if [ $err != 0 ] ; then
echo "fail $frame" >> WS/log
continue
fi
set -e
txt=$(printf "#%03d" $frame)
echo $frame $img $txt
convert ${TMPIMG} \
-pointsize 16 \
-pointsize 20 \
-fill orange \
-gravity south \
-annotate +0+0 "$txt" \
${img}
fin=$(date +%s)
echo
echo $frame $(( fin - debut )) | tee -a WS/timing
echo ; echo
echo $frame $(( fin - debut )) | tee -a WS/${TYPE}.timing
echo
done
echo
@ -42,6 +48,7 @@ echo
case $TYPE in
"gif89a") convert -delay 8 -dither none \
-colors 109 frames/* foo.gif ;;
"mp4") ff_encodage ;;
esac
ls -lh foo.gif

View File

@ -5,7 +5,7 @@ set -ue
TMPFILE="/dev/shm/plot-timing.tmp"
IMAGE="timing.png"
tail -3600 WS/timing.mp4 | awk ' \
tail -3600 WS/mp4.timing | awk ' \
BEGIN { \
for (foo=0; foo<180; foo++) { \
mini[foo] = 666; \
@ -34,7 +34,7 @@ gnuplot << __EOC__
set term png size 800,480
set output "timing.png"
set grid
set yrange [:200]
set yrange [:300]
set title "HexaCone : temps de tracé vs. numéro de séquence"
set xlabel "numéro de la trame"
set ylabel "temps en secondes"

View File

@ -11,14 +11,17 @@ global_settings {
}
#include "colors.inc"
#include "metals.inc"
#include "textures.inc"
#include "elements.inc"
#declare NormClock = clock / 180.0;
#include "contexte.inc"
#include "elements.inc"
object { HexaCone rotate y*17 translate y*1.11 }
#declare CK = 56 + (clock * 2);
#declare Dcam = 1.97;
#declare Dcam = 2.04;
#declare CamX = Dcam * sin(radians(CK));
#declare CamZ = Dcam * 1.20 * cos(radians(CK));
#declare CamZ = CamZ - 0.11;
@ -28,7 +31,7 @@ camera {
location <CamX, 1.23, CamZ>
look_at Lat
focal_point Lat
aperture 0.056
aperture 0.052
blur_samples 33
angle 70
}