mirror of
https://github.com/lltcggie/waifu2x-caffe.git
synced 2025-06-25 21:22:47 +00:00
tclapwの名前空間変更
This commit is contained in:
parent
da933de66d
commit
c232046e23
@ -22,8 +22,8 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_ARGUMENT_H
|
||||
#define TCLAP_ARGUMENT_H
|
||||
#ifndef TCLAPW_ARGUMENT_H
|
||||
#define TCLAPW_ARGUMENT_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
@ -54,7 +54,7 @@ typedef std::istrstream istringstream;
|
||||
#include <tclapw/ArgTraits.h>
|
||||
#include <tclapw/StandardTraits.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A virtual base class that defines the essential data for all arguments.
|
||||
@ -223,31 +223,31 @@ class Arg
|
||||
|
||||
/**
|
||||
* The wchar_t that indicates the beginning of a flag. Defaults to L'-', but
|
||||
* clients can define TCLAP_FLAGSTARTCHAR to override.
|
||||
* clients can define TCLAPW_FLAGSTARTCHAR to override.
|
||||
*/
|
||||
#ifndef TCLAP_FLAGSTARTCHAR
|
||||
#define TCLAP_FLAGSTARTCHAR L'-'
|
||||
#ifndef TCLAPW_FLAGSTARTCHAR
|
||||
#define TCLAPW_FLAGSTARTCHAR L'-'
|
||||
#endif
|
||||
static wchar_t flagStartChar() { return TCLAP_FLAGSTARTCHAR; }
|
||||
static wchar_t flagStartChar() { return TCLAPW_FLAGSTARTCHAR; }
|
||||
|
||||
/**
|
||||
* The sting that indicates the beginning of a flag. Defaults to L"-", but
|
||||
* clients can define TCLAP_FLAGSTARTSTRING to override. Should be the same
|
||||
* as TCLAP_FLAGSTARTCHAR.
|
||||
* clients can define TCLAPW_FLAGSTARTSTRING to override. Should be the same
|
||||
* as TCLAPW_FLAGSTARTCHAR.
|
||||
*/
|
||||
#ifndef TCLAP_FLAGSTARTSTRING
|
||||
#define TCLAP_FLAGSTARTSTRING L"-"
|
||||
#ifndef TCLAPW_FLAGSTARTSTRING
|
||||
#define TCLAPW_FLAGSTARTSTRING L"-"
|
||||
#endif
|
||||
static const std::wstring flagStartString() { return TCLAP_FLAGSTARTSTRING; }
|
||||
static const std::wstring flagStartString() { return TCLAPW_FLAGSTARTSTRING; }
|
||||
|
||||
/**
|
||||
* The sting that indicates the beginning of a name. Defaults to L"--", but
|
||||
* clients can define TCLAP_NAMESTARTSTRING to override.
|
||||
* clients can define TCLAPW_NAMESTARTSTRING to override.
|
||||
*/
|
||||
#ifndef TCLAP_NAMESTARTSTRING
|
||||
#define TCLAP_NAMESTARTSTRING L"--"
|
||||
#ifndef TCLAPW_NAMESTARTSTRING
|
||||
#define TCLAPW_NAMESTARTSTRING L"--"
|
||||
#endif
|
||||
static const std::wstring nameStartString() { return TCLAP_NAMESTARTSTRING; }
|
||||
static const std::wstring nameStartString() { return TCLAPW_NAMESTARTSTRING; }
|
||||
|
||||
/**
|
||||
* The name used to identify the ignore rest argument.
|
||||
@ -425,7 +425,7 @@ ExtractValue(T &destVal, const std::wstring& strVal, ValueLike vl)
|
||||
int valuesRead = 0;
|
||||
while ( is.good() ) {
|
||||
if ( is.peek() != EOF )
|
||||
#ifdef TCLAP_SETBASE_ZERO
|
||||
#ifdef TCLAPW_SETBASE_ZERO
|
||||
is >> std::setbase(0) >> destVal;
|
||||
#else
|
||||
is >> destVal;
|
||||
@ -691,7 +691,7 @@ inline void Arg::reset()
|
||||
//END Arg.cpp
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -21,13 +21,13 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_ARG_EXCEPTION_H
|
||||
#define TCLAP_ARG_EXCEPTION_H
|
||||
#ifndef TCLAPW_ARG_EXCEPTION_H
|
||||
#define TCLAPW_ARG_EXCEPTION_H
|
||||
|
||||
#include <string>
|
||||
#include <exception>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A simple class that defines and argument exception. Should be caught
|
||||
@ -197,7 +197,7 @@ private:
|
||||
int _estat;
|
||||
};
|
||||
|
||||
} // namespace TCLAP
|
||||
} // namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -23,10 +23,10 @@
|
||||
// This is an internal tclapw file, you should probably not have to
|
||||
// include this directly
|
||||
|
||||
#ifndef TCLAP_ARGTRAITS_H
|
||||
#define TCLAP_ARGTRAITS_H
|
||||
#ifndef TCLAPW_ARGTRAITS_H
|
||||
#define TCLAPW_ARGTRAITS_H
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
// We use two empty structs to get compile type specialization
|
||||
// function to work
|
||||
|
@ -21,8 +21,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_CMDLINE_H
|
||||
#define TCLAP_CMDLINE_H
|
||||
#ifndef TCLAPW_CMDLINE_H
|
||||
#define TCLAPW_CMDLINE_H
|
||||
|
||||
#include <tclapw/SwitchArg.h>
|
||||
#include <tclapw/MultiSwitchArg.h>
|
||||
@ -48,7 +48,7 @@
|
||||
#include <algorithm>
|
||||
#include <stdlib.h> // Needed for exit(), which isnL't defined in some envs.
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
template<typename T> void DelPtr(T ptr)
|
||||
{
|
||||
@ -629,5 +629,5 @@ inline void CmdLine::reset()
|
||||
|
||||
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
#endif
|
||||
|
@ -20,8 +20,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_COMMANDLINE_INTERFACE_H
|
||||
#define TCLAP_COMMANDLINE_INTERFACE_H
|
||||
#ifndef TCLAPW_COMMANDLINE_INTERFACE_H
|
||||
#define TCLAPW_COMMANDLINE_INTERFACE_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -30,7 +30,7 @@
|
||||
#include <algorithm>
|
||||
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
class Arg;
|
||||
class CmdLineOutput;
|
||||
|
@ -20,8 +20,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_CMDLINEOUTPUT_H
|
||||
#define TCLAP_CMDLINEOUTPUT_H
|
||||
#ifndef TCLAPW_CMDLINEOUTPUT_H
|
||||
#define TCLAPW_CMDLINEOUTPUT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -30,7 +30,7 @@
|
||||
#include <iomanip>
|
||||
#include <algorithm>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
class CmdLineInterface;
|
||||
class ArgException;
|
||||
@ -70,5 +70,5 @@ class CmdLineOutput
|
||||
|
||||
};
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
#endif
|
||||
|
@ -19,8 +19,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_CONSTRAINT_H
|
||||
#define TCLAP_CONSTRAINT_H
|
||||
#ifndef TCLAPW_CONSTRAINT_H
|
||||
#define TCLAPW_CONSTRAINT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -29,7 +29,7 @@
|
||||
#include <iomanip>
|
||||
#include <algorithm>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* The interface that defines the interaction between the Arg and Constraint.
|
||||
@ -64,5 +64,5 @@ class Constraint
|
||||
virtual ~Constraint() { ; }
|
||||
};
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
#endif
|
||||
|
@ -20,8 +20,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_DOCBOOKOUTPUT_H
|
||||
#define TCLAP_DOCBOOKOUTPUT_H
|
||||
#ifndef TCLAPW_DOCBOOKOUTPUT_H
|
||||
#define TCLAPW_DOCBOOKOUTPUT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -34,7 +34,7 @@
|
||||
#include <tclapw/XorHandler.h>
|
||||
#include <tclapw/Arg.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A class that generates DocBook output for usage() method for the
|
||||
@ -295,5 +295,5 @@ inline void DocBookOutput::printLongArg(Arg* a)
|
||||
std::cout << L"</varlistentry>" << std::endl;
|
||||
}
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
#endif
|
||||
|
@ -19,14 +19,14 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_HELP_VISITOR_H
|
||||
#define TCLAP_HELP_VISITOR_H
|
||||
#ifndef TCLAPW_HELP_VISITOR_H
|
||||
#define TCLAPW_HELP_VISITOR_H
|
||||
|
||||
#include <tclapw/CmdLineInterface.h>
|
||||
#include <tclapw/CmdLineOutput.h>
|
||||
#include <tclapw/Visitor.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A Visitor object that calls the usage method of the given CmdLineOutput
|
||||
|
@ -20,13 +20,13 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_IGNORE_REST_VISITOR_H
|
||||
#define TCLAP_IGNORE_REST_VISITOR_H
|
||||
#ifndef TCLAPW_IGNORE_REST_VISITOR_H
|
||||
#define TCLAPW_IGNORE_REST_VISITOR_H
|
||||
|
||||
#include <tclapw/Visitor.h>
|
||||
#include <tclapw/Arg.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A Vistor that tells the CmdLine to begin ignoring arguments after
|
||||
|
@ -20,8 +20,8 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_MULTIPLE_ARGUMENT_H
|
||||
#define TCLAP_MULTIPLE_ARGUMENT_H
|
||||
#ifndef TCLAPW_MULTIPLE_ARGUMENT_H
|
||||
#define TCLAPW_MULTIPLE_ARGUMENT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -29,7 +29,7 @@
|
||||
#include <tclapw/Arg.h>
|
||||
#include <tclapw/Constraint.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
/**
|
||||
* An argument that allows multiple values of type T to be specified. Very
|
||||
* similar to a ValueArg, except a vector of values will be returned
|
||||
@ -428,6 +428,6 @@ void MultiArg<T>::reset()
|
||||
_values.clear();
|
||||
}
|
||||
|
||||
} // namespace TCLAP
|
||||
} // namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
@ -22,15 +22,15 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_MULTI_SWITCH_ARG_H
|
||||
#define TCLAP_MULTI_SWITCH_ARG_H
|
||||
#ifndef TCLAPW_MULTI_SWITCH_ARG_H
|
||||
#define TCLAPW_MULTI_SWITCH_ARG_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include <tclapw/SwitchArg.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A multiple switch argument. If the switch is set on the command line, then
|
||||
@ -211,6 +211,6 @@ MultiSwitchArg::reset()
|
||||
//END MultiSwitchArg.cpp
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
@ -21,12 +21,12 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_OPTIONAL_UNLABELED_TRACKER_H
|
||||
#define TCLAP_OPTIONAL_UNLABELED_TRACKER_H
|
||||
#ifndef TCLAPW_OPTIONAL_UNLABELED_TRACKER_H
|
||||
#define TCLAPW_OPTIONAL_UNLABELED_TRACKER_H
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
class OptionalUnlabeledTracker
|
||||
{
|
||||
@ -57,6 +57,6 @@ inline void OptionalUnlabeledTracker::check( bool req, const std::wstring& argNa
|
||||
}
|
||||
|
||||
|
||||
} // namespace TCLAP
|
||||
} // namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
@ -23,8 +23,8 @@
|
||||
// This is an internal tclapw file, you should probably not have to
|
||||
// include this directly
|
||||
|
||||
#ifndef TCLAP_STANDARD_TRAITS_H
|
||||
#define TCLAP_STANDARD_TRAITS_H
|
||||
#ifndef TCLAPW_STANDARD_TRAITS_H
|
||||
#define TCLAPW_STANDARD_TRAITS_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h> // To check for long long
|
||||
@ -35,11 +35,11 @@
|
||||
// creating ArgTraits twice for unsigned short. Thus...
|
||||
#ifdef _MSC_VER
|
||||
#ifndef _NATIVE_WCHAR_T_DEFINED
|
||||
#define TCLAP_DONT_DECLARE_WCHAR_T_ARGTRAITS
|
||||
#define TCLAPW_DONT_DECLARE_WCHAR_T_ARGTRAITS
|
||||
#endif
|
||||
#endif
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
// ======================================================================
|
||||
// Integer types
|
||||
@ -181,7 +181,7 @@ struct ArgTraits<bool> {
|
||||
/**
|
||||
* wchar_ts have value-like semantics.
|
||||
*/
|
||||
#ifndef TCLAP_DONT_DECLARE_WCHAR_T_ARGTRAITS
|
||||
#ifndef TCLAPW_DONT_DECLARE_WCHAR_T_ARGTRAITS
|
||||
template<>
|
||||
struct ArgTraits<wchar_t> {
|
||||
typedef ValueLike ValueCategory;
|
||||
|
@ -20,8 +20,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_STDCMDLINEOUTPUT_H
|
||||
#define TCLAP_STDCMDLINEOUTPUT_H
|
||||
#ifndef TCLAPW_STDCMDLINEOUTPUT_H
|
||||
#define TCLAPW_STDCMDLINEOUTPUT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -34,7 +34,7 @@
|
||||
#include <tclapw/XorHandler.h>
|
||||
#include <tclapw/Arg.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A class that isolates any output from the CmdLine object so that it
|
||||
@ -294,5 +294,5 @@ inline void StdOutput::spacePrint( std::wostream& os,
|
||||
}
|
||||
}
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
#endif
|
||||
|
@ -21,15 +21,15 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_SWITCH_ARG_H
|
||||
#define TCLAP_SWITCH_ARG_H
|
||||
#ifndef TCLAPW_SWITCH_ARG_H
|
||||
#define TCLAPW_SWITCH_ARG_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include <tclapw/Arg.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A simple switch argument. If the switch is set on the command line, then
|
||||
@ -261,6 +261,6 @@ inline void SwitchArg::reset()
|
||||
//End SwitchArg.cpp
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
@ -20,8 +20,8 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_MULTIPLE_UNLABELED_ARGUMENT_H
|
||||
#define TCLAP_MULTIPLE_UNLABELED_ARGUMENT_H
|
||||
#ifndef TCLAPW_MULTIPLE_UNLABELED_ARGUMENT_H
|
||||
#define TCLAPW_MULTIPLE_UNLABELED_ARGUMENT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -29,7 +29,7 @@
|
||||
#include <tclapw/MultiArg.h>
|
||||
#include <tclapw/OptionalUnlabeledTracker.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* Just like a MultiArg, except that the arguments are unlabeled. Basically,
|
||||
|
@ -21,8 +21,8 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_UNLABELED_VALUE_ARGUMENT_H
|
||||
#define TCLAP_UNLABELED_VALUE_ARGUMENT_H
|
||||
#ifndef TCLAPW_UNLABELED_VALUE_ARGUMENT_H
|
||||
#define TCLAPW_UNLABELED_VALUE_ARGUMENT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -31,7 +31,7 @@
|
||||
#include <tclapw/OptionalUnlabeledTracker.h>
|
||||
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* The basic unlabeled argument that parses a value.
|
||||
|
@ -20,8 +20,8 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_VALUE_ARGUMENT_H
|
||||
#define TCLAP_VALUE_ARGUMENT_H
|
||||
#ifndef TCLAPW_VALUE_ARGUMENT_H
|
||||
#define TCLAPW_VALUE_ARGUMENT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -29,7 +29,7 @@
|
||||
#include <tclapw/Arg.h>
|
||||
#include <tclapw/Constraint.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* The basic labeled argument that parses a value.
|
||||
@ -420,6 +420,6 @@ void ValueArg<T>::reset()
|
||||
_value = _default;
|
||||
}
|
||||
|
||||
} // namespace TCLAP
|
||||
} // namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
@ -20,8 +20,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_VALUESCONSTRAINT_H
|
||||
#define TCLAP_VALUESCONSTRAINT_H
|
||||
#ifndef TCLAPW_VALUESCONSTRAINT_H
|
||||
#define TCLAPW_VALUESCONSTRAINT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -41,7 +41,7 @@
|
||||
#error L"Need a stringstream (sstream or strstream) to compile!"
|
||||
#endif
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A Constraint that constrains the Arg to only those values specified
|
||||
@ -143,6 +143,6 @@ std::wstring ValuesConstraint<T>::description() const
|
||||
}
|
||||
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
#endif
|
||||
|
||||
|
@ -21,14 +21,14 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_VERSION_VISITOR_H
|
||||
#define TCLAP_VERSION_VISITOR_H
|
||||
#ifndef TCLAPW_VERSION_VISITOR_H
|
||||
#define TCLAPW_VERSION_VISITOR_H
|
||||
|
||||
#include <tclapw/CmdLineInterface.h>
|
||||
#include <tclapw/CmdLineOutput.h>
|
||||
#include <tclapw/Visitor.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A Vistor that will call the version method of the given CmdLineOutput
|
||||
|
@ -20,10 +20,10 @@
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#ifndef TCLAP_VISITOR_H
|
||||
#define TCLAP_VISITOR_H
|
||||
#ifndef TCLAPW_VISITOR_H
|
||||
#define TCLAPW_VISITOR_H
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A base class that defines the interface for visitors.
|
||||
|
@ -20,8 +20,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_XORHANDLER_H
|
||||
#define TCLAP_XORHANDLER_H
|
||||
#ifndef TCLAPW_XORHANDLER_H
|
||||
#define TCLAPW_XORHANDLER_H
|
||||
|
||||
#include <tclapw/Arg.h>
|
||||
#include <string>
|
||||
@ -29,7 +29,7 @@
|
||||
#include <algorithm>
|
||||
#include <iostream>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* This class handles lists of ArgL's that are to be XOR'd on the command
|
||||
@ -161,6 +161,6 @@ inline std::vector< std::vector<Arg*> >& XorHandler::getXorList()
|
||||
//END XOR.cpp
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
|
||||
#endif
|
||||
|
@ -20,8 +20,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef TCLAP_ZSHCOMPLETIONOUTPUT_H
|
||||
#define TCLAP_ZSHCOMPLETIONOUTPUT_H
|
||||
#ifndef TCLAPW_ZSHCOMPLETIONOUTPUT_H
|
||||
#define TCLAPW_ZSHCOMPLETIONOUTPUT_H
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
@ -34,7 +34,7 @@
|
||||
#include <tclapw/XorHandler.h>
|
||||
#include <tclapw/Arg.h>
|
||||
|
||||
namespace TCLAP {
|
||||
namespace TCLAPW {
|
||||
|
||||
/**
|
||||
* A class that generates a Zsh completion function as output from the usage()
|
||||
@ -319,5 +319,5 @@ inline std::wstring ZshCompletionOutput::getMutexList( CmdLineInterface& _cmd, A
|
||||
return list.str();
|
||||
}
|
||||
|
||||
} //namespace TCLAP
|
||||
} //namespace TCLAPW
|
||||
#endif
|
||||
|
@ -2095,22 +2095,22 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData)
|
||||
if (nArgs > 1)
|
||||
{
|
||||
// definition of command line arguments
|
||||
TCLAP::CmdLine cmd(L"waifu2x reimplementation using Caffe", L' ', L"1.0.0");
|
||||
TCLAPW::CmdLine cmd(L"waifu2x reimplementation using Caffe", L' ', L"1.0.0");
|
||||
|
||||
// GUIでは-iを付けない
|
||||
TCLAP::UnlabeledMultiArg<std::wstring> cmdInputFile(L"input_file_paths", L"input file paths", false,
|
||||
TCLAPW::UnlabeledMultiArg<std::wstring> cmdInputFile(L"input_file_paths", L"input file paths", false,
|
||||
L"string", cmd);
|
||||
|
||||
// GUIでは出力先フォルダのみの指定
|
||||
TCLAP::ValueArg<std::wstring> cmdOutputDir(L"o", L"output_folder",
|
||||
TCLAPW::ValueArg<std::wstring> cmdOutputDir(L"o", L"output_folder",
|
||||
L"path to output image folder", false,
|
||||
L"", L"string", cmd);
|
||||
|
||||
TCLAP::ValueArg<std::wstring> cmdInputFileExt(L"l", L"input_extention_list",
|
||||
TCLAPW::ValueArg<std::wstring> cmdInputFileExt(L"l", L"input_extention_list",
|
||||
L"extention to input image file when input_path is folder", false, L"png:jpg:jpeg:tif:tiff:bmp:tga",
|
||||
L"string", cmd);
|
||||
|
||||
TCLAP::ValueArg<std::wstring> cmdOutputFileExt(L"e", L"output_extention",
|
||||
TCLAPW::ValueArg<std::wstring> cmdOutputFileExt(L"e", L"output_extention",
|
||||
L"extention to output image file when output_path is (auto) or input_path is folder", false,
|
||||
L"png", L"string", cmd);
|
||||
|
||||
@ -2119,8 +2119,8 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData)
|
||||
cmdModeConstraintV.push_back(L"scale");
|
||||
cmdModeConstraintV.push_back(L"noise_scale");
|
||||
cmdModeConstraintV.push_back(L"auto_scale");
|
||||
TCLAP::ValuesConstraint<std::wstring> cmdModeConstraint(cmdModeConstraintV);
|
||||
TCLAP::ValueArg<std::wstring> cmdMode(L"m", L"mode", L"image processing mode",
|
||||
TCLAPW::ValuesConstraint<std::wstring> cmdModeConstraint(cmdModeConstraintV);
|
||||
TCLAPW::ValueArg<std::wstring> cmdMode(L"m", L"mode", L"image processing mode",
|
||||
false, L"noise_scale", &cmdModeConstraint, cmd);
|
||||
|
||||
std::vector<int> cmdNRLConstraintV;
|
||||
@ -2128,43 +2128,43 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData)
|
||||
cmdNRLConstraintV.push_back(1);
|
||||
cmdNRLConstraintV.push_back(2);
|
||||
cmdNRLConstraintV.push_back(3);
|
||||
TCLAP::ValuesConstraint<int> cmdNRLConstraint(cmdNRLConstraintV);
|
||||
TCLAP::ValueArg<int> cmdNRLevel(L"n", L"noise_level", L"noise reduction level",
|
||||
TCLAPW::ValuesConstraint<int> cmdNRLConstraint(cmdNRLConstraintV);
|
||||
TCLAPW::ValueArg<int> cmdNRLevel(L"n", L"noise_level", L"noise reduction level",
|
||||
false, 0, &cmdNRLConstraint, cmd);
|
||||
|
||||
TCLAP::ValueArg<double> cmdScaleRatio(L"s", L"scale_ratio",
|
||||
TCLAPW::ValueArg<double> cmdScaleRatio(L"s", L"scale_ratio",
|
||||
L"custom scale ratio", false, 2.0, L"double", cmd);
|
||||
|
||||
TCLAP::ValueArg<int> cmdScaleWidth(L"w", L"scale_width",
|
||||
TCLAPW::ValueArg<int> cmdScaleWidth(L"w", L"scale_width",
|
||||
L"custom scale width", false, 0, L"double", cmd);
|
||||
|
||||
TCLAP::ValueArg<int> cmdScaleHeight(L"h", L"scale_height",
|
||||
TCLAPW::ValueArg<int> cmdScaleHeight(L"h", L"scale_height",
|
||||
L"custom scale height", false, 0, L"double", cmd);
|
||||
|
||||
std::vector<std::wstring> cmdProcessConstraintV;
|
||||
cmdProcessConstraintV.push_back(L"cpu");
|
||||
cmdProcessConstraintV.push_back(L"gpu");
|
||||
TCLAP::ValuesConstraint<std::wstring> cmdProcessConstraint(cmdProcessConstraintV);
|
||||
TCLAP::ValueArg<std::wstring> cmdProcess(L"p", L"process", L"process mode",
|
||||
TCLAPW::ValuesConstraint<std::wstring> cmdProcessConstraint(cmdProcessConstraintV);
|
||||
TCLAPW::ValueArg<std::wstring> cmdProcess(L"p", L"process", L"process mode",
|
||||
false, L"gpu", &cmdProcessConstraint, cmd);
|
||||
|
||||
TCLAP::ValueArg<int> cmdOutputQuality(L"q", L"output_quality",
|
||||
TCLAPW::ValueArg<int> cmdOutputQuality(L"q", L"output_quality",
|
||||
L"output image quality", false,
|
||||
-1, L"int", cmd);
|
||||
|
||||
TCLAP::ValueArg<int> cmdOutputDepth(L"d", L"output_depth",
|
||||
TCLAPW::ValueArg<int> cmdOutputDepth(L"d", L"output_depth",
|
||||
L"output image chaneel depth bit", false,
|
||||
8, L"int", cmd);
|
||||
|
||||
TCLAP::ValueArg<int> cmdCropSizeFile(L"c", L"crop_size",
|
||||
TCLAPW::ValueArg<int> cmdCropSizeFile(L"c", L"crop_size",
|
||||
L"input image split size", false,
|
||||
128, L"int", cmd);
|
||||
|
||||
TCLAP::ValueArg<int> cmdBatchSizeFile(L"b", L"batch_size",
|
||||
TCLAPW::ValueArg<int> cmdBatchSizeFile(L"b", L"batch_size",
|
||||
L"input batch size", false,
|
||||
1, L"int", cmd);
|
||||
|
||||
TCLAP::ValueArg<int> cmdGPUNoFile(L"", L"gpu",
|
||||
TCLAPW::ValueArg<int> cmdGPUNoFile(L"", L"gpu",
|
||||
L"gpu device no", false,
|
||||
0, L"int", cmd);
|
||||
|
||||
@ -2172,21 +2172,21 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData)
|
||||
cmdBoolConstraintV.push_back(0);
|
||||
cmdBoolConstraintV.push_back(1);
|
||||
|
||||
TCLAP::ValuesConstraint<int> cmdTTAConstraint(cmdBoolConstraintV);
|
||||
TCLAP::ValueArg<int> cmdTTA(L"t", L"tta", L"8x slower and slightly high quality",
|
||||
TCLAPW::ValuesConstraint<int> cmdTTAConstraint(cmdBoolConstraintV);
|
||||
TCLAPW::ValueArg<int> cmdTTA(L"t", L"tta", L"8x slower and slightly high quality",
|
||||
false, 0, &cmdTTAConstraint, cmd);
|
||||
|
||||
// GUI独自
|
||||
TCLAP::ValuesConstraint<int> cmdAutoStartConstraint(cmdBoolConstraintV);
|
||||
TCLAP::ValueArg<int> cmdAutoStart(L"", L"auto_start", L"to run automatically at startup",
|
||||
TCLAPW::ValuesConstraint<int> cmdAutoStartConstraint(cmdBoolConstraintV);
|
||||
TCLAPW::ValueArg<int> cmdAutoStart(L"", L"auto_start", L"to run automatically at startup",
|
||||
false, 0, &cmdAutoStartConstraint, cmd);
|
||||
|
||||
TCLAP::ValuesConstraint<int> cmdAutoExitConstraint(cmdBoolConstraintV);
|
||||
TCLAP::ValueArg<int> cmdAutoExit(L"", L"auto_exit", L"exit when the run was succeeded",
|
||||
TCLAPW::ValuesConstraint<int> cmdAutoExitConstraint(cmdBoolConstraintV);
|
||||
TCLAPW::ValueArg<int> cmdAutoExit(L"", L"auto_exit", L"exit when the run was succeeded",
|
||||
false, 0, &cmdAutoExitConstraint, cmd);
|
||||
|
||||
TCLAP::ValuesConstraint<int> cmdNoOverwriteConstraint(cmdBoolConstraintV);
|
||||
TCLAP::ValueArg<int> cmdNoOverwrite(L"", L"no_overwrite", L"don't overwrite output file",
|
||||
TCLAPW::ValuesConstraint<int> cmdNoOverwriteConstraint(cmdBoolConstraintV);
|
||||
TCLAPW::ValueArg<int> cmdNoOverwrite(L"", L"no_overwrite", L"don't overwrite output file",
|
||||
false, 0, &cmdNoOverwriteConstraint, cmd);
|
||||
|
||||
std::vector<std::wstring> cmdModelTypeConstraintV;
|
||||
@ -2195,13 +2195,13 @@ void DialogEvent::Create(HWND hWnd, WPARAM wParam, LPARAM lParam, LPVOID lpData)
|
||||
cmdModelTypeConstraintV.push_back(L"anime_style_art_rgb");
|
||||
cmdModelTypeConstraintV.push_back(L"photo");
|
||||
cmdModelTypeConstraintV.push_back(L"anime_style_art_y");
|
||||
TCLAP::ValuesConstraint<std::wstring> cmdModelTypeConstraint(cmdModelTypeConstraintV);
|
||||
TCLAP::ValueArg<std::wstring> cmdModelType(L"y", L"model_type", L"model type",
|
||||
TCLAPW::ValuesConstraint<std::wstring> cmdModelTypeConstraint(cmdModelTypeConstraintV);
|
||||
TCLAPW::ValueArg<std::wstring> cmdModelType(L"y", L"model_type", L"model type",
|
||||
false, L"upconv_7_anime_style_art_rgb", &cmdModelTypeConstraint, cmd);
|
||||
|
||||
// definition of command line argument : end
|
||||
|
||||
TCLAP::Arg::enableIgnoreMismatched();
|
||||
TCLAPW::Arg::enableIgnoreMismatched();
|
||||
|
||||
// parse command line arguments
|
||||
try
|
||||
|
Loading…
x
Reference in New Issue
Block a user