#!/usr/bin/env python
# -*- coding: utf-8 -*-

import os, sys, signal
import time
import glob

sys.path.append('regzamod')
from Common.RzCmnSubs import dbg,dbg2,dbg0,error,setdbg
from Common.RzCmnSubs import isAudio,isImage,isVideo,isWebVideo,isWebContents,conv_encoding
from Common.RzCmnSubs import gs_encode_sys,gs_debug,gs_verbose,gs_ff_loglev
from Common.RzCmnSubs import gs_python,gs_prog_ytdl,gs_prog_ytdl_s,gs_prog_streamer,gs_streamer_conf
from Common.RzCmnSubs import gs_get_minfo_fp

#----------------------------------------------------------------------------------
# main
#----------------------------------------------------------------------------------
if __name__ == '__main__':
	
	#---- get main args 
	if(len(sys.argv)<2):
		print "usage: pipe_cat.py {file_in}"
		sys.exit(1)
	myprog=sys.argv[0]
	url=sys.argv[1]
	
	dbg0("CommonTest: gs_get_minfo_fp call start audio_in=%s" % (url))
	(rc,fmt,ac,abps,ach)=gs_get_minfo_fp(url)
	dbg0("audiocat: gs_get_minfo_fp call end rc=%d, fmt=%s, ac=%s, abps=%d, ach=%d" % (rc,fmt,ac,abps,ach))
	
