Capture and save animations, window by window, in hyperview using .tcl script
Hello everyone
> Motive is to capture animations window by window using .tcl script.
As an example, Lets say there are 6 windows in one page. I have created a script that is able to capture still images window by window and save them. In the same manner I want to capture animations. I am unable to find any command that can capture an animation by selecting a current window.
> Supplying a script below. This script capture all the windows in one go and make a single .gif consisting of 6 windows.
hwi OpenStack hwi GetSessionHandle session session GetProjectHandle project project GetPageHandle page [project GetActivePage ] set i 0 set j 1 while { $i < [expr [page GetNumberOfWindows ]] } { page SetActiveWindow $j page GetWindowHandle window$j [page GetActiveWindow ] if { [expr [window$j IsEmpty ] ] } { puts 'hey hey hey!! window$j is Empty' window$j ReleaseHandle } else { window$j GetClientHandle client client GetModelHandle model 1 model GetResultCtrlHandle result result GetContourCtrlHandle contour set tag [contour GetDataType] set session_name [session GetSessionFileName] # This is the line of capturing an animation. session CaptureAnimation gif $session_name.$tag-$j.gif result ReleaseHandle contour ReleaseHandle model ReleaseHandle client ReleaseHandle window$j ReleaseHandle } #puts ' i is $i ' #puts ' j is $j ' incr i incr j if { $i > [expr [page GetNumberOfWindows ]-1] } { set i 0 set j 1 break } } page ReleaseHandle project ReleaseHandle session ReleaseHandle hwi ReleaseAllHandles hwi CloseStack
> There is final option of capturing animations by area, but i don't want to use it. It is because the area of windows in page is going to change with requirements.
Thanks for going through such a long post /emoticons/default_smile.png' srcset='/emoticons/smile@2x.png 2x' title=':)' width='20' />
Would be helpful if i get an answer...
Thanks again
Answers
-
Hi Zeta,
Try the method mentioned in the below thread:
https://community.altair.com/community?id=community_question&sys_id=daa64c7a1b2bd0908017dc61ec4bcbfa
0 -
hi @Livil Lyle, the method discussed in the link shared by you is helpful. But I have got more than one window in a single page. I have discussed my problem in detail in the link shared below:
Can you help me out here....
Thanks in advance
0