|
 |
hi,
"Bald Eagle" <cre### [at] netscape net> wrote:
> "jr" <cre### [at] gmail com> wrote:
> > too complex, really, for the need.
>
> Probably, but good learning exercise for more complex scenes.
> We really don't have any demonstrations / tutorials for this.
> Working example code beats everything.
if you, anyone reading, have a tutorial "in them", the wiki would be a good
place for it. (would be happy to collaborate)
> > #if (first_ < last_ & first_ <= frame_number)
> won't this always be true?
true, the "bit" after the '&' is .. without use. (maybe I need to have stronger
coffee in the mornings :-))
> If I understand this correctly, ...
you and me both.. :-) it'd all be "easier" with the actual scene code, let's
wait for m@b's reply.
regards, jr.
Post a reply to this message
|
 |
|
 |
"jr" <cre### [at] gmail com> wrote:
> "m@b" <nomail@nomail> wrote:
> > "jr" <cre### [at] gmail com> wrote:
> > > ...
> > > another option, not yet mentioned, is having a (shell) script run from the
> > > 'pre_frame_command' which writes the values to a simple CSV type file that you
> > > can read from within the scene.
> >
> > Hmm, yes, I could shell out to a Python script that parses the resolution.ini
> > file.
>
> too complex, really, for the need. apologies. it can (should) all be done "in
> scene", the following quick test works, assuming ten frames and you only want 4
> through 6:
>
> - create a simple "CSV" file with (subset) end and start frame numbers:
>
> $ echo '6,4' > framenos.csv
>
>
> - my ini file ("mb.ini"):
>
> initial_frame = 1
> final_frame = 10
> cyclic_animation = off
> subset_start_frame = 4
> subset_end_frame = 6
>
> input_file_name = mb.pov
> output_file_name = mb_
>
>
> - and your scene, ie only the code inside the conditional:
>
> #version 3.7;
>
> global_settings {assumed_gamma 1}
>
> #declare datafn_ = "framenos.csv";
>
> #fopen tmp_fp_ datafn_ read
> #read (tmp_fp_,last_,first_)
> #fclose tmp_fp_
>
> #if (first_ < last_ & first_ <= frame_number)
>
> /* scene stuff */
> box {0,1}
>
>
> #declare first_ = first_ + 1; /* 'incr()' ?! ;-) */
> #fopen tmp_fp_ datafn_ write
> #write (tmp_fp_,last_,",",first_)
> #fclose tmp_fp_
>
> #end
>
>
> hth, let me know if I got "the wrong end of the stick" :-).
>
>
> regards, jr.
Yes - that would work but, as others have sated, the whole thing is getting more
complicated than it merits.
For now I am happy just to pass the numbers from resolution.ini thus:
Subset_End_Frame=3755
Declare=SEF=3755
Typing the number twice must be quicker than editing a second file each time.
m@b
Post a reply to this message
|
 |
|
 |
hi,
"m@b" <nomail@nomail> wrote:
> "jr" <cre### [at] gmail com> wrote:
> ...
> > > > another option, ...
>
> Yes - that would work but, as others have sated, the whole thing is getting more
> complicated than it merits.
>
> For now I am happy just to pass the numbers from resolution.ini thus:
>
> Subset_End_Frame=3755
> Declare=SEF=3755
>
> Typing the number twice must be quicker than editing a second file each time.
:-) glad/good you found a way.
regards, jr.
Post a reply to this message
|
 |