MCPcopy Create free account
hub / github.com/BZFlag-Dev/bzflag / init

Method init

tools/modeltool/modeltool.cpp:1702–1725  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1700}
1701
1702void ModelToolApp::init(int argc, char* argv[]) {
1703 xRot = 45;
1704 zRot = 0;
1705 zoom = 15;
1706 pan[0] = pan[1] = pan[2] = 0.0f;
1707 buttonStates[0] = buttonStates[1] = buttonStates[2] = false;
1708 dragPos[0] = dragPos[1] = 0;
1709
1710 gridSpacing = 1.0f;
1711 gridExtents = 15.0f;
1712
1713 std::string input;
1714 std::string extenstion = "OBJ";
1715 std::string output;
1716
1717 if (!setupArgs(argc, argv, input, extenstion, output)) {
1718 quit();
1719 return;
1720 }
1721
1722 if (TextUtils::tolower(extenstion) == "obj") {
1723 readOBJ(model, input);
1724 }
1725}
1726
1727bool ModelToolApp::getStartupInfo(int& x, int& y, bool& fullScreen, std::string& title, bool& resizeable) {
1728 x = 640;

Callers 1

GFXMainFunction · 0.45

Calls 3

setupArgsFunction · 0.85
tolowerFunction · 0.85
readOBJFunction · 0.85

Tested by

no test coverage detected