//--------------------------------------------------------------------------- int Help_Security() { TEXTOUT("Usage: \"MediaInfo [-Options...] FileName1 [Filename2...]\""); TEXTOUT("\"MediaInfo --Help\" for displaying more information"); return -1; }
//-------------------------------------------------------------------------- void CLI::print_error(MediaConchLib::errorHttp code) { switch (code) { case MediaConchLib::errorHttp_INVALID_DATA: TEXTOUT("Data sent to the daemon is not correct"); break; case MediaConchLib::errorHttp_INIT: TEXTOUT("Cannot initialize the HTTP connection"); break; case MediaConchLib::errorHttp_CONNECT: TEXTOUT("Cannot connect to the daemon"); break; case MediaConchLib::errorHttp_INTERNAL: { MediaInfoLib::String error_mil = ZenLib::Ztring().From_UTF8(error); STRINGOUT(error_mil); break; } case MediaConchLib::errorHttp_DAEMON_RESTART: TEXTOUT("Daemon has restarted, try again"); break; default: TEXTOUT("Internal error"); break; } }
void CChannelN::ShowString(double time /*seconds*/, char* buf) { if(int(time) != int(lastTime)/*time - lastTime > 1*/) { PaintBkgr(); lastTime = time; } double position /*(0..1)*/ = time - double(int(time)); int h=Form1->ImageCode->ClientHeight; int w=Form1->ImageCode->ClientWidth; int pos = int(w * position); LOCKCODE; DCTYPE dc; GET_CODEDC(dc); int PenCol; Form1->Memo1->Lines->Add(buf); int tw; TEXTWIDTH(dc,buf,tw); SET_REDPEN(dc); TEXTOUT(dc,buf,pos-tw,1,PenCol); //-tw LINE(dc,pos,0,pos,h,PenCol); UNLOCKCODE; h=Form1->Image3->ClientHeight; LOCK(bmpCanvas); GET_DC(dc); SET_REDPEN(dc); LINE(dc,pos,0,pos,h,PenCol); UNLOCK(bmpCanvas); }
void console_main(void) { enum input_result_enum success; int option, tempint1, tempint2; char tempchar, finished=FALSE; do { TEXTOUT_P(PSTR("\r\n\ \r\n\ ****** Main Menu ******\r\n\ \r\n\ 1. Upload new firmware\r\n\ 2. Speed set\r\n\ 3. Envelope set\r\n\ 4. Enter\r\n\ 5. Exit\r\n\ 6. Finalize\r\n\ 7. Tone\r\n\ 8. Minor\r\n\ 9. Major\r\n\ 0. exit\r\n\ ")); success=getint(&option, 0, 99); //if input failed, exit menu, or refresh menu if(success == INPUT_RESULT_TIMEOUT || success == INPUT_RESULT_ABORTED) finished=TRUE; else if(success == INPUT_RESULT_OK) { switch(option) { case 1: bootload(); break; case 2: getint(&option, -40000, +40000); sheppard_speedset(option); break; case 3: TEXTOUT_P(PSTR("Center ")); getint(&tempint1, 0, 255); TEXTOUT_P(PSTR("Width ")); getint(&tempint2, 1, 200); sheppard_envelopeset(tempint1, tempint2); break; case 4: sheppard_enter(); break; case 5: sheppard_exit(); break; case 6: sheppard_finalize(); break; case 7: sheppard_styleset(STYLE_TONE); break; case 8: sheppard_styleset(STYLE_MINOR); break; case 9: sheppard_styleset(STYLE_MAJOR); break; case 10: while(1) { if(interface_update_speed) { interface_update_speed=FALSE; TEXTOUT("Speed = "); TEXTOUT_INT(interface_output.speed); TEXTOUT("\r\n"); time=2; while(time) main_fly(); }; if(interface_update_window) { interface_update_window=FALSE; if(interface_output.width_onoff) { TEXTOUT("Width = "); TEXTOUT_INT(interface_output.width); TEXTOUT("\r\nCenter = "); TEXTOUT_INT(interface_output.center); TEXTOUT("\r\n\r\n"); sheppard_envelopeset(interface_output.center, interface_output.width); } else { TEXTOUT("Window off\r\n"); sheppard_envelopeset(-1, 0); }; time=2; while(time) main_fly(); }; main_fly(); }; }; };//INPUT_RESULT_NIL will simply refresh }while(!finished); TEXTOUT_P(PSTR("Exit\r\n")); }
//--------------------------------------------------------------------------- int Help() { TEXTOUT("Usage: \"MediaInfo [-Options...] FileName1 [Filename2...]\""); TEXTOUT(""); TEXTOUT("Options:"); TEXTOUT("--Help, -h"); TEXTOUT(" Display this help and exit"); TEXTOUT("--Help-Output"); TEXTOUT(" Display help for Output= option"); TEXTOUT("--Help-AnOption"); TEXTOUT(" Display help for \"AnOption\""); TEXTOUT("--Version"); TEXTOUT(" Display MediaInfo version and exit"); TEXTOUT(""); TEXTOUT("--Full , -f"); TEXTOUT(" Full information Display (all internal tags)"); TEXTOUT("--Output=HTML"); TEXTOUT(" Full information Display with HTML tags"); TEXTOUT("--Output=XML"); TEXTOUT(" Full information Display with XML tags"); TEXTOUT("--Output=...y"); TEXTOUT(" Template defined information Display"); TEXTOUT("--Info-Parameters"); TEXTOUT(" Display list of Inform= parameters"); TEXTOUT(""); TEXTOUT("--Language=raw"); TEXTOUT(" Display non-translated unique identifiers (internal text)"); TEXTOUT("--LogFile=..."); TEXTOUT(" Save the output in the specified file"); TEXTOUT("--BOM"); TEXTOUT(" Byte order mark for UTF-8 output"); TEXTOUT(""); TEXTOUT("--Ssl_CertificateFileName=..."); TEXTOUT(" File name of the SSL certificate."); TEXTOUT(" The default format is \"PEM\" and can be changed"); TEXTOUT(" with --Ssl_CertificateFormat."); TEXTOUT("--Ssl_CertificateFormat=..."); TEXTOUT(" File format of the SSL certificate."); TEXTOUT(" Supported formats are \"PEM\" and \"DER\""); TEXTOUT("--Ssl_PrivateKeyFileName=..."); TEXTOUT(" File name of the SSL private key."); TEXTOUT(" The default format is \"PEM\" and can be changed"); TEXTOUT(" with --Ssl_PrivateKeyFormat."); TEXTOUT(" Note: private key with a password is not supported."); TEXTOUT("--Ssl_PrivateKeyFormat=..."); TEXTOUT(" File format of the SSL private key."); TEXTOUT(" Supported formats are \"PEM\" and \"DER\""); TEXTOUT("--Ssl_CertificateAuthorityFileName=..."); TEXTOUT(" File name of the SSL certificate authorities"); TEXTOUT(" to verify the peer with."); TEXTOUT("--Ssl_CertificateAuthorityPath=..."); TEXTOUT(" Path of the SSL certificate authorities"); TEXTOUT(" to verify the peer with."); TEXTOUT("--Ssl_CertificateRevocationListFileName=..."); TEXTOUT(" File name of the SSL certificate revocation list."); TEXTOUT(" The format is \"PEM\""); TEXTOUT("--Ssl_IgnoreSecurity=..."); TEXTOUT(" Does not verify the authenticity of the peer's certificate"); TEXTOUT(" Use it at your own risks"); TEXTOUT("--Ssh_PublicKeyFileName=..."); TEXTOUT(" File name of the SSH private key."); TEXTOUT(" Default is $HOME/.ssh/id_rsa.pub or $HOME/.ssh/id_dsa.pub"); TEXTOUT(" if the HOME environment variable is set, and just"); TEXTOUT(" \"id_rsa.pub\" or \"id_dsa.pub\" in the current directory"); TEXTOUT(" if HOME is not set."); TEXTOUT(" Note: you need to set both public and private key."); TEXTOUT("--Ssh_PrivateKeyFileName=..."); TEXTOUT(" File name of the SSH private key."); TEXTOUT(" Default is $HOME/.ssh/id_rsa or $HOME/.ssh/id_dsa"); TEXTOUT(" if the HOME environment variable is set, and just"); TEXTOUT(" \"id_rsa\" or \"id_dsa\" in the current directory"); TEXTOUT(" if HOME is not set."); TEXTOUT(" Note: you need to set both public and private key."); TEXTOUT(" Note: private key with a password is not supported."); TEXTOUT("--Ssh_KnownHostsFileName=..."); TEXTOUT(" File name of the known hosts"); TEXTOUT(" The format is the OpenSSH file format (libssh2)"); TEXTOUT(" Default is $HOME/.ssh/known_hosts"); TEXTOUT(" if the HOME environment variable is set, and just"); TEXTOUT(" \"known_hosts\" in the current directory"); TEXTOUT(" if HOME is not set."); TEXTOUT("--Ssh_IgnoreSecurity=..."); TEXTOUT(" Does not verify the authenticity of the peer"); TEXTOUT(" (you don't need to accept the key with ssh first)"); TEXTOUT(" Use it at your own risks"); return -1; }
//--------------------------------------------------------------------------- int Help_Output() { TEXTOUT("--Output=... Specify a template (BETA)"); TEXTOUT("Usage: \"MediaInfo --Output=[xxx;]Text FileName\""); TEXTOUT(""); TEXTOUT("xxx can be: General, Video, Audio, Text, Chapter, Image, Menu"); TEXTOUT("Text can be the template text, or a filename"); TEXTOUT(" Filename must be in the form file://filename"); TEXTOUT(""); TEXTOUT("See --Info-Parameters for available parameters in the text"); TEXTOUT("(Parameters must be surrounded by \"%\" sign)"); TEXTOUT(""); TEXTOUT("Example: \"MediaInfo --Output=Video;%AspectRatio% FileName\""); TEXTOUT(""); TEXTOUT("Example: \"MediaInfo --Output=Video;file://Video.txt FileName\""); TEXTOUT("and Video.txt contains "); TEXTOUT("\"%DisplayAspectRatio%\" for Video Aspect Ratio."); TEXTOUT(""); TEXTOUT("Example: \"MediaInfo --Output=file://Text.txt FileName\""); TEXTOUT("and Text.txt contains"); TEXTOUT("\"Video;%DisplayAspectRatio%\" for Video Aspect Ratio."); TEXTOUT("\"Audio;%Format%\" for Audio Format."); return -1; }
//--------------------------------------------------------------------------- int Version() { TEXTOUT(std::string("MediaConch Daemon " + MediaConch::Daemon::version).c_str()); return DAEMON_RETURN_FINISH; }
//--------------------------------------------------------------------------- int Help_Usage() { TEXTOUT("Usage: \"MediaConchD [-Options...]\""); return DAEMON_RETURN_ERROR; }
//--------------------------------------------------------------------------- int Help() { Version(); Help_Usage(); TEXTOUT(""); TEXTOUT("Options:"); TEXTOUT("Help:"); TEXTOUT(" --Help, -h"); TEXTOUT(" Display this help and exit"); TEXTOUT(" --Version, -v"); TEXTOUT(" Display the version and exit"); TEXTOUT(""); TEXTOUT("Configuration Element:"); TEXTOUT(" --Configuration=ConfigurationFile, -c ConfigurationFile"); TEXTOUT(" Use ConfigurationFile as configuration file"); TEXTOUT(" Default, it uses the one in the user data application file"); TEXTOUT(" --PluginsConfiguration=PluginsConfigurationFile, -pc PluginsConfigurationFile"); TEXTOUT(" Use PluginsConfigurationFile as plugins configuration file"); TEXTOUT(" Default, it uses the struct in the configuration file or"); TEXTOUT(" no plugins configured if not inside."); TEXTOUT(""); TEXTOUT("Implementation Checker:"); TEXTOUT(" --ImplementationSchema=File, -i File"); TEXTOUT(" Use the specified File for implementation validation"); TEXTOUT(" --ImplementationVerbosity=V, -iv V"); TEXTOUT(" Select verbosity (V) of the implementation check, default 5"); TEXTOUT(" <= 4, show only fails and N/A"); TEXTOUT(" >= 5, show fails, N/A and pass"); TEXTOUT(""); TEXTOUT("Daemon fork:"); TEXTOUT(" --Fork=[Yes/No]"); TEXTOUT(" If No, MediaConchd will not fork, default it forks"); TEXTOUT(" -n"); TEXTOUT(" Same as --Fork=No"); TEXTOUT(""); TEXTOUT("Daemon Debug:"); TEXTOUT(" --OutputLog=File, -o File"); TEXTOUT(" Log debug information to File"); TEXTOUT(""); TEXTOUT("Watch folder:"); TEXTOUT(" --WatchFolder=folder, -wf folder"); TEXTOUT(" Send to the server a folder to watch"); TEXTOUT(" --WatchFolder-Reports=folder, -wfr folder"); TEXTOUT(" Create reports of the selected watch folder to this folder"); TEXTOUT(" --WatchFolder-Not-Recursive"); TEXTOUT(" If watch folder is enabled, do not check recursively the folder"); TEXTOUT(" --Plugin=PluginID"); TEXTOUT(" By default, only format plugin are used."); TEXTOUT(" With this command, you can give the plugin ID you want to use."); TEXTOUT(" Plugin ID can be get using the --pluginslist."); TEXTOUT(" --PluginsList"); TEXTOUT(" Output the plugins information ID"); TEXTOUT(" --Policy=PolicyFile, -p PolicyFile"); TEXTOUT(" Policy used by the watch folder manager."); TEXTOUT(""); return DAEMON_RETURN_FINISH; }