Advertisement
BDuck

myffinfo

Aug 1st, 2017
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 1.01 KB | None | 0 0
  1. function myFFInfo(clip c, string "bonusText", int "text_color", int "halo_color") {
  2.  
  3. varprefix = FFVAR_PREFIX
  4. bonusText = default(bonusText, "")
  5.  
  6. c.frameevaluate("""
  7.        fftempstring = ""
  8.        varprefix = """" + varprefix + """"
  9.        bonusText = """" + bonusText + """"""")
  10.  
  11. frameevaluate("""fftempstring = fftempstring + "Frame Number: " + string(current_frame) + " of " + string(framecount()) + "\n" """, after_frame=true)
  12. frameevaluate("""fftempstring = fftempstring + "Picture Type: " + chr(eval(varprefix + "FFPICT_TYPE")) + "\n" """, after_frame=true)
  13. frameevaluate("""fftempstring = fftempstring + bonusText """, after_frame=true)
  14.  
  15. #check whether text_color and halo_color are defined in parameter list
  16.     text_color_string= (Defined(text_color)) ? "text_color="+string(text_color)+"," : ""
  17.     halo_color_string= (Defined(halo_color)) ? "halo_color="+string(halo_color)+"," : ""
  18.  
  19. return scriptclip("subtitle(fftempstring,"+text_color_string+halo_color_string+"lsp = 1)", after_frame=true)
  20.  
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement