Compare commits
1 Commits
SplashHTML
...
optimizati
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ae174c1fdc |
12
.gitignore
vendored
@@ -36,6 +36,8 @@
|
|||||||
*.user
|
*.user
|
||||||
*.pdb
|
*.pdb
|
||||||
*.idb
|
*.idb
|
||||||
|
*.manifest
|
||||||
|
*.htm
|
||||||
*.res
|
*.res
|
||||||
*.ilk
|
*.ilk
|
||||||
*.dep
|
*.dep
|
||||||
@@ -50,12 +52,6 @@ G3DTest.suo
|
|||||||
G3DTest.suo
|
G3DTest.suo
|
||||||
stderr.txt
|
stderr.txt
|
||||||
desktop.ini
|
desktop.ini
|
||||||
UpgradeLog.XML
|
main.cpp
|
||||||
/_UpgradeReport_Files
|
|
||||||
/.vs
|
|
||||||
*.7.10.old
|
|
||||||
*.db
|
*.db
|
||||||
|
G3DTest.sln
|
||||||
#Redist
|
|
||||||
!Installer/Redist/*
|
|
||||||
UpgradeLog.htm
|
|
||||||
|
|||||||
@@ -1,14 +1,12 @@
|
|||||||
#include <G3DAll.h>
|
#include <G3DAll.h>
|
||||||
#include <initguid.h>
|
#include <initguid.h>
|
||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
|
#include "Instance.h"
|
||||||
#include "resource.h"
|
#include "resource.h"
|
||||||
#include "DataModelV2/Instance.h"
|
#include "PartInstance.h"
|
||||||
#include "DataModelV2/PartInstance.h"
|
#include "TextButtonInstance.h"
|
||||||
#include "DataModelV2/TextButtonInstance.h"
|
#include "ImageButtonInstance.h"
|
||||||
#include "DataModelV2/ImageButtonInstance.h"
|
#include "DataModelInstance.h"
|
||||||
#include "DataModelV2/DataModelInstance.h"
|
|
||||||
#include "DataModelV2/GuiRootInstance.h"
|
|
||||||
#include "XplicitNgine/XplicitNgine.h"
|
|
||||||
#include "CameraController.h"
|
#include "CameraController.h"
|
||||||
#include "AudioPlayer.h"
|
#include "AudioPlayer.h"
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
@@ -22,22 +20,24 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include "ax.h"
|
#include "ax.h"
|
||||||
#include <cguid.h>
|
#include <cguid.h>
|
||||||
|
#include "IEBrowser.h"
|
||||||
#include "PropertyWindow.h"
|
#include "PropertyWindow.h"
|
||||||
#include <commctrl.h>
|
#include <commctrl.h>
|
||||||
#include "StringFunctions.h"
|
#include "StringFunctions.h"
|
||||||
#include "SplashHTML.h"
|
#include "GuiRoot.h"
|
||||||
|
|
||||||
#include "Listener/GUDButtonListener.h"
|
#include "GUDButtonListener.h"
|
||||||
#include "Listener/ModeSelectionListener.h"
|
#include "ModeSelectionListener.h"
|
||||||
#include "Listener/DeleteListener.h"
|
#include "DeleteListener.h"
|
||||||
#include "Listener/CameraButtonListener.h"
|
#include "CameraButtonListener.h"
|
||||||
#include "Listener/RotateButtonListener.h"
|
#include "RotateButtonListener.h"
|
||||||
#include "Faces.h"
|
|
||||||
#define LEGACY_LOAD_G3DFUN_LEVEL
|
Ray testRay;
|
||||||
//Ray testRay;
|
static int cursorid = 0;
|
||||||
//static int cursorid = 0;
|
static int cursorOvrid = 0;
|
||||||
//static int cursorOvrid = 0;
|
static int currentcursorid = 0;
|
||||||
//static int currentcursorid = 0;
|
static G3D::TextureRef cursor = NULL;
|
||||||
|
static G3D::TextureRef cursorOvr = NULL;
|
||||||
static bool mouseMovedBeginMotion = false;
|
static bool mouseMovedBeginMotion = false;
|
||||||
static POINT oldGlobalMouse;
|
static POINT oldGlobalMouse;
|
||||||
Vector2 oldMouse = Vector2(0,0);
|
Vector2 oldMouse = Vector2(0,0);
|
||||||
@@ -71,7 +71,7 @@ void Application::setFocus(bool focus)
|
|||||||
Application::Application(HWND parentWindow) : _propWindow(NULL) { //: GApp(settings,window) {
|
Application::Application(HWND parentWindow) : _propWindow(NULL) { //: GApp(settings,window) {
|
||||||
|
|
||||||
|
|
||||||
std::string tempPath = ((std::string)getenv("temp")) + "/"+g_appName;
|
std::string tempPath = ((std::string)getenv("temp")) + "/"+g_PlaceholderName;
|
||||||
CreateDirectory(tempPath.c_str(), NULL);
|
CreateDirectory(tempPath.c_str(), NULL);
|
||||||
|
|
||||||
_hWndMain = parentWindow;
|
_hWndMain = parentWindow;
|
||||||
@@ -114,7 +114,7 @@ Application::Application(HWND parentWindow) : _propWindow(NULL) { //: GApp(setti
|
|||||||
Win32Window* window = Win32Window::create(_settings.window,_hwndRenderer);
|
Win32Window* window = Win32Window::create(_settings.window,_hwndRenderer);
|
||||||
ShowWindow(_hwndRenderer, SW_SHOW);
|
ShowWindow(_hwndRenderer, SW_SHOW);
|
||||||
ShowWindow(_hWndMain, SW_SHOW);
|
ShowWindow(_hWndMain, SW_SHOW);
|
||||||
|
|
||||||
quit=false;
|
quit=false;
|
||||||
rightButtonHolding=false;
|
rightButtonHolding=false;
|
||||||
mouseOnScreen=false;
|
mouseOnScreen=false;
|
||||||
@@ -135,163 +135,131 @@ Application::Application(HWND parentWindow) : _propWindow(NULL) { //: GApp(setti
|
|||||||
SetWindowLongPtr(_hWndMain,GWL_USERDATA,(LONG)this);
|
SetWindowLongPtr(_hWndMain,GWL_USERDATA,(LONG)this);
|
||||||
SetWindowLongPtr(_hwndRenderer,GWL_USERDATA,(LONG)this);
|
SetWindowLongPtr(_hwndRenderer,GWL_USERDATA,(LONG)this);
|
||||||
_propWindow = new PropertyWindow(0, 0, 200, 640, hThisInstance);
|
_propWindow = new PropertyWindow(0, 0, 200, 640, hThisInstance);
|
||||||
webBrowser = new IEBrowser(_hwndToolbox);
|
IEBrowser* webBrowser = new IEBrowser(_hwndToolbox);
|
||||||
|
webBrowser->navigateSyncURL(L"http://androdome.com/g3d/toolbox/");
|
||||||
SetProp(_hwndToolbox,"Browser",(HANDLE)webBrowser);
|
|
||||||
//navigateToolbox("http://androdome.com/res/ClientToolbox.php");
|
|
||||||
navigateToolbox(GetFileInPath("/content/page/surface.html"));
|
|
||||||
//navigateToolbox(GetFileInPath("/content/page/controller.html"));
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Application::viewportHasFocus()
|
|
||||||
{
|
|
||||||
return GetActiveWindow() == this->_hWndMain;
|
|
||||||
}
|
|
||||||
|
|
||||||
void Application::navigateToolbox(std::string path)
|
|
||||||
{
|
|
||||||
int len = path.size() + 1;
|
|
||||||
wchar_t * nstr = new wchar_t[len];
|
|
||||||
MultiByteToWideChar(0, 0, path.c_str(), len, nstr, len);
|
|
||||||
webBrowser->navigateSyncURL(nstr);
|
|
||||||
delete[] nstr;
|
|
||||||
}
|
|
||||||
|
|
||||||
void Application::deleteInstance()
|
void Application::deleteInstance()
|
||||||
{
|
{
|
||||||
if(_dataModel->getSelectionService()->getSelection().size() > 0)
|
if(g_selectedInstances.size() > 0)
|
||||||
{
|
{
|
||||||
std::vector<Instance *> selection = _dataModel->getSelectionService()->getSelection();
|
size_t undeletable = 0;
|
||||||
std::vector<Instance *> toDelete;
|
while(g_selectedInstances.size() > undeletable)
|
||||||
for(size_t i = 0; i < selection.size(); i++) {
|
|
||||||
if(selection[i]->canDelete) {
|
|
||||||
toDelete.push_back(selection[i]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if(toDelete.size() > 0)
|
|
||||||
{
|
{
|
||||||
AudioPlayer::playSound(GetFileInPath("/content/sounds/pageturn.wav"));
|
if(g_selectedInstances.at(0)->canDelete)
|
||||||
for(size_t i = 0; i < toDelete.size(); i++) {
|
{
|
||||||
Instance* selectedInstance = toDelete[i];
|
AudioPlayer::playSound(GetFileInPath("/content/sounds/pageturn.wav"));
|
||||||
_dataModel->getSelectionService()->removeSelected(selectedInstance);
|
Instance* selectedInstance = g_selectedInstances.at(0);
|
||||||
selectedInstance->setParent(NULL);
|
if(selectedInstance->getParent() != NULL)
|
||||||
|
selectedInstance->getParent()->removeChild(selectedInstance);
|
||||||
delete selectedInstance;
|
delete selectedInstance;
|
||||||
selectedInstance = NULL;
|
selectedInstance = NULL;
|
||||||
|
g_selectedInstances.erase(g_selectedInstances.begin());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
undeletable++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(_dataModel->getSelectionService()->getSelection().size() == 0)
|
if(g_selectedInstances.size() == 0)
|
||||||
_dataModel->getSelectionService()->addSelected(_dataModel);
|
g_usableApp->_propWindow->ClearProperties();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Application::onInit() {
|
void Application::onInit() {
|
||||||
tool = new Tool();
|
|
||||||
// Called before Application::run() beings
|
// Called before Application::run() beings
|
||||||
cameraController.setFrame(Vector3(0,2,10));
|
cameraController.setFrame(Vector3(0,2,10));
|
||||||
_dataModel = new DataModelInstance();
|
_dataModel = new DataModelInstance();
|
||||||
_dataModel->setParent(NULL);
|
_dataModel->setParent(NULL);
|
||||||
_dataModel->setName("undefined");
|
_dataModel->name = "undefined";
|
||||||
_dataModel->font = g_fntdominant;
|
_dataModel->font = g_fntdominant;
|
||||||
g_dataModel = _dataModel;
|
g_dataModel = _dataModel;
|
||||||
|
|
||||||
|
//initGUI();
|
||||||
|
|
||||||
#ifdef LEGACY_LOAD_G3DFUN_LEVEL
|
#ifdef LEGACY_LOAD_G3DFUN_LEVEL
|
||||||
// Anchored this baseplate for XplicitNgine tests
|
|
||||||
PartInstance* test = makePart();
|
PartInstance* test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3(0.2F,0.3F,1);
|
test->color = Color3(0.2F,0.3F,1);
|
||||||
test->setSize(Vector3(24,1,24));
|
test->setSize(Vector3(24,1,24));
|
||||||
test->setPosition(Vector3(0,0,0));
|
test->setPosition(Vector3(0,0,0));
|
||||||
test->setCFrame(test->getCFrame() * Matrix3::fromEulerAnglesXYZ(0,toRadians(0),toRadians(0)));
|
test->setCFrame(test->getCFrame() * Matrix3::fromEulerAnglesXYZ(0,toRadians(0),toRadians(0)));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
test->setAnchored(true);
|
|
||||||
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3(.5F,1,.5F);
|
test->color = Color3(.5F,1,.5F);
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(-10,1,0));
|
test->setPosition(Vector3(-10,1,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3(.5F,1,.5F);
|
test->color = Color3(.5F,1,.5F);
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(10,1,0));
|
test->setPosition(Vector3(10,1,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(7,2,0));
|
test->setPosition(Vector3(7,2,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(-7,2,0));
|
test->setPosition(Vector3(-7,2,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(4,3,0));
|
test->setPosition(Vector3(4,3,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(-5,3,0));
|
test->setPosition(Vector3(-5,3,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(1,4,0));
|
test->setPosition(Vector3(1,4,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(-3,4,0));
|
test->setPosition(Vector3(-3,4,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(-2,5,0));
|
test->setPosition(Vector3(-2,5,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(0,6,0));
|
test->setPosition(Vector3(0,6,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
|
|
||||||
test = makePart();
|
test = makePart();
|
||||||
test->setParent(_dataModel->getWorkspace());
|
test->setParent(_dataModel->getWorkspace());
|
||||||
test->color = Color3::gray();
|
test->color = Color3::gray();
|
||||||
test->setSize(Vector3(4,1,2));
|
test->setSize(Vector3(4,1,2));
|
||||||
test->setPosition(Vector3(2,7,0));
|
test->setPosition(Vector3(2,7,0));
|
||||||
test->setSurface(TOP, Enum::SurfaceType::Bumps);
|
|
||||||
#else
|
#else
|
||||||
_dataModel->debugGetOpen();
|
_dataModel->debugGetOpen();
|
||||||
#endif
|
#endif
|
||||||
LevelInstance * level = g_dataModel->getLevel();
|
|
||||||
std::string GetCurrentSplash = level->SplashHTML;
|
|
||||||
SplashHTMLLoad(GetCurrentSplash);
|
|
||||||
|
|
||||||
_dataModel->getSelectionService()->clearSelection();
|
|
||||||
_dataModel->getSelectionService()->addSelected(_dataModel);
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -304,15 +272,28 @@ void Application::onInit() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void Application::onCleanup() {
|
void Application::onCleanup() {
|
||||||
clearInstances();
|
clearInstances();
|
||||||
sky->~Sky();
|
sky->~Sky();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void Application::onLogic() {
|
void Application::onLogic() {
|
||||||
|
// Add non-simulation game logic and AI code here
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Application::onNetwork() {
|
void Application::onNetwork() {
|
||||||
// Poll net messages here
|
// Poll net messages here
|
||||||
}
|
}
|
||||||
@@ -323,38 +304,14 @@ void Application::onNetwork() {
|
|||||||
// return pow(pow((double)vector1.x - (double)vector2.x, 2) + pow((double)vector1.y - (double)vector2.y, 2) + pow((double)vector1.z - (double)vector2.z, 2), 0.5);
|
// return pow(pow((double)vector1.x - (double)vector2.x, 2) + pow((double)vector1.y - (double)vector2.y, 2) + pow((double)vector1.z - (double)vector2.z, 2), 0.5);
|
||||||
//}
|
//}
|
||||||
|
|
||||||
|
std::vector<Instance*> Application::getSelection()
|
||||||
|
{
|
||||||
|
return g_selectedInstances;
|
||||||
|
}
|
||||||
void Application::onSimulation(RealTime rdt, SimTime sdt, SimTime idt) {
|
void Application::onSimulation(RealTime rdt, SimTime sdt, SimTime idt) {
|
||||||
|
|
||||||
if(_dataModel->isRunning())
|
|
||||||
{
|
|
||||||
// XplicitNgine Start
|
|
||||||
std::vector<PartInstance *> toDelete;
|
|
||||||
for(size_t i = 0; i < _dataModel->getWorkspace()->partObjects.size(); i++)
|
|
||||||
{
|
|
||||||
PartInstance* partInstance = _dataModel->getWorkspace()->partObjects[i];
|
|
||||||
if(partInstance->getPosition().y < -255)
|
|
||||||
{
|
|
||||||
toDelete.push_back(partInstance);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
_dataModel->getEngine()->createBody(partInstance);
|
|
||||||
}
|
|
||||||
while(toDelete.size() > 0)
|
|
||||||
{
|
|
||||||
PartInstance * p = toDelete.back();
|
|
||||||
toDelete.pop_back();
|
|
||||||
g_dataModel->getSelectionService()->removeSelected(p);
|
|
||||||
p->setParent(NULL);
|
|
||||||
delete p;
|
|
||||||
}
|
|
||||||
for(int i = 0; i < 6; i++)
|
|
||||||
{
|
|
||||||
_dataModel->getEngine()->step(0.1F);
|
|
||||||
}
|
|
||||||
onLogic();
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
_dataModel->getGuiRoot()->update();
|
_dataModel->getGuiRoot()->update();
|
||||||
|
|
||||||
if(_dataModel->name != _title)
|
if(_dataModel->name != _title)
|
||||||
@@ -369,53 +326,124 @@ void Application::onSimulation(RealTime rdt, SimTime sdt, SimTime idt) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::onUserInput(UserInput* ui) {
|
/*double getOSVersion() {
|
||||||
if(mouseMoveState)
|
OSVERSIONINFO osvi;
|
||||||
{
|
|
||||||
mouseMoveState = false;
|
|
||||||
tool->onMouseMoved(mouse);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
ZeroMemory(&osvi, sizeof(OSVERSIONINFO));
|
||||||
|
osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
|
||||||
|
|
||||||
|
GetVersionEx(&osvi);
|
||||||
|
std::string version = Convert(osvi.dwMajorVersion) + "." + Convert(osvi.dwMinorVersion);
|
||||||
|
return ::atof(version.c_str());
|
||||||
|
}*/
|
||||||
|
/*
|
||||||
|
bool IsHolding(int button)
|
||||||
|
{
|
||||||
|
return (GetKeyState(button) >> 1)>0;
|
||||||
|
}
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
void Application::onUserInput(UserInput* ui) {
|
||||||
|
|
||||||
|
/*
|
||||||
|
if(GetHoldKeyState(VK_LCONTROL))
|
||||||
|
{
|
||||||
|
if(GetHoldKeyState('D'))
|
||||||
|
{
|
||||||
|
_messageTime = System::time();
|
||||||
|
if(debugMode())
|
||||||
|
_message = "Debug Mode Disabled";
|
||||||
|
else
|
||||||
|
_message = "Debug Mode Enabled";
|
||||||
|
setDebugMode(!debugMode());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
*/
|
||||||
if(GetHoldKeyState(VK_F8))
|
if(GetHoldKeyState(VK_F8))
|
||||||
{
|
{
|
||||||
_dataModel->getGuiRoot()->setDebugMessage("FOV Set to 10", System::time());
|
_dataModel->getGuiRoot()->setDebugMessage("FOV Set to 10", System::time());
|
||||||
}
|
}
|
||||||
|
//}
|
||||||
|
|
||||||
mouse.setMouseDown((GetKeyState(VK_LBUTTON) & 0x100) != 0);
|
//_dataModel->mousex = ui->getMouseX();
|
||||||
|
//_dataModel->mousey = ui->getMouseY();
|
||||||
|
_dataModel->mouseButton1Down = (GetKeyState(VK_LBUTTON) & 0x100) != 0;
|
||||||
|
|
||||||
// Camera KB Handling
|
if (GetHoldKeyState(VK_LBUTTON)) {
|
||||||
if (GetKPBool(VK_OEM_COMMA)) //Left
|
if (_dragging) {
|
||||||
g_usableApp->cameraController.panLeft();
|
PartInstance* part = NULL;
|
||||||
else if (GetKPBool(VK_OEM_PERIOD)) // Right
|
if(g_selectedInstances.size() > 0)
|
||||||
g_usableApp->cameraController.panRight();
|
part = (PartInstance*) g_selectedInstances.at(0);
|
||||||
else if (GetKPBool(0x49)) // Zoom In (I)
|
Ray dragRay = cameraController.getCamera()->worldRay(_dataModel->mousex, _dataModel->mousey, renderDevice->getViewport());
|
||||||
g_usableApp->cameraController.Zoom(1);
|
std::vector<Instance*> instances = _dataModel->getWorkspace()->getAllChildren();
|
||||||
else if (GetKPBool(0x4F)) // Zoom Out (O)
|
for(size_t i = 0; i < instances.size(); i++)
|
||||||
g_usableApp->cameraController.Zoom(-1);
|
{
|
||||||
|
if(PartInstance* moveTo = dynamic_cast<PartInstance*>(instances.at(i)))
|
||||||
|
{
|
||||||
|
float __time = testRay.intersectionTime(moveTo->getBox());
|
||||||
|
float __nearest=std::numeric_limits<float>::infinity();
|
||||||
|
if (__time != inf())
|
||||||
|
{
|
||||||
|
if (__nearest>__time)
|
||||||
|
{
|
||||||
|
// BROKEN
|
||||||
|
//Vector3 closest = (dragRay.closestPoint(moveTo->getPosition()) * 2);
|
||||||
|
//part->setPosition(closest);
|
||||||
|
//part->setPosition(Vector3(floor(closest.x),part->getPosition().y,floor(closest.z)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Sleep(10);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Camera KB Handling {
|
||||||
|
if (GetKPBool(VK_OEM_COMMA)) //Left
|
||||||
|
g_usableApp->cameraController.panLeft();
|
||||||
|
else if (GetKPBool(VK_OEM_PERIOD)) // Right
|
||||||
|
g_usableApp->cameraController.panRight();
|
||||||
|
else if (GetKPBool(0x49)) // Zoom In (I)
|
||||||
|
g_usableApp->cameraController.Zoom(1);
|
||||||
|
else if (GetKPBool(0x4F)) // Zoom Out (O)
|
||||||
|
g_usableApp->cameraController.Zoom(-1);
|
||||||
|
// }
|
||||||
|
|
||||||
|
//readMouseGUIInput();
|
||||||
|
// Add other key handling here
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::changeTool(Tool * newTool)
|
void Application::makeFlag(Vector3 &vec, RenderDevice* &rd)
|
||||||
{
|
{
|
||||||
tool->onDeselect(mouse);
|
|
||||||
delete tool;
|
Vector3 up = Vector3(vec.x, vec.y+3, vec.z);
|
||||||
if(newTool != NULL)
|
rd->setColor(Color3::blue());
|
||||||
tool = newTool;
|
rd->beforePrimitive();
|
||||||
else
|
|
||||||
tool = new Tool(); //Nulltool
|
glBegin(GL_LINES);
|
||||||
tool->onSelect(mouse);
|
glVertex3f(vec.x, vec.y, vec.z);
|
||||||
|
glVertex3f(up.x, up.y, up.z);
|
||||||
|
glEnd();
|
||||||
|
|
||||||
|
glBegin( GL_TRIANGLES );
|
||||||
|
glVertex3f(up.x, up.y-1, up.z);
|
||||||
|
glVertex3f(up.x, up.y-0.5, up.z-1);
|
||||||
|
glVertex3f(up.x, up.y, up.z);
|
||||||
|
|
||||||
|
glVertex3f(up.x, up.y, up.z);
|
||||||
|
glVertex3f(up.x, up.y-0.5, up.z-1);
|
||||||
|
glVertex3f(up.x, up.y-1, up.z);
|
||||||
|
|
||||||
|
glEnd();
|
||||||
|
rd->afterPrimitive();
|
||||||
|
rd->setColor(Color3::white());
|
||||||
|
//I know how i will approach this now
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::setMode(int mode)
|
void Application::setMode(int mode)
|
||||||
{
|
{
|
||||||
_mode = mode;
|
_mode = mode;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::unSetMode()
|
|
||||||
{
|
|
||||||
_mode = NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
int Application::getMode()
|
int Application::getMode()
|
||||||
{
|
{
|
||||||
return _mode;
|
return _mode;
|
||||||
@@ -424,7 +452,7 @@ int Application::getMode()
|
|||||||
|
|
||||||
void Application::drawOutline(Vector3 from, Vector3 to, RenderDevice* rd, LightingParameters lighting, Vector3 size, Vector3 pos, CoordinateFrame c)
|
void Application::drawOutline(Vector3 from, Vector3 to, RenderDevice* rd, LightingParameters lighting, Vector3 size, Vector3 pos, CoordinateFrame c)
|
||||||
{
|
{
|
||||||
rd->disableLighting();
|
|
||||||
Color3 outline = Color3::cyan();//Color3(0.098F,0.6F,1.0F);
|
Color3 outline = Color3::cyan();//Color3(0.098F,0.6F,1.0F);
|
||||||
float offsetSize = 0.05F;
|
float offsetSize = 0.05F;
|
||||||
//X
|
//X
|
||||||
@@ -446,6 +474,8 @@ void Application::drawOutline(Vector3 from, Vector3 to, RenderDevice* rd, Lighti
|
|||||||
|
|
||||||
if(_mode == ARROWS)
|
if(_mode == ARROWS)
|
||||||
{
|
{
|
||||||
|
rd->setLight(0, NULL);
|
||||||
|
rd->setAmbientLightColor(Color3(1,1,1));
|
||||||
|
|
||||||
AABox box;
|
AABox box;
|
||||||
c.toWorldSpace(Box(from, to)).getBounds(box);
|
c.toWorldSpace(Box(from, to)).getBounds(box);
|
||||||
@@ -466,10 +496,14 @@ void Application::drawOutline(Vector3 from, Vector3 to, RenderDevice* rd, Lighti
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
rd->setAmbientLightColor(lighting.ambient);
|
||||||
|
rd->setLight(0, GLight::directional(lighting.lightDirection, lighting.lightColor));
|
||||||
}
|
}
|
||||||
else if(_mode == RESIZE)
|
else if(_mode == RESIZE)
|
||||||
{
|
{
|
||||||
Color3 sphereColor = outline;
|
Color3 sphereColor = outline;
|
||||||
|
rd->setLight(0, NULL);
|
||||||
|
rd->setAmbientLightColor(Color3(1,1,1));
|
||||||
Vector3 gamepoint = pos;
|
Vector3 gamepoint = pos;
|
||||||
Vector3 camerapoint = rd->getCameraToWorldMatrix().translation;
|
Vector3 camerapoint = rd->getCameraToWorldMatrix().translation;
|
||||||
float distance = pow(pow((double)gamepoint.x - (double)camerapoint.x, 2) + pow((double)gamepoint.y - (double)camerapoint.y, 2) + pow((double)gamepoint.z - (double)camerapoint.z, 2), 0.5);
|
float distance = pow(pow((double)gamepoint.x - (double)camerapoint.x, 2) + pow((double)gamepoint.y - (double)camerapoint.y, 2) + pow((double)gamepoint.z - (double)camerapoint.z, 2), 0.5);
|
||||||
@@ -479,23 +513,25 @@ void Application::drawOutline(Vector3 from, Vector3 to, RenderDevice* rd, Lighti
|
|||||||
float multiplier = distance * 0.025F/2;
|
float multiplier = distance * 0.025F/2;
|
||||||
if(multiplier < 0.25F)
|
if(multiplier < 0.25F)
|
||||||
multiplier = 0.25F;
|
multiplier = 0.25F;
|
||||||
Vector3 position = pos + (c.lookVector()*((size.z)+1));
|
Vector3 position = pos + (c.lookVector()*((size.z/2)+1));
|
||||||
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
||||||
position = pos - (c.lookVector()*((size.z)+1));
|
position = pos - (c.lookVector()*((size.z/2)+1));
|
||||||
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
||||||
|
|
||||||
position = pos + (c.rightVector()*((size.x)+1));
|
position = pos + (c.rightVector()*((size.x/2)+1));
|
||||||
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
||||||
position = pos - (c.rightVector()*((size.x)+1));
|
position = pos - (c.rightVector()*((size.x/2)+1));
|
||||||
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
||||||
|
|
||||||
position = pos + (c.upVector()*((size.y)+1));
|
position = pos + (c.upVector()*((size.y/2)+1));
|
||||||
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
||||||
position = pos - (c.upVector()*((size.y)+1));
|
position = pos - (c.upVector()*((size.y/2)+1));
|
||||||
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
Draw::sphere(Sphere(position, multiplier), rd, sphereColor, Color4::clear());
|
||||||
}
|
}
|
||||||
|
rd->setAmbientLightColor(lighting.ambient);
|
||||||
|
rd->setLight(0, GLight::directional(lighting.lightDirection, lighting.lightColor));
|
||||||
}
|
}
|
||||||
rd->enableLighting();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::exitApplication()
|
void Application::exitApplication()
|
||||||
@@ -505,8 +541,6 @@ void Application::exitApplication()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void Application::onGraphics(RenderDevice* rd) {
|
void Application::onGraphics(RenderDevice* rd) {
|
||||||
|
|
||||||
G3D::uint8 num = 0;
|
G3D::uint8 num = 0;
|
||||||
@@ -524,14 +558,14 @@ void Application::onGraphics(RenderDevice* rd) {
|
|||||||
{
|
{
|
||||||
mouseOnScreen = false;
|
mouseOnScreen = false;
|
||||||
//ShowCursor(true);
|
//ShowCursor(true);
|
||||||
//_window->setMouseVisible(true);
|
_window->setMouseVisible(true);
|
||||||
//rd->window()->setInputCaptureCount(0);
|
//rd->window()->setInputCaptureCount(0);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
mouseOnScreen = true;
|
mouseOnScreen = true;
|
||||||
//SetCursor(NULL);
|
//SetCursor(NULL);
|
||||||
//_window->setMouseVisible(false);
|
_window->setMouseVisible(false);
|
||||||
//rd->window()->setInputCaptureCount(1);
|
//rd->window()->setInputCaptureCount(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -544,8 +578,7 @@ void Application::onGraphics(RenderDevice* rd) {
|
|||||||
ScreenToClient(_hWndMain, &mousepos);
|
ScreenToClient(_hWndMain, &mousepos);
|
||||||
}
|
}
|
||||||
|
|
||||||
LightingParameters lighting(G3D::toSeconds(2, 00, 00, PM));
|
LightingParameters lighting(G3D::toSeconds(11, 00, 00, AM));
|
||||||
lighting.ambient = Color3(0.6F,0.6F,0.6F);
|
|
||||||
renderDevice->setProjectionAndCameraMatrix(*cameraController.getCamera());
|
renderDevice->setProjectionAndCameraMatrix(*cameraController.getCamera());
|
||||||
|
|
||||||
// Cyan background
|
// Cyan background
|
||||||
@@ -562,52 +595,40 @@ void Application::onGraphics(RenderDevice* rd) {
|
|||||||
renderDevice->setShadeMode(RenderDevice::SHADE_SMOOTH);
|
renderDevice->setShadeMode(RenderDevice::SHADE_SMOOTH);
|
||||||
renderDevice->setAmbientLightColor(Color3(1,1,1));
|
renderDevice->setAmbientLightColor(Color3(1,1,1));
|
||||||
|
|
||||||
renderDevice->setLight(0, GLight::directional(lighting.lightDirection, lighting.lightColor, true, true));
|
renderDevice->setLight(0, GLight::directional(lighting.lightDirection, lighting.lightColor));
|
||||||
renderDevice->setAmbientLightColor(lighting.ambient);
|
renderDevice->setAmbientLightColor(lighting.ambient);
|
||||||
|
|
||||||
//renderDevice->setBlendFunc(RenderDevice::BLEND_ONE, RenderDevice::BLEND_ONE);
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
renderDevice->setShininess(70);
|
|
||||||
renderDevice->setSpecularCoefficient(Color3(0.1F, 0.1F, 0.1F));
|
|
||||||
|
|
||||||
//float lightAmbient[] = { 0.5F, 0.6F, 0.9F, 1.0F };
|
|
||||||
//float lightDiffuse[] = { 0.6F, 0.4F, 0.9F, 1.0F };
|
|
||||||
//float lightSpecular[] = { 0.8F, 0.6F, 1.0F, 1.0F };
|
|
||||||
|
|
||||||
//glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, lightAmbient);
|
|
||||||
//glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, lightDiffuse);
|
|
||||||
//glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, lightSpecular);
|
|
||||||
//glMateriali(GL_FRONT_AND_BACK, GL_SHININESS, 70);
|
|
||||||
|
|
||||||
|
|
||||||
rd->beforePrimitive();
|
rd->beforePrimitive();
|
||||||
CoordinateFrame forDraw = rd->getObjectToWorldMatrix();
|
CoordinateFrame forDraw = rd->getObjectToWorldMatrix();
|
||||||
glEnableClientState(GL_VERTEX_ARRAY);
|
glEnableClientState(GL_VERTEX_ARRAY);
|
||||||
glEnableClientState(GL_COLOR_ARRAY);
|
glEnableClientState(GL_COLOR_ARRAY);
|
||||||
glEnableClientState(GL_NORMAL_ARRAY);
|
glEnableClientState(GL_NORMAL_ARRAY);
|
||||||
//if(_dataModel->getWorkspace() != NULL)
|
|
||||||
|
|
||||||
_dataModel->getWorkspace()->render(rd);
|
|
||||||
//else throw std::exception("Workspace not found");
|
|
||||||
|
|
||||||
|
for (unsigned int i = 0; i < _dataModel->getWorkspace()->__pvVector.size(); i++)
|
||||||
|
{
|
||||||
|
_dataModel->getWorkspace()->__pvVector[i]->render(rd);
|
||||||
|
}
|
||||||
|
//_dataModel->getWorkspace()->render(rd);
|
||||||
glDisableClientState(GL_VERTEX_ARRAY);
|
glDisableClientState(GL_VERTEX_ARRAY);
|
||||||
glDisableClientState(GL_COLOR_ARRAY);
|
glDisableClientState(GL_COLOR_ARRAY);
|
||||||
glDisableClientState(GL_NORMAL_ARRAY);
|
glDisableClientState(GL_NORMAL_ARRAY);
|
||||||
rd->setObjectToWorldMatrix(forDraw);
|
rd->setObjectToWorldMatrix(forDraw);
|
||||||
rd->afterPrimitive();
|
rd->afterPrimitive();
|
||||||
|
|
||||||
|
if(g_selectedInstances.size() > 0)
|
||||||
//Draw::box(G3D::Box(mouse.getPosition()-Vector3(2,0.5F,1),mouse.getPosition()+Vector3(2,0.5F,1)), rd, Color3::cyan(), Color4::clear());
|
|
||||||
|
|
||||||
for(size_t i = 0; i < _dataModel->getSelectionService()->getSelection().size(); i++)
|
|
||||||
{
|
{
|
||||||
if(PartInstance* part = dynamic_cast<PartInstance*>(g_dataModel->getSelectionService()->getSelection()[i]))
|
for(size_t i = 0; i < g_selectedInstances.size(); i++)
|
||||||
{
|
{
|
||||||
Vector3 size = part->getSize();
|
if(PartInstance* part = dynamic_cast<PartInstance*>(g_selectedInstances.at(i)))
|
||||||
Vector3 pos = part->getPosition();
|
{
|
||||||
drawOutline(Vector3(0+size.x/2, 0+size.y/2, 0+size.z/2) ,Vector3(0-size.x/2,0-size.y/2,0-size.z/2), rd, lighting, Vector3(size.x/2, size.y/2, size.z/2), Vector3(pos.x, pos.y, pos.z), part->getCFrame());
|
Vector3 size = part->getSize();
|
||||||
}
|
Vector3 pos = part->getPosition();
|
||||||
|
drawOutline(Vector3(0+size.x/2, 0+size.y/2, 0+size.z/2) ,Vector3(0-size.x/2,0-size.y/2,0-size.z/2), rd, lighting, Vector3(size.x/2, size.y/2, size.z/2), Vector3(pos.x, pos.y, pos.z), part->getCFrameRenderBased());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -629,7 +650,7 @@ void Application::onGraphics(RenderDevice* rd) {
|
|||||||
}
|
}
|
||||||
renderDevice->push2D();
|
renderDevice->push2D();
|
||||||
_dataModel->getGuiRoot()->renderGUI(renderDevice, m_graphicsWatch.FPS());
|
_dataModel->getGuiRoot()->renderGUI(renderDevice, m_graphicsWatch.FPS());
|
||||||
/*rd->pushState();
|
rd->pushState();
|
||||||
rd->beforePrimitive();
|
rd->beforePrimitive();
|
||||||
|
|
||||||
if(Globals::showMouse && mouseOnScreen)
|
if(Globals::showMouse && mouseOnScreen)
|
||||||
@@ -637,7 +658,7 @@ void Application::onGraphics(RenderDevice* rd) {
|
|||||||
glEnable( GL_TEXTURE_2D );
|
glEnable( GL_TEXTURE_2D );
|
||||||
glEnable(GL_BLEND);// you enable blending function
|
glEnable(GL_BLEND);// you enable blending function
|
||||||
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
||||||
/*
|
|
||||||
std::vector<Instance*> instances = _dataModel->getWorkspace()->getAllChildren();
|
std::vector<Instance*> instances = _dataModel->getWorkspace()->getAllChildren();
|
||||||
currentcursorid = cursorid;
|
currentcursorid = cursorid;
|
||||||
for(size_t i = 0; i < instances.size(); i++)
|
for(size_t i = 0; i < instances.size(); i++)
|
||||||
@@ -654,8 +675,8 @@ void Application::onGraphics(RenderDevice* rd) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
/*glBindTexture( GL_TEXTURE_2D, tool->getCursorId());
|
glBindTexture( GL_TEXTURE_2D, currentcursorid);
|
||||||
|
|
||||||
|
|
||||||
glBegin( GL_QUADS );
|
glBegin( GL_QUADS );
|
||||||
@@ -669,11 +690,11 @@ void Application::onGraphics(RenderDevice* rd) {
|
|||||||
glVertex2f( mousepos.x-64, mousepos.y+64 );
|
glVertex2f( mousepos.x-64, mousepos.y+64 );
|
||||||
glEnd();
|
glEnd();
|
||||||
|
|
||||||
glDisable( GL_TEXTURE_2D );*/
|
glDisable( GL_TEXTURE_2D );
|
||||||
//}
|
}
|
||||||
|
|
||||||
/*rd->afterPrimitive();
|
rd->afterPrimitive();
|
||||||
rd->popState();*/
|
rd->popState();
|
||||||
renderDevice->pop2D();
|
renderDevice->pop2D();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -683,28 +704,85 @@ void Application::onKeyPressed(int key)
|
|||||||
{
|
{
|
||||||
deleteInstance();
|
deleteInstance();
|
||||||
}
|
}
|
||||||
if ((GetHoldKeyState(VK_LCONTROL) || GetHoldKeyState(VK_RCONTROL)) && key=='O')
|
if (GetHoldKeyState(VK_RCONTROL))
|
||||||
{
|
{
|
||||||
|
if (key=='O')
|
||||||
|
{
|
||||||
_dataModel->getOpen();
|
_dataModel->getOpen();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
tool->onKeyDown(key);
|
|
||||||
}
|
}
|
||||||
void Application::onKeyUp(int key)
|
void Application::onKeyUp(int key)
|
||||||
{
|
{
|
||||||
tool->onKeyUp(key);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::onMouseLeftPressed(HWND hwnd,int x,int y)
|
void Application::onMouseLeftPressed(HWND hwnd,int x,int y)
|
||||||
{
|
{
|
||||||
|
//Removed set focus
|
||||||
|
|
||||||
|
|
||||||
|
std::cout << "Click: " << x << "," << y << std::endl;
|
||||||
|
|
||||||
bool onGUI = _dataModel->getGuiRoot()->mouseInGUI(renderDevice, x, y);
|
bool onGUI = _dataModel->getGuiRoot()->mouseInGUI(renderDevice, x, y);
|
||||||
|
|
||||||
|
|
||||||
if(!onGUI)
|
if(!onGUI)
|
||||||
{
|
{
|
||||||
tool->onButton1MouseDown(mouse);
|
testRay = cameraController.getCamera()->worldRay(_dataModel->mousex, _dataModel->mousey, renderDevice->getViewport());
|
||||||
|
float nearest=std::numeric_limits<float>::infinity();
|
||||||
|
Vector3 camPos = cameraController.getCamera()->getCoordinateFrame().translation;
|
||||||
|
std::vector<Instance*> instances = _dataModel->getWorkspace()->getAllChildren();
|
||||||
|
bool objFound = false;
|
||||||
|
for(size_t i = 0; i < instances.size(); i++)
|
||||||
|
{
|
||||||
|
if(PartInstance* test = dynamic_cast<PartInstance*>(instances.at(i)))
|
||||||
|
{
|
||||||
|
float time = testRay.intersectionTime(test->getBox());
|
||||||
|
|
||||||
|
if (time != inf())
|
||||||
|
{
|
||||||
|
objFound = true;
|
||||||
|
if (nearest>time)
|
||||||
|
{
|
||||||
|
nearest=time;
|
||||||
|
bool found = false;
|
||||||
|
for(size_t i = 0; i < g_selectedInstances.size(); i++)
|
||||||
|
{
|
||||||
|
if(g_selectedInstances.at(i) == test)
|
||||||
|
{
|
||||||
|
found = true;
|
||||||
|
//ShowWindow(_propWindow->_hwndProp, SW_SHOW);
|
||||||
|
//SetActiveWindow(_propWindow->_hwndProp);
|
||||||
|
//SetForegroundWindow(_propWindow->_hwndProp);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(!found)
|
||||||
|
{
|
||||||
|
g_selectedInstances.clear();
|
||||||
|
g_selectedInstances.push_back(test);
|
||||||
|
}
|
||||||
|
selectInstance(test, _propWindow);
|
||||||
|
//_message = "Dragging = true.";
|
||||||
|
//_messageTime = System::time();
|
||||||
|
//_dragging = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(!objFound)
|
||||||
|
selectInstance(_dataModel,_propWindow);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Application::selectInstance(Instance* selectedInstance, PropertyWindow* propWindow)
|
||||||
|
{
|
||||||
|
g_selectedInstances.clear();
|
||||||
|
g_selectedInstances.push_back(selectedInstance);
|
||||||
|
propWindow->UpdateSelected(selectedInstance);
|
||||||
|
|
||||||
|
}
|
||||||
G3D::RenderDevice* Application::getRenderDevice()
|
G3D::RenderDevice* Application::getRenderDevice()
|
||||||
{
|
{
|
||||||
return renderDevice;
|
return renderDevice;
|
||||||
@@ -712,28 +790,25 @@ G3D::RenderDevice* Application::getRenderDevice()
|
|||||||
|
|
||||||
void Application::onMouseLeftUp(G3D::RenderDevice* renderDevice, int x, int y)
|
void Application::onMouseLeftUp(G3D::RenderDevice* renderDevice, int x, int y)
|
||||||
{
|
{
|
||||||
|
//std::cout << "Release: " << x << "," << y << std::endl;
|
||||||
_dataModel->getGuiRoot()->onMouseLeftUp(renderDevice, x, y);
|
_dataModel->getGuiRoot()->onMouseLeftUp(renderDevice, x, y);
|
||||||
_dragging = false;
|
_dragging = false;
|
||||||
tool->onButton1MouseUp(mouse);
|
//_message = "Dragging = false.";
|
||||||
|
//_messageTime = System::time();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::onMouseRightPressed(int x,int y)
|
void Application::onMouseRightPressed(int x,int y)
|
||||||
{
|
{
|
||||||
tool->onButton2MouseDown(mouse);
|
|
||||||
}
|
}
|
||||||
void Application::onMouseRightUp(int x,int y)
|
void Application::onMouseRightUp(int x,int y)
|
||||||
{
|
{
|
||||||
tool->onButton2MouseUp(mouse);
|
|
||||||
}
|
}
|
||||||
void Application::onMouseMoved(int x,int y)
|
void Application::onMouseMoved(int x,int y)
|
||||||
{
|
{
|
||||||
oldMouse = Vector2(mouse.x, mouse.y);
|
oldMouse = _dataModel->getMousePos();
|
||||||
mouse.oldx = mouse.x;
|
_dataModel->mousex = x;
|
||||||
mouse.oldy = mouse.y;
|
_dataModel->mousey = y;
|
||||||
mouse.x = x;
|
|
||||||
mouse.y = y;
|
|
||||||
//tool->onMouseMoved(mouse);
|
|
||||||
mouseMoveState = true;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
void Application::onMouseWheel(int x,int y,short delta)
|
void Application::onMouseWheel(int x,int y,short delta)
|
||||||
@@ -743,7 +818,6 @@ void Application::onMouseWheel(int x,int y,short delta)
|
|||||||
{
|
{
|
||||||
AudioPlayer::playSound(cameraSound);
|
AudioPlayer::playSound(cameraSound);
|
||||||
}
|
}
|
||||||
tool->onMouseScroll(mouse);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::run() {
|
void Application::run() {
|
||||||
@@ -767,16 +841,20 @@ void Application::run() {
|
|||||||
UpdateWindow(_hWndMain);
|
UpdateWindow(_hWndMain);
|
||||||
|
|
||||||
// Load objects here=
|
// Load objects here=
|
||||||
|
cursor = Texture::fromFile(GetFileInPath("/content/images/ArrowCursor.png"));
|
||||||
|
cursorOvr = Texture::fromFile(GetFileInPath("/content/images/DragCursor.png"));
|
||||||
Globals::surface = Texture::fromFile(GetFileInPath("/content/images/surfacebr.png"));
|
Globals::surface = Texture::fromFile(GetFileInPath("/content/images/surfacebr.png"));
|
||||||
Globals::surfaceId = Globals::surface->getOpenGLID();
|
Globals::surfaceId = Globals::surface->getOpenGLID();
|
||||||
cameraSound = GetFileInPath("/content/sounds/SWITCH3.wav");
|
cameraSound = GetFileInPath("/content/sounds/SWITCH3.wav");
|
||||||
clickSound = GetFileInPath("/content/sounds/switch.wav");
|
clickSound = GetFileInPath("/content/sounds/switch.wav");
|
||||||
dingSound = GetFileInPath("/content/sounds/electronicpingshort.wav");
|
dingSound = GetFileInPath("/content/sounds/electronicpingshort.wav");
|
||||||
sky = Sky::create(NULL, ExePath() + "/content/sky/");
|
sky = Sky::create(NULL, ExePath() + "/content/sky/");
|
||||||
|
cursorid = cursor->openGLID();
|
||||||
|
currentcursorid = cursorid;
|
||||||
|
cursorOvrid = cursorOvr->openGLID();
|
||||||
RealTime now=0, lastTime=0;
|
RealTime now=0, lastTime=0;
|
||||||
double simTimeRate = 1.0f;
|
double simTimeRate = 1.0f;
|
||||||
float fps=30.0f;
|
float fps=3000.0f;
|
||||||
|
|
||||||
RealTime desiredFrameDuration=1.0/fps;
|
RealTime desiredFrameDuration=1.0/fps;
|
||||||
onInit();
|
onInit();
|
||||||
@@ -790,7 +868,7 @@ void Application::run() {
|
|||||||
//renderDevice->setViewport(viewportRect);
|
//renderDevice->setViewport(viewportRect);
|
||||||
//window()->setInputCaptureCount(1);
|
//window()->setInputCaptureCount(1);
|
||||||
resizeWithParent(_hWndMain);
|
resizeWithParent(_hWndMain);
|
||||||
glEnable(GL_CULL_FACE);
|
|
||||||
while (!quit)
|
while (!quit)
|
||||||
{
|
{
|
||||||
|
|
||||||
@@ -812,8 +890,6 @@ void Application::run() {
|
|||||||
RealTime rdt = timeStep;
|
RealTime rdt = timeStep;
|
||||||
SimTime sdt = timeStep * rate;
|
SimTime sdt = timeStep * rate;
|
||||||
SimTime idt = desiredFrameDuration * rate;
|
SimTime idt = desiredFrameDuration * rate;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
onSimulation(rdt,sdt,idt);
|
onSimulation(rdt,sdt,idt);
|
||||||
m_simulationWatch.tock();
|
m_simulationWatch.tock();
|
||||||
@@ -1,12 +1,9 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include <G3DAll.h>
|
#include <G3DAll.h>
|
||||||
#include "PropertyWindow.h"
|
#include "PropertyWindow.h"
|
||||||
#include "DataModelV2/TextButtonInstance.h"
|
#include "TextButtonInstance.h"
|
||||||
#include "DataModelV2/ImageButtonInstance.h"
|
#include "ImageButtonInstance.h"
|
||||||
#include "CameraController.h"
|
#include "CameraController.h"
|
||||||
#include "IEBrowser.h"
|
|
||||||
#include "Mouse.h"
|
|
||||||
#include "Tool/Tool.h"
|
|
||||||
//#include "GuiRoot.h"
|
//#include "GuiRoot.h"
|
||||||
|
|
||||||
class TextButtonInstance;
|
class TextButtonInstance;
|
||||||
@@ -28,10 +25,11 @@ class Application { // : public GApp {
|
|||||||
virtual void onUserInput(UserInput* ui);
|
virtual void onUserInput(UserInput* ui);
|
||||||
virtual void onCleanup();
|
virtual void onCleanup();
|
||||||
void clearInstances();
|
void clearInstances();
|
||||||
void navigateToolbox(std::string);
|
|
||||||
PartInstance* makePart();
|
PartInstance* makePart();
|
||||||
void drawButtons(RenderDevice* rd);
|
void drawButtons(RenderDevice* rd);
|
||||||
void drawOutline(Vector3 from, Vector3 to, RenderDevice* rd, LightingParameters lighting, Vector3 size, Vector3 pos, CoordinateFrame c);
|
void drawOutline(Vector3 from, Vector3 to, RenderDevice* rd, LightingParameters lighting, Vector3 size, Vector3 pos, CoordinateFrame c);
|
||||||
|
void makeFlag(Vector3 &vec, RenderDevice* &rd);
|
||||||
|
std::vector<Instance*> getSelection();
|
||||||
void deleteInstance();
|
void deleteInstance();
|
||||||
void run();
|
void run();
|
||||||
void QuitApp();
|
void QuitApp();
|
||||||
@@ -47,7 +45,6 @@ class Application { // : public GApp {
|
|||||||
void onMouseWheel(int x, int y, short delta);
|
void onMouseWheel(int x, int y, short delta);
|
||||||
void setFocus(bool isFocused);
|
void setFocus(bool isFocused);
|
||||||
int getMode();
|
int getMode();
|
||||||
void unSetMode();
|
|
||||||
CameraController cameraController;
|
CameraController cameraController;
|
||||||
UserInput* userInput;
|
UserInput* userInput;
|
||||||
PropertyWindow* _propWindow;
|
PropertyWindow* _propWindow;
|
||||||
@@ -55,13 +52,7 @@ class Application { // : public GApp {
|
|||||||
RenderDevice* getRenderDevice();
|
RenderDevice* getRenderDevice();
|
||||||
void selectInstance(Instance* selectedInstance,PropertyWindow* propWindow);
|
void selectInstance(Instance* selectedInstance,PropertyWindow* propWindow);
|
||||||
void setMode(int mode);
|
void setMode(int mode);
|
||||||
|
|
||||||
Tool * tool;
|
|
||||||
void changeTool(Tool *);
|
|
||||||
Mouse mouse;
|
|
||||||
bool viewportHasFocus();
|
|
||||||
private:
|
private:
|
||||||
bool mouseMoveState;
|
|
||||||
RenderDevice* renderDevice;
|
RenderDevice* renderDevice;
|
||||||
//void initGUI();
|
//void initGUI();
|
||||||
HWND _hWndMain;
|
HWND _hWndMain;
|
||||||
@@ -81,7 +72,6 @@ class Application { // : public GApp {
|
|||||||
int _mode;
|
int _mode;
|
||||||
GAppSettings _settings;
|
GAppSettings _settings;
|
||||||
double lightProjX, lightProjY, lightProjNear, lightProjFar;
|
double lightProjX, lightProjY, lightProjNear, lightProjFar;
|
||||||
IEBrowser* webBrowser;
|
|
||||||
protected:
|
protected:
|
||||||
Stopwatch m_graphicsWatch;
|
Stopwatch m_graphicsWatch;
|
||||||
Stopwatch m_logicWatch;
|
Stopwatch m_logicWatch;
|
||||||
BIN
B3dIcon.ico
|
Before Width: | Height: | Size: 108 KiB |
@@ -1,6 +1,5 @@
|
|||||||
#include "DataModelV2/BaseButtonInstance.h"
|
#include "BaseButtonInstance.h"
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include "Application.h"
|
|
||||||
|
|
||||||
|
|
||||||
ButtonListener* listener = NULL;
|
ButtonListener* listener = NULL;
|
||||||
@@ -14,18 +13,19 @@ BaseButtonInstance::BaseButtonInstance(void)
|
|||||||
void BaseButtonInstance::render(RenderDevice* rd)
|
void BaseButtonInstance::render(RenderDevice* rd)
|
||||||
{
|
{
|
||||||
DataModelInstance* dataModel = g_dataModel;
|
DataModelInstance* dataModel = g_dataModel;
|
||||||
Vector2 pos = Vector2(g_usableApp->mouse.x,g_usableApp->mouse.y);
|
Vector2 pos = Vector2(dataModel->mousex,dataModel->mousey);
|
||||||
drawObj(rd, pos, g_usableApp->mouse.isMouseDown());
|
drawObj(rd, pos, dataModel->mouseButton1Down);
|
||||||
Instance::render(rd);
|
Instance::render(rd);
|
||||||
}
|
}
|
||||||
|
|
||||||
BaseButtonInstance::~BaseButtonInstance(void)
|
BaseButtonInstance::~BaseButtonInstance(void)
|
||||||
{
|
{
|
||||||
|
delete listener;
|
||||||
}
|
}
|
||||||
|
|
||||||
void BaseButtonInstance::setButtonListener(ButtonListener& buttonListener)
|
void BaseButtonInstance::setButtonListener(ButtonListener* buttonListener)
|
||||||
{
|
{
|
||||||
listener = &buttonListener;
|
listener = buttonListener;
|
||||||
}
|
}
|
||||||
|
|
||||||
void BaseButtonInstance::drawObj(RenderDevice* rd, Vector2 mousePos, bool mouseDown){}
|
void BaseButtonInstance::drawObj(RenderDevice* rd, Vector2 mousePos, bool mouseDown){}
|
||||||
@@ -37,6 +37,7 @@ void BaseButtonInstance::onMouseClick()
|
|||||||
if(listener != NULL)
|
if(listener != NULL)
|
||||||
{
|
{
|
||||||
listener->onButton1MouseClick(this);
|
listener->onButton1MouseClick(this);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "Instance.h"
|
#include "instance.h"
|
||||||
#include "Listener/ButtonListener.h"
|
#include "ButtonListener.h"
|
||||||
|
|
||||||
class ButtonListener;
|
class ButtonListener;
|
||||||
class Instance;
|
class Instance;
|
||||||
@@ -14,7 +14,7 @@ public:
|
|||||||
virtual void drawObj(RenderDevice* rd, Vector2 mousePos, bool mouseDown);
|
virtual void drawObj(RenderDevice* rd, Vector2 mousePos, bool mouseDown);
|
||||||
virtual bool mouseInButton(float, float, RenderDevice* rd);
|
virtual bool mouseInButton(float, float, RenderDevice* rd);
|
||||||
virtual void onMouseClick();
|
virtual void onMouseClick();
|
||||||
void setButtonListener(ButtonListener&);
|
void setButtonListener(ButtonListener*);
|
||||||
bool floatBottom;
|
bool floatBottom;
|
||||||
bool floatRight;
|
bool floatRight;
|
||||||
bool floatCenter;
|
bool floatCenter;
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
||||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
|
|
||||||
<assemblyIdentity
|
|
||||||
version="0.0.106.2"
|
|
||||||
processorArchitecture="*"
|
|
||||||
name="Blocks3D.Blocks3D.Blocks3D"
|
|
||||||
type="win32"
|
|
||||||
/>
|
|
||||||
<dependency>
|
|
||||||
<dependentAssembly>
|
|
||||||
<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*"/>
|
|
||||||
</dependentAssembly>
|
|
||||||
</dependency>
|
|
||||||
</assembly>
|
|
||||||
20
Blocks3D.sln
@@ -1,20 +0,0 @@
|
|||||||
|
|
||||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
|
||||||
# Visual C++ Express 2005
|
|
||||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Blocks3D", "Blocks3D.vcproj", "{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}"
|
|
||||||
EndProject
|
|
||||||
Global
|
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
|
||||||
Debug|Win32 = Debug|Win32
|
|
||||||
Release|Win32 = Release|Win32
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
|
||||||
{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}.Debug|Win32.ActiveCfg = Debug|Win32
|
|
||||||
{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}.Debug|Win32.Build.0 = Debug|Win32
|
|
||||||
{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}.Release|Win32.ActiveCfg = Release|Win32
|
|
||||||
{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}.Release|Win32.Build.0 = Release|Win32
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
|
||||||
HideSolutionNode = FALSE
|
|
||||||
EndGlobalSection
|
|
||||||
EndGlobal
|
|
||||||
945
Blocks3D.vcproj
@@ -1,945 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="Windows-1252"?>
|
|
||||||
<VisualStudioProject
|
|
||||||
ProjectType="Visual C++"
|
|
||||||
Version="8.00"
|
|
||||||
Name="Blocks3D"
|
|
||||||
ProjectGUID="{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}"
|
|
||||||
RootNamespace="Blocks3D"
|
|
||||||
>
|
|
||||||
<Platforms>
|
|
||||||
<Platform
|
|
||||||
Name="Win32"
|
|
||||||
/>
|
|
||||||
</Platforms>
|
|
||||||
<ToolFiles>
|
|
||||||
</ToolFiles>
|
|
||||||
<Configurations>
|
|
||||||
<Configuration
|
|
||||||
Name="Release|Win32"
|
|
||||||
OutputDirectory=".\Release"
|
|
||||||
IntermediateDirectory=".\Release"
|
|
||||||
ConfigurationType="1"
|
|
||||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
|
|
||||||
UseOfMFC="0"
|
|
||||||
UseOfATL="0"
|
|
||||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
|
||||||
CharacterSet="2"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreBuildEventTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCCustomBuildTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCXMLDataGeneratorTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebServiceProxyGeneratorTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCMIDLTool"
|
|
||||||
PreprocessorDefinitions="NDEBUG"
|
|
||||||
MkTypLibCompatible="true"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
TargetEnvironment="1"
|
|
||||||
TypeLibraryName=".\Release/Blocks3D.tlb"
|
|
||||||
HeaderFileName=""
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
Optimization="2"
|
|
||||||
InlineFunctionExpansion="1"
|
|
||||||
AdditionalIncludeDirectories="".\src\include""
|
|
||||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS"
|
|
||||||
StringPooling="true"
|
|
||||||
RuntimeLibrary="2"
|
|
||||||
EnableFunctionLevelLinking="true"
|
|
||||||
PrecompiledHeaderFile=".\Release/Blocks3D.pch"
|
|
||||||
AssemblerListingLocation=".\Release/"
|
|
||||||
ObjectFile=".\Release/"
|
|
||||||
ProgramDataBaseFileName=".\Release/"
|
|
||||||
WarningLevel="3"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCManagedResourceCompilerTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCResourceCompilerTool"
|
|
||||||
PreprocessorDefinitions="NDEBUG"
|
|
||||||
Culture="4105"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreLinkEventTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCLinkerTool"
|
|
||||||
AdditionalDependencies="Advapi32.lib Comctl32.lib Comdlg32.lib Shell32.lib ode.lib OPCODE.lib Ole32.lib"
|
|
||||||
OutputFile="./Blocks3D.exe"
|
|
||||||
LinkIncremental="1"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
ProgramDatabaseFile=".\Release/Blocks3D.pdb"
|
|
||||||
SubSystem="2"
|
|
||||||
TargetMachine="1"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCALinkTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCManifestTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCXDCMakeTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCBscMakeTool"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
OutputFile=".\Release/Blocks3D.bsc"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCFxCopTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCAppVerifierTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebDeploymentTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPostBuildEventTool"
|
|
||||||
/>
|
|
||||||
</Configuration>
|
|
||||||
<Configuration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
OutputDirectory=".\Debug"
|
|
||||||
IntermediateDirectory=".\Debug"
|
|
||||||
ConfigurationType="1"
|
|
||||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
|
|
||||||
UseOfMFC="0"
|
|
||||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
|
||||||
CharacterSet="2"
|
|
||||||
ManagedExtensions="0"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreBuildEventTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCCustomBuildTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCXMLDataGeneratorTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebServiceProxyGeneratorTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCMIDLTool"
|
|
||||||
PreprocessorDefinitions="_DEBUG"
|
|
||||||
MkTypLibCompatible="true"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
TargetEnvironment="1"
|
|
||||||
TypeLibraryName=".\Debug/Blocks3D.tlb"
|
|
||||||
HeaderFileName=""
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
Optimization="0"
|
|
||||||
AdditionalIncludeDirectories=""C:\libraries\ode-0.5\include\drawstuff";.\src\include"
|
|
||||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS"
|
|
||||||
MinimalRebuild="false"
|
|
||||||
BasicRuntimeChecks="0"
|
|
||||||
RuntimeLibrary="3"
|
|
||||||
EnableFunctionLevelLinking="false"
|
|
||||||
PrecompiledHeaderFile=".\Debug/Blocks3D.pch"
|
|
||||||
AssemblerListingLocation=".\Debug/"
|
|
||||||
ObjectFile=".\Debug/"
|
|
||||||
ProgramDataBaseFileName=".\Debug/"
|
|
||||||
WarningLevel="3"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
DebugInformationFormat="3"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCManagedResourceCompilerTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCResourceCompilerTool"
|
|
||||||
PreprocessorDefinitions="_DEBUG"
|
|
||||||
Culture="4105"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreLinkEventTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCLinkerTool"
|
|
||||||
AdditionalDependencies="Advapi32.lib UxTheme.lib Comctl32.lib Comdlg32.lib Shell32.lib Urlmon.lib ole32.lib oleaut32.lib uuid.lib ode.lib OPCODE.lib"
|
|
||||||
OutputFile="./Blocks3D-Debug.exe"
|
|
||||||
LinkIncremental="2"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
GenerateDebugInformation="true"
|
|
||||||
ProgramDatabaseFile=".\Debug/Blocks3D.pdb"
|
|
||||||
SubSystem="1"
|
|
||||||
TargetMachine="1"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCALinkTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCManifestTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCXDCMakeTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCBscMakeTool"
|
|
||||||
SuppressStartupBanner="true"
|
|
||||||
OutputFile=".\Debug/Blocks3D.bsc"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCFxCopTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCAppVerifierTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebDeploymentTool"
|
|
||||||
/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPostBuildEventTool"
|
|
||||||
/>
|
|
||||||
</Configuration>
|
|
||||||
</Configurations>
|
|
||||||
<References>
|
|
||||||
<AssemblyReference
|
|
||||||
RelativePath="System.dll"
|
|
||||||
AssemblyName="System, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"
|
|
||||||
/>
|
|
||||||
<AssemblyReference
|
|
||||||
RelativePath="System.Data.dll"
|
|
||||||
AssemblyName="System.Data, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=x86"
|
|
||||||
/>
|
|
||||||
<AssemblyReference
|
|
||||||
RelativePath="System.Drawing.dll"
|
|
||||||
AssemblyName="System.Drawing, Version=2.0.0.0, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL"
|
|
||||||
/>
|
|
||||||
<AssemblyReference
|
|
||||||
RelativePath="System.Windows.Forms.dll"
|
|
||||||
AssemblyName="System.Windows.Forms, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"
|
|
||||||
/>
|
|
||||||
<AssemblyReference
|
|
||||||
RelativePath="System.XML.dll"
|
|
||||||
AssemblyName="System.Xml, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"
|
|
||||||
/>
|
|
||||||
</References>
|
|
||||||
<Files>
|
|
||||||
<Filter
|
|
||||||
Name="Source Files"
|
|
||||||
Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Application.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\AudioPlayer.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\ax.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\BrowserCallHandler.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\CameraController.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\ErrorFunctions.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Globals.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\IEBrowser.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\IEDispatcher.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\main.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Mouse.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\propertyGrid.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\PropertyWindow.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Renderer.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\SplashHTML.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\StringFunctions.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\TextureHandler.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\WindowFunctions.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<Filter
|
|
||||||
Name="Tool"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Tool\ArrowTool.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Tool\SurfaceTool.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Tool\Tool.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Listener"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\ButtonListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\CameraButtonListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\DeleteListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\GUDButtonListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\MenuButtonListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\ModeSelectionListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\RotateButtonListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Listener\ToolbarListener.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="DataModelV2"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\DataModelInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\GroupInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\Instance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\LevelInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\PartInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\PVInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModel\SelectionService.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\WorkspaceInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<Filter
|
|
||||||
Name="Gui"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\BaseButtonInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\BaseGuiInstance.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\GuiRootInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\ImageButtonInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\TextButtonInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\DataModelV2\ToggleImageButtonInstance.cpp"
|
|
||||||
>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Release|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
<FileConfiguration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
>
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
|
||||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
|
||||||
/>
|
|
||||||
</FileConfiguration>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="XplicitNgine"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\XplicitNgine\XplicitNgine.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Properties"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Properties\BoolProperty.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\source\Properties\Property.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Header Files"
|
|
||||||
Filter="h;hpp;hxx;hm;inl"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Application.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\AudioPlayer.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\ax.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\BrowserCallHandler.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\CameraController.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Enum.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\ErrorFunctions.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Faces.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Globals.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\IEBrowser.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\IEDispatcher.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Mouse.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\propertyGrid.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\PropertyWindow.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Renderer.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\resource.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\SplashHTML.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\StringFunctions.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\TextureHandler.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\win32Defines.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\WindowFunctions.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<Filter
|
|
||||||
Name="RapidXML"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\rapidxml\rapidxml.hpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\rapidxml\rapidxml_iterators.hpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\rapidxml\rapidxml_print.hpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\rapidxml\rapidxml_utils.hpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Listener"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\ButtonListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\CameraButtonListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\DeleteListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\GUDButtonListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\MenuButtonListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\ModeSelectionListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\RotateButtonListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Listener\ToolbarListener.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModel\WorkspaceInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Tool"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Tool\ArrowTool.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Tool\SurfaceTool.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Tool\Tool.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="DataModelV2"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\DataModelInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\GroupInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\Instance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\LevelInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\PartInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\PVInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\SelectionService.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\WorkspaceInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<Filter
|
|
||||||
Name="Gui"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\BaseButtonInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\BaseGuiInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\GuiRootInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\ImageButtonInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\TextButtonInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\DataModelV2\ToggleImageButtonInstance.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="XplicitNgine"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\XplicitNgine\XplicitNgine.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Properties"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Properties\BoolProperty.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\src\include\Properties\Property.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Resource Files"
|
|
||||||
Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
|
|
||||||
>
|
|
||||||
<File
|
|
||||||
RelativePath=".\Blocks3D.exe.manifest"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\Dialogs.rc"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\icon1.ico"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\Parts.bmp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath=".\roblox_RN1_icon.ico"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
</Files>
|
|
||||||
<Globals>
|
|
||||||
<Global
|
|
||||||
Name="RESOURCE_FILE"
|
|
||||||
Value="Dialogs.rc"
|
|
||||||
/>
|
|
||||||
</Globals>
|
|
||||||
</VisualStudioProject>
|
|
||||||
340
Blocks3D.vcxproj
@@ -1,340 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<Project DefaultTargets="Build" ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
||||||
<ItemGroup Label="ProjectConfigurations">
|
|
||||||
<ProjectConfiguration Include="Debug|Win32">
|
|
||||||
<Configuration>Debug</Configuration>
|
|
||||||
<Platform>Win32</Platform>
|
|
||||||
</ProjectConfiguration>
|
|
||||||
<ProjectConfiguration Include="Release|Win32">
|
|
||||||
<Configuration>Release</Configuration>
|
|
||||||
<Platform>Win32</Platform>
|
|
||||||
</ProjectConfiguration>
|
|
||||||
</ItemGroup>
|
|
||||||
<PropertyGroup Label="Globals">
|
|
||||||
<VCProjectVersion>17.0</VCProjectVersion>
|
|
||||||
<ProjectGuid>{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}</ProjectGuid>
|
|
||||||
<RootNamespace>Blocks3D</RootNamespace>
|
|
||||||
</PropertyGroup>
|
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
|
||||||
<PlatformToolset>v143</PlatformToolset>
|
|
||||||
<UseOfMfc>false</UseOfMfc>
|
|
||||||
<CharacterSet>MultiByte</CharacterSet>
|
|
||||||
<CLRSupport>false</CLRSupport>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
|
||||||
<PlatformToolset>v143</PlatformToolset>
|
|
||||||
<UseOfMfc>false</UseOfMfc>
|
|
||||||
<UseOfAtl>false</UseOfAtl>
|
|
||||||
<CharacterSet>MultiByte</CharacterSet>
|
|
||||||
</PropertyGroup>
|
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
|
||||||
<ImportGroup Label="ExtensionSettings">
|
|
||||||
</ImportGroup>
|
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
|
||||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
||||||
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC60.props" />
|
|
||||||
</ImportGroup>
|
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
|
||||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
||||||
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC60.props" />
|
|
||||||
</ImportGroup>
|
|
||||||
<PropertyGroup Label="UserMacros" />
|
|
||||||
<PropertyGroup>
|
|
||||||
<_ProjectFileVersion>17.0.32505.173</_ProjectFileVersion>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
|
||||||
<OutDir>.\Release\</OutDir>
|
|
||||||
<IntDir>.\Release\</IntDir>
|
|
||||||
<LinkIncremental>false</LinkIncremental>
|
|
||||||
</PropertyGroup>
|
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
|
||||||
<OutDir>.\Debug\</OutDir>
|
|
||||||
<IntDir>.\Debug\</IntDir>
|
|
||||||
<LinkIncremental>true</LinkIncremental>
|
|
||||||
</PropertyGroup>
|
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
|
||||||
<Midl>
|
|
||||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
<TargetEnvironment>Win32</TargetEnvironment>
|
|
||||||
<TypeLibraryName>.\Release/Blocks3D.tlb</TypeLibraryName>
|
|
||||||
<HeaderFileName />
|
|
||||||
</Midl>
|
|
||||||
<ClCompile>
|
|
||||||
<Optimization>MaxSpeed</Optimization>
|
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
|
||||||
<AdditionalIncludeDirectories>.\src\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
|
||||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<StringPooling>true</StringPooling>
|
|
||||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
|
||||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
|
||||||
<PrecompiledHeaderOutputFile>.\Release/Blocks3D.pch</PrecompiledHeaderOutputFile>
|
|
||||||
<AssemblerListingLocation>.\Release/</AssemblerListingLocation>
|
|
||||||
<ObjectFileName>.\Release/</ObjectFileName>
|
|
||||||
<ProgramDataBaseFileName>.\Release/</ProgramDataBaseFileName>
|
|
||||||
<WarningLevel>Level3</WarningLevel>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
</ClCompile>
|
|
||||||
<ResourceCompile>
|
|
||||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<Culture>0x1009</Culture>
|
|
||||||
</ResourceCompile>
|
|
||||||
<Link>
|
|
||||||
<AdditionalDependencies>Advapi32.lib;Comctl32.lib;Comdlg32.lib;Shell32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
||||||
<OutputFile>./Blocks3D.exe</OutputFile>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
<ProgramDatabaseFile>.\Release/Blocks3D.pdb</ProgramDatabaseFile>
|
|
||||||
<SubSystem>Windows</SubSystem>
|
|
||||||
<TargetMachine>MachineX86</TargetMachine>
|
|
||||||
</Link>
|
|
||||||
<Bscmake>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
<OutputFile>.\Release/Blocks3D.bsc</OutputFile>
|
|
||||||
</Bscmake>
|
|
||||||
</ItemDefinitionGroup>
|
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
|
||||||
<Midl>
|
|
||||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
<TargetEnvironment>Win32</TargetEnvironment>
|
|
||||||
<TypeLibraryName>.\Debug/Blocks3D.tlb</TypeLibraryName>
|
|
||||||
<HeaderFileName />
|
|
||||||
</Midl>
|
|
||||||
<ClCompile>
|
|
||||||
<Optimization>Disabled</Optimization>
|
|
||||||
<AdditionalIncludeDirectories>.\src\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
|
||||||
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<MinimalRebuild>false</MinimalRebuild>
|
|
||||||
<BasicRuntimeChecks>Default</BasicRuntimeChecks>
|
|
||||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
|
||||||
<FunctionLevelLinking>false</FunctionLevelLinking>
|
|
||||||
<PrecompiledHeaderOutputFile>.\Debug/Blocks3D.pch</PrecompiledHeaderOutputFile>
|
|
||||||
<AssemblerListingLocation>.\Debug/</AssemblerListingLocation>
|
|
||||||
<ObjectFileName>.\Debug/</ObjectFileName>
|
|
||||||
<ProgramDataBaseFileName>.\Debug/</ProgramDataBaseFileName>
|
|
||||||
<WarningLevel>Level3</WarningLevel>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
|
||||||
</ClCompile>
|
|
||||||
<ResourceCompile>
|
|
||||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
||||||
<Culture>0x1009</Culture>
|
|
||||||
</ResourceCompile>
|
|
||||||
<Link>
|
|
||||||
<AdditionalDependencies>Advapi32.lib;UxTheme.lib;Comctl32.lib;Comdlg32.lib;Shell32.lib;Urlmon.lib;ole32.lib;oleaut32.lib;uuid.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
||||||
<OutputFile>./Blocks3D-Debug.exe</OutputFile>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
|
||||||
<ProgramDatabaseFile>.\Debug/Blocks3D.pdb</ProgramDatabaseFile>
|
|
||||||
<SubSystem>Console</SubSystem>
|
|
||||||
<TargetMachine>MachineX86</TargetMachine>
|
|
||||||
</Link>
|
|
||||||
<Bscmake>
|
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
|
||||||
<OutputFile>.\Debug/Blocks3D.bsc</OutputFile>
|
|
||||||
</Bscmake>
|
|
||||||
</ItemDefinitionGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<Reference Include="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
|
||||||
<CopyLocalSatelliteAssemblies>true</CopyLocalSatelliteAssemblies>
|
|
||||||
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
|
||||||
<CopyLocalSatelliteAssemblies>true</CopyLocalSatelliteAssemblies>
|
|
||||||
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
|
||||||
<CopyLocalSatelliteAssemblies>true</CopyLocalSatelliteAssemblies>
|
|
||||||
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
|
||||||
<CopyLocalSatelliteAssemblies>true</CopyLocalSatelliteAssemblies>
|
|
||||||
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
|
||||||
<CopyLocalSatelliteAssemblies>true</CopyLocalSatelliteAssemblies>
|
|
||||||
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
|
|
||||||
</Reference>
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ClCompile Include="src\source\Application.cpp" />
|
|
||||||
<ClCompile Include="src\source\AudioPlayer.cpp" />
|
|
||||||
<ClCompile Include="src\source\ax.cpp" />
|
|
||||||
<ClCompile Include="src\source\BrowserCallHandler.cpp" />
|
|
||||||
<ClCompile Include="src\source\CameraController.cpp" />
|
|
||||||
<ClCompile Include="src\source\DataModelV2\BaseButtonInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\BaseGuiInstance.cpp" />
|
|
||||||
<ClCompile Include="src\source\DataModelV2\DataModelInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\GroupInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\GuiRootInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\ImageButtonInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\Instance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\LevelInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\PartInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\PVInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\TextButtonInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\ToggleImageButtonInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\WorkspaceInstance.cpp">
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
<ObjectFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.obj</ObjectFileName>
|
|
||||||
<XMLDocumentationFileName Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)%(Filename)1.xdc</XMLDocumentationFileName>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\ErrorFunctions.cpp" />
|
|
||||||
<ClCompile Include="src\source\Globals.cpp" />
|
|
||||||
<ClCompile Include="src\source\IEBrowser.cpp" />
|
|
||||||
<ClCompile Include="src\source\IEDispatcher.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\ButtonListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\CameraButtonListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\DeleteListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\GUDButtonListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\MenuButtonListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\ModeSelectionListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\RotateButtonListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\Listener\ToolbarListener.cpp" />
|
|
||||||
<ClCompile Include="src\source\main.cpp" />
|
|
||||||
<ClCompile Include="src\source\Mouse.cpp" />
|
|
||||||
<ClCompile Include="src\source\Properties\BoolProperty.cpp" />
|
|
||||||
<ClCompile Include="src\source\Properties\Property.cpp" />
|
|
||||||
<ClCompile Include="src\source\propertyGrid.cpp" />
|
|
||||||
<ClCompile Include="src\source\PropertyWindow.cpp" />
|
|
||||||
<ClCompile Include="src\source\Renderer.cpp" />
|
|
||||||
<ClCompile Include="src\source\StringFunctions.cpp" />
|
|
||||||
<ClCompile Include="src\source\TextureHandler.cpp" />
|
|
||||||
<ClCompile Include="src\source\Tool\ArrowTool.cpp" />
|
|
||||||
<ClCompile Include="src\source\Tool\SurfaceTool.cpp" />
|
|
||||||
<ClCompile Include="src\source\Tool\Tool.cpp" />
|
|
||||||
<ClCompile Include="src\source\WindowFunctions.cpp" />
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ClInclude Include="resource.h" />
|
|
||||||
<ClInclude Include="src\include\Application.h" />
|
|
||||||
<ClInclude Include="src\include\AudioPlayer.h" />
|
|
||||||
<ClInclude Include="src\include\ax.h" />
|
|
||||||
<ClInclude Include="src\include\BrowserCallHandler.h" />
|
|
||||||
<ClInclude Include="src\include\CameraController.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\BaseButtonInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\BaseGuiInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\DataModelInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\GroupInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\GuiRootInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\ImageButtonInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\Instance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\LevelInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\PartInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\PVInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\TextButtonInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\ToggleImageButtonInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModelV2\WorkspaceInstance.h" />
|
|
||||||
<ClInclude Include="src\include\DataModel\WorkspaceInstance.h" />
|
|
||||||
<ClInclude Include="src\include\Enum.h" />
|
|
||||||
<ClInclude Include="src\include\ErrorFunctions.h" />
|
|
||||||
<ClInclude Include="src\include\Faces.h" />
|
|
||||||
<ClInclude Include="src\include\Globals.h" />
|
|
||||||
<ClInclude Include="src\include\IEBrowser.h" />
|
|
||||||
<ClInclude Include="src\include\IEDispatcher.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\ButtonListener.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\CameraButtonListener.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\DeleteListener.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\GUDButtonListener.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\MenuButtonListener.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\ModeSelectionListener.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\RotateButtonListener.h" />
|
|
||||||
<ClInclude Include="src\include\Listener\ToolbarListener.h" />
|
|
||||||
<ClInclude Include="src\include\Mouse.h" />
|
|
||||||
<ClInclude Include="src\include\Properties\BoolProperty.h" />
|
|
||||||
<ClInclude Include="src\include\Properties\Property.h" />
|
|
||||||
<ClInclude Include="src\include\propertyGrid.h" />
|
|
||||||
<ClInclude Include="src\include\PropertyWindow.h" />
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml.hpp" />
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml_iterators.hpp" />
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml_print.hpp" />
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml_utils.hpp" />
|
|
||||||
<ClInclude Include="src\include\Renderer.h" />
|
|
||||||
<ClInclude Include="src\include\StringFunctions.h" />
|
|
||||||
<ClInclude Include="src\include\TextureHandler.h" />
|
|
||||||
<ClInclude Include="src\include\Tool\ArrowTool.h" />
|
|
||||||
<ClInclude Include="src\include\Tool\SurfaceTool.h" />
|
|
||||||
<ClInclude Include="src\include\Tool\Tool.h" />
|
|
||||||
<ClInclude Include="src\include\win32Defines.h" />
|
|
||||||
<ClInclude Include="src\include\WindowFunctions.h" />
|
|
||||||
<ClInclude Include="src\include\winver.h" />
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<None Include="B3dIcon.ico" />
|
|
||||||
<None Include="FatB3dIcon.ico" />
|
|
||||||
<None Include="Parts.bmp" />
|
|
||||||
<None Include="roblox_RN1_icon.ico" />
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ResourceCompile Include="Dialogs.rc" />
|
|
||||||
</ItemGroup>
|
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
|
||||||
<ImportGroup Label="ExtensionTargets">
|
|
||||||
</ImportGroup>
|
|
||||||
<ProjectExtensions>
|
|
||||||
<VisualStudio>
|
|
||||||
<UserProperties RESOURCE_FILE="Dialogs.rc" />
|
|
||||||
</VisualStudio>
|
|
||||||
</ProjectExtensions>
|
|
||||||
</Project>
|
|
||||||
@@ -1,358 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
||||||
<ItemGroup>
|
|
||||||
<Filter Include="Source Files">
|
|
||||||
<UniqueIdentifier>{9571c986-a719-4aa9-8f06-edd22511bbbf}</UniqueIdentifier>
|
|
||||||
<Extensions>cpp;c;cxx;rc;def;r;odl;idl;hpj;bat</Extensions>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Source Files\Tool">
|
|
||||||
<UniqueIdentifier>{10225c23-5e14-45ed-aa65-5e2952d83749}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Source Files\Listener">
|
|
||||||
<UniqueIdentifier>{9a362f2a-3ea4-4130-80e1-c7dae14a8862}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Source Files\DataModelV2">
|
|
||||||
<UniqueIdentifier>{018ed0d2-9b98-424f-9af8-172600aa12e3}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Source Files\DataModelV2\Gui">
|
|
||||||
<UniqueIdentifier>{870b4a49-cf43-4f47-8321-f48d7b01816b}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Source Files\Properties">
|
|
||||||
<UniqueIdentifier>{7d5f8016-5447-4c00-b9cd-d2c5bb2e59b8}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files">
|
|
||||||
<UniqueIdentifier>{f959d8b8-bb6a-4c70-ad2c-f1c66758c461}</UniqueIdentifier>
|
|
||||||
<Extensions>h;hpp;hxx;hm;inl</Extensions>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files\RapidXML">
|
|
||||||
<UniqueIdentifier>{6db93330-5b80-4675-8d44-4db372d9d5b5}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files\Listener">
|
|
||||||
<UniqueIdentifier>{8bb34ca3-25fe-465c-a77e-8057005450b0}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files\Tool">
|
|
||||||
<UniqueIdentifier>{b00aefef-dafe-4dc3-8aec-d5a4d56dd2e0}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files\DataModelV2">
|
|
||||||
<UniqueIdentifier>{c13ee511-5b6b-4b79-8402-31323e149b75}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files\DataModelV2\Gui">
|
|
||||||
<UniqueIdentifier>{2414eb84-1360-4601-af93-51eb6639ba14}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Header Files\Properties">
|
|
||||||
<UniqueIdentifier>{1ff12666-0b54-4e78-8a68-43853c4f7f12}</UniqueIdentifier>
|
|
||||||
</Filter>
|
|
||||||
<Filter Include="Resource Files">
|
|
||||||
<UniqueIdentifier>{f27a93e2-d403-4b4e-ac57-4081d78febbc}</UniqueIdentifier>
|
|
||||||
<Extensions>ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe</Extensions>
|
|
||||||
</Filter>
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ClCompile Include="src\source\Application.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\AudioPlayer.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\ax.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\BrowserCallHandler.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\CameraController.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\ErrorFunctions.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Globals.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\IEBrowser.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\IEDispatcher.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\main.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Mouse.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\propertyGrid.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\PropertyWindow.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Renderer.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\StringFunctions.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\TextureHandler.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\WindowFunctions.cpp">
|
|
||||||
<Filter>Source Files</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Tool\ArrowTool.cpp">
|
|
||||||
<Filter>Source Files\Tool</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Tool\SurfaceTool.cpp">
|
|
||||||
<Filter>Source Files\Tool</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Tool\Tool.cpp">
|
|
||||||
<Filter>Source Files\Tool</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\ButtonListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\CameraButtonListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\DeleteListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\GUDButtonListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\MenuButtonListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\ModeSelectionListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\RotateButtonListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Listener\ToolbarListener.cpp">
|
|
||||||
<Filter>Source Files\Listener</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\DataModelInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\GroupInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\Instance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\LevelInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\PartInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\PVInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\WorkspaceInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\BaseButtonInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\BaseGuiInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\GuiRootInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\ImageButtonInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\TextButtonInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\DataModelV2\ToggleImageButtonInstance.cpp">
|
|
||||||
<Filter>Source Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Properties\BoolProperty.cpp">
|
|
||||||
<Filter>Source Files\Properties</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
<ClCompile Include="src\source\Properties\Property.cpp">
|
|
||||||
<Filter>Source Files\Properties</Filter>
|
|
||||||
</ClCompile>
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ClInclude Include="src\include\Application.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\AudioPlayer.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\ax.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\BrowserCallHandler.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\CameraController.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Enum.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\ErrorFunctions.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Faces.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Globals.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\IEBrowser.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\IEDispatcher.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Mouse.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\propertyGrid.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\PropertyWindow.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Renderer.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="resource.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\StringFunctions.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\TextureHandler.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\win32Defines.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\WindowFunctions.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\winver.h">
|
|
||||||
<Filter>Header Files</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml.hpp">
|
|
||||||
<Filter>Header Files\RapidXML</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml_iterators.hpp">
|
|
||||||
<Filter>Header Files\RapidXML</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml_print.hpp">
|
|
||||||
<Filter>Header Files\RapidXML</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\rapidxml\rapidxml_utils.hpp">
|
|
||||||
<Filter>Header Files\RapidXML</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\ButtonListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\CameraButtonListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\DeleteListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\GUDButtonListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\MenuButtonListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\ModeSelectionListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\RotateButtonListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Listener\ToolbarListener.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModel\WorkspaceInstance.h">
|
|
||||||
<Filter>Header Files\Listener</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Tool\ArrowTool.h">
|
|
||||||
<Filter>Header Files\Tool</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Tool\SurfaceTool.h">
|
|
||||||
<Filter>Header Files\Tool</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Tool\Tool.h">
|
|
||||||
<Filter>Header Files\Tool</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\DataModelInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\GroupInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\Instance.h">
|
|
||||||
<Filter>Header Files\DataModelV2</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\LevelInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\PartInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\PVInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\WorkspaceInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\BaseButtonInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\BaseGuiInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\GuiRootInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\ImageButtonInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\TextButtonInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\DataModelV2\ToggleImageButtonInstance.h">
|
|
||||||
<Filter>Header Files\DataModelV2\Gui</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Properties\BoolProperty.h">
|
|
||||||
<Filter>Header Files\Properties</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
<ClInclude Include="src\include\Properties\Property.h">
|
|
||||||
<Filter>Header Files\Properties</Filter>
|
|
||||||
</ClInclude>
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<None Include="B3dIcon.ico">
|
|
||||||
<Filter>Resource Files</Filter>
|
|
||||||
</None>
|
|
||||||
<None Include="FatB3dIcon.ico">
|
|
||||||
<Filter>Resource Files</Filter>
|
|
||||||
</None>
|
|
||||||
<None Include="Parts.bmp">
|
|
||||||
<Filter>Resource Files</Filter>
|
|
||||||
</None>
|
|
||||||
<None Include="roblox_RN1_icon.ico">
|
|
||||||
<Filter>Resource Files</Filter>
|
|
||||||
</None>
|
|
||||||
</ItemGroup>
|
|
||||||
<ItemGroup>
|
|
||||||
<ResourceCompile Include="Dialogs.rc">
|
|
||||||
<Filter>Resource Files</Filter>
|
|
||||||
</ResourceCompile>
|
|
||||||
</ItemGroup>
|
|
||||||
</Project>
|
|
||||||
@@ -1,10 +1,9 @@
|
|||||||
#include "DataModelV2/BaseButtonInstance.h"
|
#include "BaseButtonInstance.h"
|
||||||
#include "Listener/ButtonListener.h"
|
#include "ButtonListener.h"
|
||||||
|
|
||||||
|
|
||||||
ButtonListener::ButtonListener()
|
ButtonListener::ButtonListener()
|
||||||
{
|
{
|
||||||
doDelete = true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ButtonListener::~ButtonListener(void)
|
ButtonListener::~ButtonListener(void)
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
//#include "Application.h"
|
//#include "Application.h"
|
||||||
#include "DataModelV2/BaseButtonInstance.h"
|
//#include "BaseButtonInstance.h"
|
||||||
|
|
||||||
class BaseButtonInstance;
|
class BaseButtonInstance;
|
||||||
|
|
||||||
@@ -10,7 +10,6 @@ class ButtonListener
|
|||||||
ButtonListener();
|
ButtonListener();
|
||||||
~ButtonListener(void);
|
~ButtonListener(void);
|
||||||
virtual void onButton1MouseClick(BaseButtonInstance*);
|
virtual void onButton1MouseClick(BaseButtonInstance*);
|
||||||
bool doDelete;
|
|
||||||
//virtual void onMouseOver(); //TODO
|
//virtual void onMouseOver(); //TODO
|
||||||
//virtual void onMouseOut(); //TODO
|
//virtual void onMouseOut(); //TODO
|
||||||
//virtual void onButton1MouseDown(); //TODO
|
//virtual void onButton1MouseDown(); //TODO
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
#include "Listener/CameraButtonListener.h"
|
#include "CameraButtonListener.h"
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include "AudioPlayer.h"
|
#include "AudioPlayer.h"
|
||||||
#include "Application.h"
|
#include "Application.h"
|
||||||
@@ -7,8 +7,8 @@ void CameraButtonListener::onButton1MouseClick(BaseButtonInstance* button)
|
|||||||
{
|
{
|
||||||
AudioPlayer::playSound(cameraSound);
|
AudioPlayer::playSound(cameraSound);
|
||||||
CoordinateFrame frame = g_usableApp->cameraController.getCamera()->getCoordinateFrame();
|
CoordinateFrame frame = g_usableApp->cameraController.getCamera()->getCoordinateFrame();
|
||||||
if(button->name == "CenterCam" && g_dataModel->getSelectionService()->getSelection().size() > 0)
|
if(button->name == "CenterCam" && g_selectedInstances.size() > 0)
|
||||||
g_usableApp->cameraController.centerCamera(g_dataModel->getSelectionService()->getSelection()[0]);
|
g_usableApp->cameraController.centerCamera(g_selectedInstances.at(0));
|
||||||
else if(button->name == "ZoomIn")
|
else if(button->name == "ZoomIn")
|
||||||
g_usableApp->cameraController.Zoom(1);
|
g_usableApp->cameraController.Zoom(1);
|
||||||
else if(button->name == "ZoomOut")
|
else if(button->name == "ZoomOut")
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
#include "CameraController.h"
|
#include "CameraController.h"
|
||||||
#include "win32Defines.h"
|
#include "win32Defines.h"
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include "DataModelV2/PartInstance.h"
|
#include "PartInstance.h"
|
||||||
#include "Application.h"
|
#include "Application.h"
|
||||||
#include "AudioPlayer.h"
|
#include "AudioPlayer.h"
|
||||||
|
|
||||||
@@ -57,35 +57,6 @@ void CameraController::refreshZoom(const CoordinateFrame& frame)
|
|||||||
|
|
||||||
void CameraController::pan(CoordinateFrame* frame,float spdX, float spdY)
|
void CameraController::pan(CoordinateFrame* frame,float spdX, float spdY)
|
||||||
{
|
{
|
||||||
|
|
||||||
yaw+=spdX;
|
|
||||||
pitch+=spdY;
|
|
||||||
|
|
||||||
if (pitch>1.4f) pitch=1.4f;
|
|
||||||
if (pitch<-1.4f) pitch=-1.4f;
|
|
||||||
frame->translation = Vector3(sin(-yaw)*zoom*cos(pitch),sin(pitch)*zoom,cos(-yaw)*zoom*cos(pitch))+focusPosition;
|
|
||||||
frame->lookAt(focusPosition);
|
|
||||||
}
|
|
||||||
|
|
||||||
void CameraController::panLock(CoordinateFrame* frame,float spdX, float spdY)
|
|
||||||
{
|
|
||||||
int sign = 0;
|
|
||||||
|
|
||||||
|
|
||||||
yaw = toDegrees(yaw);
|
|
||||||
if((((yaw - fmod(yaw, 45)) / 45) * 45) < 0)
|
|
||||||
{
|
|
||||||
sign = 1;
|
|
||||||
}
|
|
||||||
yaw = fabs(yaw);
|
|
||||||
yaw = ((yaw - fmod(yaw, 45)) / 45) * 45;
|
|
||||||
yaw = toRadians(yaw);
|
|
||||||
|
|
||||||
if(sign==1)
|
|
||||||
{
|
|
||||||
yaw = yaw * -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
yaw+=spdX;
|
yaw+=spdX;
|
||||||
pitch+=spdY;
|
pitch+=spdY;
|
||||||
|
|
||||||
@@ -134,14 +105,14 @@ void CameraController::Zoom(short delta)
|
|||||||
void CameraController::panLeft()
|
void CameraController::panLeft()
|
||||||
{
|
{
|
||||||
CoordinateFrame frame = g3dCamera.getCoordinateFrame();
|
CoordinateFrame frame = g3dCamera.getCoordinateFrame();
|
||||||
panLock(&frame,toRadians(-45),0);
|
pan(&frame,toRadians(-45),0);
|
||||||
setFrame(frame);
|
setFrame(frame);
|
||||||
|
|
||||||
}
|
}
|
||||||
void CameraController::panRight()
|
void CameraController::panRight()
|
||||||
{
|
{
|
||||||
CoordinateFrame frame = g3dCamera.getCoordinateFrame();
|
CoordinateFrame frame = g3dCamera.getCoordinateFrame();
|
||||||
panLock(&frame,toRadians(45),0);
|
pan(&frame,toRadians(45),0);
|
||||||
setFrame(frame);
|
setFrame(frame);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -159,11 +130,6 @@ void CameraController::tiltDown()
|
|||||||
setFrame(frame);
|
setFrame(frame);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CameraController::zoomExtents()
|
|
||||||
{
|
|
||||||
// do some weird jank math
|
|
||||||
}
|
|
||||||
|
|
||||||
void CameraController::centerCamera(Instance* selection)
|
void CameraController::centerCamera(Instance* selection)
|
||||||
{
|
{
|
||||||
CoordinateFrame frame = CoordinateFrame(g3dCamera.getCoordinateFrame().translation);
|
CoordinateFrame frame = CoordinateFrame(g3dCamera.getCoordinateFrame().translation);
|
||||||
@@ -193,8 +159,6 @@ void CameraController::update(Application* app)
|
|||||||
Vector3 cameraPos = g3dCamera.getCoordinateFrame().translation;
|
Vector3 cameraPos = g3dCamera.getCoordinateFrame().translation;
|
||||||
CoordinateFrame frame = g3dCamera.getCoordinateFrame();
|
CoordinateFrame frame = g3dCamera.getCoordinateFrame();
|
||||||
bool moving=false;
|
bool moving=false;
|
||||||
if(!app->viewportHasFocus())
|
|
||||||
return;
|
|
||||||
if(GetHoldKeyState('U')) {
|
if(GetHoldKeyState('U')) {
|
||||||
forwards = true;
|
forwards = true;
|
||||||
moving=true;
|
moving=true;
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <G3DAll.h>
|
#include <G3DAll.h>
|
||||||
#include "DataModelV2/Instance.h"
|
#include "Instance.h"
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
@@ -19,14 +19,12 @@ class CameraController {
|
|||||||
void lookAt(const Vector3& position);
|
void lookAt(const Vector3& position);
|
||||||
void refreshZoom(const CoordinateFrame& frame);
|
void refreshZoom(const CoordinateFrame& frame);
|
||||||
void pan(CoordinateFrame* frame,float spdX,float spdY);
|
void pan(CoordinateFrame* frame,float spdX,float spdY);
|
||||||
void panLock(CoordinateFrame* frame,float spdX,float spdY);
|
|
||||||
void update(Application* app);
|
void update(Application* app);
|
||||||
void centerCamera(Instance* selection);
|
void centerCamera(Instance* selection);
|
||||||
void panLeft();
|
void panLeft();
|
||||||
void panRight();
|
void panRight();
|
||||||
void tiltUp();
|
void tiltUp();
|
||||||
void tiltDown();
|
void tiltDown();
|
||||||
void zoomExtents();
|
|
||||||
void Zoom(short delta);
|
void Zoom(short delta);
|
||||||
bool onMouseWheel(int x, int y, short delta);
|
bool onMouseWheel(int x, int y, short delta);
|
||||||
GCamera* getCamera();
|
GCamera* getCamera();
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include "DataModel/GuiRootInstance.h"
|
#include "GuiRoot.h"
|
||||||
#include "DataModel/DataModelInstance.h"
|
#include "DataModelInstance.h"
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
@@ -15,14 +15,14 @@ DataModelInstance::DataModelInstance(void)
|
|||||||
{
|
{
|
||||||
Instance::Instance();
|
Instance::Instance();
|
||||||
workspace = new WorkspaceInstance();
|
workspace = new WorkspaceInstance();
|
||||||
guiRoot = new GuiRootInstance();
|
guiRoot = new GuiRoot();
|
||||||
level = new LevelInstance();
|
level = new LevelInstance();
|
||||||
//children.push_back(workspace);
|
//children.push_back(workspace);
|
||||||
//children.push_back(level);
|
//children.push_back(level);
|
||||||
className = "dataModel";
|
className = "dataModel";
|
||||||
//mousex = 0;
|
mousex = 0;
|
||||||
//mousey = 0;
|
mousey = 0;
|
||||||
//mouseButton1Down = false;
|
mouseButton1Down = false;
|
||||||
showMessage = false;
|
showMessage = false;
|
||||||
canDelete = false;
|
canDelete = false;
|
||||||
_modY=0;
|
_modY=0;
|
||||||
@@ -30,19 +30,9 @@ DataModelInstance::DataModelInstance(void)
|
|||||||
level->setParent(this);
|
level->setParent(this);
|
||||||
_loadedFileName="..//skooter.rbxm";
|
_loadedFileName="..//skooter.rbxm";
|
||||||
listicon = 5;
|
listicon = 5;
|
||||||
running = false;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DataModelInstance::toggleRun()
|
|
||||||
{
|
|
||||||
running = !running;
|
|
||||||
}
|
|
||||||
bool DataModelInstance::isRunning()
|
|
||||||
{
|
|
||||||
return running;
|
|
||||||
}
|
|
||||||
|
|
||||||
DataModelInstance::~DataModelInstance(void)
|
DataModelInstance::~DataModelInstance(void)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -267,7 +257,6 @@ bool DataModelInstance::scanXMLObject(xml_node<> * scanNode)
|
|||||||
xml_node<> *propNode = node->first_node();
|
xml_node<> *propNode = node->first_node();
|
||||||
xml_node<> *cFrameNode=0;
|
xml_node<> *cFrameNode=0;
|
||||||
xml_node<> *sizeNode=0;
|
xml_node<> *sizeNode=0;
|
||||||
xml_node<> *shapeNode=0;
|
|
||||||
xml_node<> *colorNode=0;
|
xml_node<> *colorNode=0;
|
||||||
xml_node<> *brickColorNode=0;
|
xml_node<> *brickColorNode=0;
|
||||||
xml_node<> *nameNode=0;
|
xml_node<> *nameNode=0;
|
||||||
@@ -287,11 +276,6 @@ bool DataModelInstance::scanXMLObject(xml_node<> * scanNode)
|
|||||||
{
|
{
|
||||||
nameNode = partPropNode;
|
nameNode = partPropNode;
|
||||||
}
|
}
|
||||||
if (xmlValue=="shape")
|
|
||||||
{
|
|
||||||
shapeNode = partPropNode;
|
|
||||||
_legacyLoad=false;
|
|
||||||
}
|
|
||||||
if (xmlValue=="Color")
|
if (xmlValue=="Color")
|
||||||
{
|
{
|
||||||
colorNode=partPropNode;
|
colorNode=partPropNode;
|
||||||
@@ -313,16 +297,11 @@ bool DataModelInstance::scanXMLObject(xml_node<> * scanNode)
|
|||||||
{
|
{
|
||||||
std::string xmlName = attr->name();
|
std::string xmlName = attr->name();
|
||||||
std::string xmlValue = attr->value();
|
std::string xmlValue = attr->value();
|
||||||
if (xmlValue=="shape")
|
|
||||||
{
|
|
||||||
shapeNode = featureNode;
|
|
||||||
_legacyLoad=true;
|
|
||||||
}
|
|
||||||
if (xmlValue=="size")
|
if (xmlValue=="size")
|
||||||
{
|
{
|
||||||
sizeNode=featureNode;
|
sizeNode=featureNode;
|
||||||
_legacyLoad=true;
|
_legacyLoad=true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -349,21 +328,7 @@ bool DataModelInstance::scanXMLObject(xml_node<> * scanNode)
|
|||||||
B = getFloatValue(colorNode,"B");
|
B = getFloatValue(colorNode,"B");
|
||||||
}
|
}
|
||||||
|
|
||||||
Enum::Shape::Value partshape = Enum::Shape::Block;
|
|
||||||
std::string pshape = shapeNode->value();
|
|
||||||
if (shapeNode)
|
|
||||||
{
|
|
||||||
if(pshape == "0" || pshape == "Ball"){
|
|
||||||
partshape = Enum::Shape::Ball;
|
|
||||||
}
|
|
||||||
if(pshape == "1" || pshape == "Block"){
|
|
||||||
partshape = Enum::Shape::Block;
|
|
||||||
}
|
|
||||||
if(pshape == "2" || pshape == "Cylinder"){
|
|
||||||
partshape = Enum::Shape::Cylinder;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
std::string newName = nameNode->value();
|
std::string newName = nameNode->value();
|
||||||
float X = getFloatValue(cFrameNode,"X");
|
float X = getFloatValue(cFrameNode,"X");
|
||||||
float Y = getFloatValue(cFrameNode,"Y");
|
float Y = getFloatValue(cFrameNode,"Y");
|
||||||
@@ -388,7 +353,6 @@ bool DataModelInstance::scanXMLObject(xml_node<> * scanNode)
|
|||||||
PartInstance* test = makePart();
|
PartInstance* test = makePart();
|
||||||
test->setParent(getWorkspace());
|
test->setParent(getWorkspace());
|
||||||
test->color = Color3(R,G,B);
|
test->color = Color3(R,G,B);
|
||||||
test->shape = partshape;
|
|
||||||
if(brickColorNode)
|
if(brickColorNode)
|
||||||
{
|
{
|
||||||
test->color = bcToRGB(atoi(brickColorNode->value()));
|
test->color = bcToRGB(atoi(brickColorNode->value()));
|
||||||
@@ -452,7 +416,6 @@ bool DataModelInstance::load(const char* filename, bool clearObjects)
|
|||||||
std::stringstream msg;
|
std::stringstream msg;
|
||||||
msg << "Failed to load file:" << std::endl << filename << std::endl << strerror(errno);
|
msg << "Failed to load file:" << std::endl << filename << std::endl << strerror(errno);
|
||||||
MessageBoxStr(msg.str());
|
MessageBoxStr(msg.str());
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -587,7 +550,7 @@ WorkspaceInstance* DataModelInstance::getWorkspace()
|
|||||||
{
|
{
|
||||||
return workspace;
|
return workspace;
|
||||||
}
|
}
|
||||||
/*Vector2 DataModelInstance::getMousePos()
|
Vector2 DataModelInstance::getMousePos()
|
||||||
{
|
{
|
||||||
return Vector2(mousex,mousey);
|
return Vector2(mousex,mousey);
|
||||||
}
|
}
|
||||||
@@ -600,8 +563,8 @@ void DataModelInstance::setMousePos(Vector2 pos)
|
|||||||
{
|
{
|
||||||
mousex=pos.x;
|
mousex=pos.x;
|
||||||
mousey=pos.y;
|
mousey=pos.y;
|
||||||
}*/
|
}
|
||||||
GuiRootInstance* DataModelInstance::getGuiRoot()
|
GuiRoot* DataModelInstance::getGuiRoot()
|
||||||
{
|
{
|
||||||
return guiRoot;
|
return guiRoot;
|
||||||
}
|
}
|
||||||
@@ -2,12 +2,10 @@
|
|||||||
#include "WorkspaceInstance.h"
|
#include "WorkspaceInstance.h"
|
||||||
#include "LevelInstance.h"
|
#include "LevelInstance.h"
|
||||||
#include "PartInstance.h"
|
#include "PartInstance.h"
|
||||||
#include "SelectionService.h"
|
|
||||||
#include "rapidxml/rapidxml.hpp"
|
#include "rapidxml/rapidxml.hpp"
|
||||||
#include "GuiRootInstance.h"
|
#include "GuiRoot.h"
|
||||||
#include "XplicitNgine/XplicitNgine.h"
|
|
||||||
|
|
||||||
class GuiRootInstance;
|
class GuiRoot;
|
||||||
|
|
||||||
class DataModelInstance :
|
class DataModelInstance :
|
||||||
public Instance
|
public Instance
|
||||||
@@ -24,19 +22,23 @@ public:
|
|||||||
bool readXMLFileStream(std::ifstream* file);
|
bool readXMLFileStream(std::ifstream* file);
|
||||||
void drawMessage(RenderDevice*);
|
void drawMessage(RenderDevice*);
|
||||||
WorkspaceInstance* getWorkspace();
|
WorkspaceInstance* getWorkspace();
|
||||||
|
WorkspaceInstance* workspace;
|
||||||
|
LevelInstance * level;
|
||||||
LevelInstance * getLevel();
|
LevelInstance * getLevel();
|
||||||
XplicitNgine * getEngine();
|
GuiRoot* guiRoot;
|
||||||
std::string message;
|
std::string message;
|
||||||
std::string _loadedFileName;
|
std::string _loadedFileName;
|
||||||
bool showMessage;
|
bool showMessage;
|
||||||
G3D::GFontRef font;
|
G3D::GFontRef font;
|
||||||
GuiRootInstance* getGuiRoot();
|
GuiRoot* getGuiRoot();
|
||||||
SelectionService* getSelectionService();
|
float mousex;
|
||||||
|
float mousey;
|
||||||
|
Vector2 getMousePos();
|
||||||
|
void setMousePos(int x,int y);
|
||||||
|
void setMousePos(Vector2 pos);
|
||||||
|
bool mouseButton1Down;
|
||||||
PartInstance* makePart();
|
PartInstance* makePart();
|
||||||
void clearLevel();
|
void clearLevel();
|
||||||
void toggleRun();
|
|
||||||
bool isRunning();
|
|
||||||
void resetEngine();
|
|
||||||
#if _DEBUG
|
#if _DEBUG
|
||||||
void modXMLLevel(float modY);
|
void modXMLLevel(float modY);
|
||||||
#endif
|
#endif
|
||||||
@@ -49,10 +51,4 @@ private:
|
|||||||
std::string _errMsg;
|
std::string _errMsg;
|
||||||
bool _legacyLoad;
|
bool _legacyLoad;
|
||||||
float _modY;
|
float _modY;
|
||||||
WorkspaceInstance* workspace;
|
|
||||||
LevelInstance * level;
|
|
||||||
GuiRootInstance* guiRoot;
|
|
||||||
SelectionService* selectionService;
|
|
||||||
bool running;
|
|
||||||
XplicitNgine * xplicitNgine;
|
|
||||||
};
|
};
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
#include "Listener/DeleteListener.h"
|
#include "DeleteListener.h"
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include "Application.h"
|
#include "Application.h"
|
||||||
|
|
||||||
BIN
Dialogs.aps
139
Dialogs.rc
@@ -1,96 +1,43 @@
|
|||||||
// Generated by ResEdit 1.6.6
|
// Generated by ResEdit 1.6.6
|
||||||
// Copyright (C) 2006-2015
|
// Copyright (C) 2006-2015
|
||||||
// http://www.resedit.net
|
// http://www.resedit.net
|
||||||
|
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#include <commctrl.h>
|
#include <commctrl.h>
|
||||||
#include <richedit.h>
|
#include <richedit.h>
|
||||||
#include "src/include/resource.h"
|
#include "resource.h"
|
||||||
|
|
||||||
#define APP_GENER 0
|
|
||||||
#define APP_MAJOR 0
|
|
||||||
#define APP_MINOR 106
|
|
||||||
#define APP_PATCH 2
|
//
|
||||||
#define APP_VER_STRING APP_GENER.APP_MAJOR.APP_MINOR.APP_PATCH
|
// Bitmap resources
|
||||||
|
//
|
||||||
#define VER_PREFIX( N ) v##N
|
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_CAN
|
||||||
#define HSTR( N ) #N
|
IDB_BITMAP1 BITMAP "Parts.bmp"
|
||||||
#define STR( N ) HSTR( N )
|
|
||||||
#define VER_STR( N ) STR( VER_PREFIX( N ) )
|
|
||||||
|
|
||||||
|
//
|
||||||
|
// Dialog resources
|
||||||
|
//
|
||||||
//
|
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
||||||
// Bitmap resources
|
IDD_DIALOG1 DIALOG 0, 0, 295, 43
|
||||||
//
|
STYLE DS_3DLOOK | DS_CENTER | DS_MODALFRAME | DS_SETFOREGROUND | DS_SHELLFONT | WS_CAPTION | WS_VISIBLE | WS_POPUP | WS_SYSMENU
|
||||||
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_CAN
|
EXSTYLE WS_EX_WINDOWEDGE
|
||||||
IDB_BITMAP1 BITMAP "Parts.bmp"
|
CAPTION "Insert Object"
|
||||||
|
FONT 8, "Ms Shell Dlg"
|
||||||
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
{
|
||||||
1 VERSIONINFO
|
EDITTEXT IDE_EDIT, 35, 6, 195, 14, ES_AUTOHSCROLL, WS_EX_LEFT
|
||||||
FILEVERSION APP_GENER,APP_MAJOR,APP_MINOR,APP_PATCH
|
LTEXT "Class:", 0, 10, 9, 20, 9, SS_LEFT, WS_EX_LEFT
|
||||||
PRODUCTVERSION APP_GENER,APP_MAJOR,APP_MINOR,APP_PATCH
|
PUSHBUTTON "Cancel", IDCANCEL, 237, 24, 50, 14, 0, WS_EX_LEFT
|
||||||
FILEOS VOS__WINDOWS32
|
DEFPUSHBUTTON "OK", IDOK, 237, 6, 50, 14, 0, WS_EX_LEFT
|
||||||
FILETYPE VFT_APP
|
}
|
||||||
FILESUBTYPE VFT2_UNKNOWN
|
|
||||||
FILEFLAGSMASK 0
|
|
||||||
FILEFLAGS 0
|
|
||||||
{
|
//
|
||||||
BLOCK "StringFileInfo"
|
// Icon resources
|
||||||
{
|
//
|
||||||
BLOCK "100901B5"
|
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_CAN
|
||||||
{
|
IDI_ICON1 ICON "icon1.ico"
|
||||||
VALUE "Comments", ""
|
|
||||||
VALUE "CompanyName", "Blocks3D Team"
|
|
||||||
VALUE "FileDescription", "Blocks 3D"
|
|
||||||
VALUE "FileVersion", VER_STR(APP_VER_STRING)
|
|
||||||
VALUE "InternalName", "Blocks3D"
|
|
||||||
VALUE "LegalCopyright", "Blocks3D Team - 2022"
|
|
||||||
VALUE "LegalTrademarks", ""
|
|
||||||
VALUE "OriginalFilename", "Blocks3D.exe"
|
|
||||||
VALUE "PrivateBuild", ""
|
|
||||||
VALUE "ProductName", "Blocks3D"
|
|
||||||
VALUE "ProductVersion", VER_STR(APP_VER_STRING)
|
|
||||||
VALUE "SpecialBuild", ""
|
|
||||||
}
|
|
||||||
}
|
|
||||||
BLOCK "VarFileInfo"
|
|
||||||
{
|
|
||||||
VALUE "Translation", 0x1009, 0x01B5
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
// Dialog resources
|
|
||||||
//
|
|
||||||
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
|
||||||
IDD_DIALOG1 DIALOG 0, 0, 295, 43
|
|
||||||
STYLE DS_3DLOOK | DS_CENTER | DS_MODALFRAME | DS_SETFOREGROUND | DS_SHELLFONT | WS_CAPTION | WS_VISIBLE | WS_POPUP | WS_SYSMENU
|
|
||||||
EXSTYLE WS_EX_WINDOWEDGE
|
|
||||||
CAPTION "Insert Object"
|
|
||||||
FONT 8, "Ms Shell Dlg"
|
|
||||||
{
|
|
||||||
EDITTEXT IDC_EDIT1, 35, 6, 195, 14, ES_AUTOHSCROLL, WS_EX_LEFT
|
|
||||||
LTEXT "Class:", 0, 10, 9, 20, 9, SS_LEFT, WS_EX_LEFT
|
|
||||||
PUSHBUTTON "Cancel", IDCANCEL, 237, 24, 50, 14, 0, WS_EX_LEFT
|
|
||||||
DEFPUSHBUTTON "OK", IDOK, 237, 6, 50, 14, 0, WS_EX_LEFT
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//
|
|
||||||
// Icon resources
|
|
||||||
//
|
|
||||||
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_CAN
|
|
||||||
IDI_ICON1 ICON "FatB3dIcon.ico"
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//
|
|
||||||
// Manifest resources
|
|
||||||
//
|
|
||||||
#ifndef _DEBUG
|
|
||||||
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
|
|
||||||
1 MANIFEST ".\\Blocks3D.exe.manifest"
|
|
||||||
#endif
|
|
||||||
|
|||||||
17
Enum.h
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
namespace Enum
|
||||||
|
{
|
||||||
|
namespace SurfaceType
|
||||||
|
{
|
||||||
|
enum Value {
|
||||||
|
Smooth, Snaps, Inlets, Glue, Weld, Spawn, Hinge, Motor, Bumps
|
||||||
|
};
|
||||||
|
}
|
||||||
|
namespace Shape
|
||||||
|
{
|
||||||
|
enum Value {
|
||||||
|
Ball = 0, Block = 1, Cylinder = 2
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
16
Enums.h
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
#ifdef UENUMS
|
||||||
|
#ifndef ENUM_H
|
||||||
|
#define ENUM_H
|
||||||
|
static enum BinType {GameTool, Grab, Clone, Hammer};
|
||||||
|
static enum ControllerType {None, KeyboardRight, KeyboardLeft, Joypad1, Joypad2, Chase, Flee};
|
||||||
|
//static enum JointType {UNK0, WeldJoint, SnapJoint, UNK3, Rotate, RotateP, RotateV, GlueJoint, UNK8, UNK9, None};
|
||||||
|
static enum ActionType {Nothing, Pause, Lose, Draw, Win};
|
||||||
|
static enum AffectType {NoChange, Increase, Decrease};
|
||||||
|
static enum InputType {NoInput, LeftTread, RightTread, Steer, Throtle, UpDown, Action1, Action2, Action3, Action4, Action5, Constant, Sin};
|
||||||
|
//static enum SurfaceConstraint {None, Hinge, SteppingMotor, Motor};
|
||||||
|
static enum SurfaceType{Smooth, Snaps, Inlets, Glue, Weld, Spawn, Hinge, Motor, Bumps};
|
||||||
|
static enum SoundType {NoSound, Boing, Bomb, Break, Click, Clock, Slingshot, Page, Ping, Snap, Splat, Step, StepOn, Swoosh, Victory};
|
||||||
|
static enum PartType {Ball, Block, Cylinder};
|
||||||
|
static enum KeywordFilterType {Include, Exclude};
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
@@ -3,13 +3,12 @@
|
|||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void OnError(int err, std::string msg)
|
void OnError(int err, std::string msg)
|
||||||
{
|
{
|
||||||
//g_usableApp->window()->setInputCaptureCount(0);
|
//g_usableApp->window()->setInputCaptureCount(0);
|
||||||
//g_usableApp->window()->setMouseVisible(true);
|
//g_usableApp->window()->setMouseVisible(true);
|
||||||
std::string emsg = "An unexpected error has occured and "+g_appName+" has to quit. We're sorry!" + msg;
|
std::string emsg = "An unexpected error has occured and "+g_PlaceholderName+" has to quit. We're sorry!" + msg;
|
||||||
std::string title = g_appName+" Crash";
|
std::string title = g_PlaceholderName+"Crash";
|
||||||
//clearInstances();
|
//clearInstances();
|
||||||
MessageBox(NULL, emsg.c_str(), title.c_str(), MB_OK);
|
MessageBox(NULL, emsg.c_str(), title.c_str(), MB_OK);
|
||||||
exit(err);
|
exit(err);
|
||||||
@@ -18,13 +17,13 @@ void OnError(int err, std::string msg)
|
|||||||
|
|
||||||
void MessageBoxStr(std::string msg)
|
void MessageBoxStr(std::string msg)
|
||||||
{
|
{
|
||||||
std::string title = g_appName;
|
std::string title = g_PlaceholderName;
|
||||||
MessageBox(NULL, msg.c_str(), title.c_str(), MB_OK);
|
MessageBox(NULL, msg.c_str(), title.c_str(), MB_OK);
|
||||||
}
|
}
|
||||||
|
|
||||||
void MessageBoxStream(std::stringstream msg)
|
void MessageBoxStream(std::stringstream msg)
|
||||||
{
|
{
|
||||||
std::string strMsg = msg.str();
|
std::string strMsg = msg.str();
|
||||||
std::string title = g_appName;
|
std::string title = g_PlaceholderName;
|
||||||
MessageBox(NULL, strMsg.c_str(), title.c_str(), MB_OK);
|
MessageBox(NULL, strMsg.c_str(), title.c_str(), MB_OK);
|
||||||
}
|
}
|
||||||
BIN
FatB3dIcon.ico
|
Before Width: | Height: | Size: 108 KiB |
BIN
G3DTest.aps
Normal file
@@ -1,24 +1,24 @@
|
|||||||
# Microsoft Developer Studio Project File - Name="Blocks3D" - Package Owner=<4>
|
# Microsoft Developer Studio Project File - Name="G3DTest" - Package Owner=<4>
|
||||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||||
# ** DO NOT EDIT **
|
# ** DO NOT EDIT **
|
||||||
|
|
||||||
# TARGTYPE "Win32 (x86) Application" 0x0101
|
# TARGTYPE "Win32 (x86) Application" 0x0101
|
||||||
|
|
||||||
CFG=Blocks3D - Win32 Debug
|
CFG=G3DTest - Win32 Debug
|
||||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||||
!MESSAGE use the Export Makefile command and run
|
!MESSAGE use the Export Makefile command and run
|
||||||
!MESSAGE
|
!MESSAGE
|
||||||
!MESSAGE NMAKE /f "Blocks3D.mak".
|
!MESSAGE NMAKE /f "G3DTest.mak".
|
||||||
!MESSAGE
|
!MESSAGE
|
||||||
!MESSAGE You can specify a configuration when running NMAKE
|
!MESSAGE You can specify a configuration when running NMAKE
|
||||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||||
!MESSAGE
|
!MESSAGE
|
||||||
!MESSAGE NMAKE /f "Blocks3D.mak" CFG="Blocks3D - Win32 Debug"
|
!MESSAGE NMAKE /f "G3DTest.mak" CFG="G3DTest - Win32 Debug"
|
||||||
!MESSAGE
|
!MESSAGE
|
||||||
!MESSAGE Possible choices for configuration are:
|
!MESSAGE Possible choices for configuration are:
|
||||||
!MESSAGE
|
!MESSAGE
|
||||||
!MESSAGE "Blocks3D - Win32 Release" (based on "Win32 (x86) Application")
|
!MESSAGE "G3DTest - Win32 Release" (based on "Win32 (x86) Application")
|
||||||
!MESSAGE "Blocks3D - Win32 Debug" (based on "Win32 (x86) Application")
|
!MESSAGE "G3DTest - Win32 Debug" (based on "Win32 (x86) Application")
|
||||||
!MESSAGE
|
!MESSAGE
|
||||||
|
|
||||||
# Begin Project
|
# Begin Project
|
||||||
@@ -29,7 +29,7 @@ CPP=cl.exe
|
|||||||
MTL=midl.exe
|
MTL=midl.exe
|
||||||
RSC=rc.exe
|
RSC=rc.exe
|
||||||
|
|
||||||
!IF "$(CFG)" == "Blocks3D - Win32 Release"
|
!IF "$(CFG)" == "G3DTest - Win32 Release"
|
||||||
|
|
||||||
# PROP BASE Use_MFC 0
|
# PROP BASE Use_MFC 0
|
||||||
# PROP BASE Use_Debug_Libraries 0
|
# PROP BASE Use_Debug_Libraries 0
|
||||||
@@ -54,7 +54,7 @@ LINK32=link.exe
|
|||||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
|
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
|
||||||
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
|
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
|
||||||
|
|
||||||
!ELSEIF "$(CFG)" == "Blocks3D - Win32 Debug"
|
!ELSEIF "$(CFG)" == "G3DTest - Win32 Debug"
|
||||||
|
|
||||||
# PROP BASE Use_MFC 0
|
# PROP BASE Use_MFC 0
|
||||||
# PROP BASE Use_Debug_Libraries 1
|
# PROP BASE Use_Debug_Libraries 1
|
||||||
@@ -83,8 +83,8 @@ LINK32=link.exe
|
|||||||
|
|
||||||
# Begin Target
|
# Begin Target
|
||||||
|
|
||||||
# Name "Blocks3D - Win32 Release"
|
# Name "G3DTest - Win32 Release"
|
||||||
# Name "Blocks3D - Win32 Debug"
|
# Name "G3DTest - Win32 Debug"
|
||||||
# Begin Group "Source Files"
|
# Begin Group "Source Files"
|
||||||
|
|
||||||
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||||
@@ -3,7 +3,7 @@ Microsoft Developer Studio Workspace File, Format Version 6.00
|
|||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
Project: "Blocks3D"=.\Blocks3D.dsp - Package Owner=<4>
|
Project: "G3DTest"=.\G3DTest.dsp - Package Owner=<4>
|
||||||
|
|
||||||
Package=<5>
|
Package=<5>
|
||||||
{{{
|
{{{
|
||||||
BIN
G3DTest.opt
Normal file
32
G3DTest.plg
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
<html>
|
||||||
|
<body>
|
||||||
|
<pre>
|
||||||
|
<h1>Build Log</h1>
|
||||||
|
<h3>
|
||||||
|
--------------------Configuration: G3DTest - Win32 Debug--------------------
|
||||||
|
</h3>
|
||||||
|
<h3>Command Lines</h3>
|
||||||
|
Creating temporary file "C:\Users\Andreja\AppData\Local\Temp\RSPFD70.tmp" with contents
|
||||||
|
[
|
||||||
|
/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"Debug/G3DTest.pch" /YX /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
|
||||||
|
"C:\USERS\ANDREJA\G3D\G3DTest\main.cpp"
|
||||||
|
]
|
||||||
|
Creating command line "cl.exe @C:\Users\Andreja\AppData\Local\Temp\RSPFD70.tmp"
|
||||||
|
Creating temporary file "C:\Users\Andreja\AppData\Local\Temp\RSPFD71.tmp" with contents
|
||||||
|
[
|
||||||
|
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:yes /pdb:"Debug/G3DTest.pdb" /debug /machine:I386 /out:"Debug/G3DTest.exe" /pdbtype:sept
|
||||||
|
.\Debug\main.obj
|
||||||
|
]
|
||||||
|
Creating command line "link.exe @C:\Users\Andreja\AppData\Local\Temp\RSPFD71.tmp"
|
||||||
|
<h3>Output Window</h3>
|
||||||
|
Compiling...
|
||||||
|
main.cpp
|
||||||
|
Linking...
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<h3>Results</h3>
|
||||||
|
G3DTest.exe - 0 error(s), 0 warning(s)
|
||||||
|
</pre>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
Microsoft Visual Studio Solution File, Format Version 9.00
|
||||||
# Visual C++ Express 2005
|
# Visual C++ Express 2005
|
||||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Blocks3D", "Blocks3D.vcproj", "{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}"
|
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "G3DTest", "G3DTest.vcproj", "{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}"
|
||||||
EndProject
|
EndProject
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
579
G3DTest.vcproj
Normal file
@@ -0,0 +1,579 @@
|
|||||||
|
<?xml version="1.0" encoding="Windows-1252"?>
|
||||||
|
<VisualStudioProject
|
||||||
|
ProjectType="Visual C++"
|
||||||
|
Version="8.00"
|
||||||
|
Name="G3DTest"
|
||||||
|
ProjectGUID="{6C4D6EEF-B1D1-456A-B850-92CAB17124BE}"
|
||||||
|
RootNamespace="G3DTest"
|
||||||
|
>
|
||||||
|
<Platforms>
|
||||||
|
<Platform
|
||||||
|
Name="Win32"
|
||||||
|
/>
|
||||||
|
</Platforms>
|
||||||
|
<ToolFiles>
|
||||||
|
</ToolFiles>
|
||||||
|
<Configurations>
|
||||||
|
<Configuration
|
||||||
|
Name="Release|Win32"
|
||||||
|
OutputDirectory=".\Release"
|
||||||
|
IntermediateDirectory=".\Release"
|
||||||
|
ConfigurationType="1"
|
||||||
|
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
|
||||||
|
UseOfMFC="0"
|
||||||
|
UseOfATL="0"
|
||||||
|
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||||
|
CharacterSet="2"
|
||||||
|
>
|
||||||
|
<Tool
|
||||||
|
Name="VCPreBuildEventTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCCustomBuildTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCXMLDataGeneratorTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCWebServiceProxyGeneratorTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCMIDLTool"
|
||||||
|
PreprocessorDefinitions="NDEBUG"
|
||||||
|
MkTypLibCompatible="true"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
TargetEnvironment="1"
|
||||||
|
TypeLibraryName=".\Release/G3DTest.tlb"
|
||||||
|
HeaderFileName=""
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCCLCompilerTool"
|
||||||
|
Optimization="2"
|
||||||
|
InlineFunctionExpansion="1"
|
||||||
|
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS"
|
||||||
|
StringPooling="true"
|
||||||
|
RuntimeLibrary="2"
|
||||||
|
EnableFunctionLevelLinking="true"
|
||||||
|
PrecompiledHeaderFile=".\Release/G3DTest.pch"
|
||||||
|
AssemblerListingLocation=".\Release/"
|
||||||
|
ObjectFile=".\Release/"
|
||||||
|
ProgramDataBaseFileName=".\Release/"
|
||||||
|
WarningLevel="3"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCManagedResourceCompilerTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCResourceCompilerTool"
|
||||||
|
PreprocessorDefinitions="NDEBUG"
|
||||||
|
Culture="4105"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCPreLinkEventTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCLinkerTool"
|
||||||
|
AdditionalDependencies="Advapi32.lib UxTheme.lib Comctl32.lib Comdlg32.lib Shell32.lib"
|
||||||
|
OutputFile="./G3DTest.exe"
|
||||||
|
LinkIncremental="1"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
ProgramDatabaseFile=".\Release/G3DTest.pdb"
|
||||||
|
SubSystem="2"
|
||||||
|
TargetMachine="1"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCALinkTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCManifestTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCXDCMakeTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCBscMakeTool"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
OutputFile=".\Release/G3DTest.bsc"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCFxCopTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCAppVerifierTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCWebDeploymentTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCPostBuildEventTool"
|
||||||
|
/>
|
||||||
|
</Configuration>
|
||||||
|
<Configuration
|
||||||
|
Name="Debug|Win32"
|
||||||
|
OutputDirectory=".\Debug"
|
||||||
|
IntermediateDirectory=".\Debug"
|
||||||
|
ConfigurationType="1"
|
||||||
|
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"
|
||||||
|
UseOfMFC="0"
|
||||||
|
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||||
|
CharacterSet="2"
|
||||||
|
ManagedExtensions="0"
|
||||||
|
>
|
||||||
|
<Tool
|
||||||
|
Name="VCPreBuildEventTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCCustomBuildTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCXMLDataGeneratorTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCWebServiceProxyGeneratorTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCMIDLTool"
|
||||||
|
PreprocessorDefinitions="_DEBUG"
|
||||||
|
MkTypLibCompatible="true"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
TargetEnvironment="1"
|
||||||
|
TypeLibraryName=".\Debug/G3DTest.tlb"
|
||||||
|
HeaderFileName=""
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCCLCompilerTool"
|
||||||
|
Optimization="0"
|
||||||
|
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS"
|
||||||
|
MinimalRebuild="false"
|
||||||
|
BasicRuntimeChecks="0"
|
||||||
|
RuntimeLibrary="3"
|
||||||
|
EnableFunctionLevelLinking="false"
|
||||||
|
PrecompiledHeaderFile=".\Debug/G3DTest.pch"
|
||||||
|
AssemblerListingLocation=".\Debug/"
|
||||||
|
ObjectFile=".\Debug/"
|
||||||
|
ProgramDataBaseFileName=".\Debug/"
|
||||||
|
WarningLevel="3"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
DebugInformationFormat="3"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCManagedResourceCompilerTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCResourceCompilerTool"
|
||||||
|
PreprocessorDefinitions="_DEBUG"
|
||||||
|
Culture="4105"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCPreLinkEventTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCLinkerTool"
|
||||||
|
AdditionalDependencies="Advapi32.lib UxTheme.lib Comctl32.lib Comdlg32.lib Shell32.lib"
|
||||||
|
OutputFile="./G3DTest-Debug.exe"
|
||||||
|
LinkIncremental="2"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
GenerateDebugInformation="true"
|
||||||
|
ProgramDatabaseFile=".\Debug/G3DTest.pdb"
|
||||||
|
SubSystem="1"
|
||||||
|
TargetMachine="1"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCALinkTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCManifestTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCXDCMakeTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCBscMakeTool"
|
||||||
|
SuppressStartupBanner="true"
|
||||||
|
OutputFile=".\Debug/G3DTest.bsc"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCFxCopTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCAppVerifierTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCWebDeploymentTool"
|
||||||
|
/>
|
||||||
|
<Tool
|
||||||
|
Name="VCPostBuildEventTool"
|
||||||
|
/>
|
||||||
|
</Configuration>
|
||||||
|
</Configurations>
|
||||||
|
<References>
|
||||||
|
<AssemblyReference
|
||||||
|
RelativePath="System.dll"
|
||||||
|
AssemblyName="System, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"
|
||||||
|
/>
|
||||||
|
<AssemblyReference
|
||||||
|
RelativePath="System.Data.dll"
|
||||||
|
AssemblyName="System.Data, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=x86"
|
||||||
|
/>
|
||||||
|
<AssemblyReference
|
||||||
|
RelativePath="System.Drawing.dll"
|
||||||
|
AssemblyName="System.Drawing, Version=2.0.0.0, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL"
|
||||||
|
/>
|
||||||
|
<AssemblyReference
|
||||||
|
RelativePath="System.Windows.Forms.dll"
|
||||||
|
AssemblyName="System.Windows.Forms, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"
|
||||||
|
/>
|
||||||
|
<AssemblyReference
|
||||||
|
RelativePath="System.XML.dll"
|
||||||
|
AssemblyName="System.Xml, Version=2.0.0.0, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"
|
||||||
|
/>
|
||||||
|
</References>
|
||||||
|
<Files>
|
||||||
|
<Filter
|
||||||
|
Name="Source Files"
|
||||||
|
Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||||
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Application.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\AudioPlayer.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ax.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\BrowserCallHandler.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ButtonListener.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\CameraController.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ErrorFunctions.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Globals.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\GroupInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\GuiRoot.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\IEBrowser.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\IEDispatcher.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="main.cpp"
|
||||||
|
>
|
||||||
|
<FileConfiguration
|
||||||
|
Name="Release|Win32"
|
||||||
|
>
|
||||||
|
<Tool
|
||||||
|
Name="VCCLCompilerTool"
|
||||||
|
PreprocessorDefinitions=""
|
||||||
|
/>
|
||||||
|
</FileConfiguration>
|
||||||
|
<FileConfiguration
|
||||||
|
Name="Debug|Win32"
|
||||||
|
>
|
||||||
|
<Tool
|
||||||
|
Name="VCCLCompilerTool"
|
||||||
|
PreprocessorDefinitions=""
|
||||||
|
/>
|
||||||
|
</FileConfiguration>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\propertyGrid.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\PropertyWindow.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\StringFunctions.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\WindowFunctions.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<Filter
|
||||||
|
Name="Instance"
|
||||||
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\BaseButtonInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\DataModelInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ImageButtonInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Instance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\LevelInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\PartInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\PVInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\TextButtonInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\WorkspaceInstance.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="Listeners"
|
||||||
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\CameraButtonListener.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\DeleteListener.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\GUDButtonListener.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ModeSelectionListener.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\RotateButtonListener.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
</Filter>
|
||||||
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="Header Files"
|
||||||
|
Filter="h;hpp;hxx;hm;inl"
|
||||||
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Application.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\AudioPlayer.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ax.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\BrowserCallHandler.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\CameraController.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Demo.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Enum.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Enums.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ErrorFunctions.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Globals.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\GuiRoot.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\IEBrowser.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\IEDispatcher.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\LevelInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\propertyGrid.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\PropertyWindow.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\rapidxml\rapidxml.hpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\rapidxml\rapidxml_iterators.hpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\rapidxml\rapidxml_print.hpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\rapidxml\rapidxml_utils.hpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\resource.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\RotateButtonListener.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\StringFunctions.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\win32Defines.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\WindowFunctions.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<Filter
|
||||||
|
Name="Instance"
|
||||||
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\BaseButtonInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\DataModelInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\GroupInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ImageButtonInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Instance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\PartInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\PVInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\TextButtonInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\WorkspaceInstance.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="Listeners"
|
||||||
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ButtonListener.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\CameraButtonListener.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\DeleteListener.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\GUDButtonListener.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\ModeSelectionListener.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
</Filter>
|
||||||
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="Resource Files"
|
||||||
|
Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
|
||||||
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Dialogs.rc"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\icon1.ico"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\Parts.bmp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
</Filter>
|
||||||
|
</Files>
|
||||||
|
<Globals>
|
||||||
|
<Global
|
||||||
|
Name="RESOURCE_FILE"
|
||||||
|
Value="Dialogs.rc"
|
||||||
|
/>
|
||||||
|
</Globals>
|
||||||
|
</VisualStudioProject>
|
||||||
40
GUDButtonListener.cpp
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
#include <G3DAll.h>
|
||||||
|
#include "Application.h"
|
||||||
|
#include "Globals.h"
|
||||||
|
#include "AudioPlayer.h"
|
||||||
|
#include "GUDButtonListener.h"
|
||||||
|
|
||||||
|
void GUDButtonListener::onButton1MouseClick(BaseButtonInstance* button)
|
||||||
|
{
|
||||||
|
bool cont = false;
|
||||||
|
for(size_t i = 0; i < g_selectedInstances.size(); i++)
|
||||||
|
if(g_selectedInstances.at(i)->canDelete)
|
||||||
|
{
|
||||||
|
cont = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if(cont)
|
||||||
|
{
|
||||||
|
AudioPlayer::playSound(dingSound);
|
||||||
|
if(button->name == "Duplicate")
|
||||||
|
{
|
||||||
|
std::vector<Instance*> newinst;
|
||||||
|
for(size_t i = 0; i < g_selectedInstances.size(); i++)
|
||||||
|
{
|
||||||
|
if(g_selectedInstances.at(i)->canDelete)
|
||||||
|
{
|
||||||
|
Instance* tempinst = g_selectedInstances.at(i);
|
||||||
|
|
||||||
|
Instance* clonedInstance = g_selectedInstances.at(i)->clone();
|
||||||
|
|
||||||
|
newinst.push_back(tempinst);
|
||||||
|
}
|
||||||
|
/*tempinst->setPosition(Vector3(tempPos.x, tempPos.y + tempSize.y, tempPos.z));
|
||||||
|
g_usableApp->cameraController.centerCamera(g_selectedInstances.at(0));*/
|
||||||
|
}
|
||||||
|
g_selectedInstances = newinst;
|
||||||
|
if(g_selectedInstances.size() > 0)
|
||||||
|
g_usableApp->_propWindow->UpdateSelected(newinst.at(0));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,13 +1,17 @@
|
|||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include "Application.h"
|
#include "Application.h"
|
||||||
|
|
||||||
|
int const Globals::gen = 0;
|
||||||
|
int const Globals::major = 0;
|
||||||
|
int const Globals::minor = 4;
|
||||||
|
int const Globals::patch = 2;
|
||||||
int Globals::surfaceId = 2;
|
int Globals::surfaceId = 2;
|
||||||
//bool Globals::showMouse = true;
|
bool Globals::showMouse = true;
|
||||||
bool Globals::useMousePoint = false;
|
bool Globals::useMousePoint = false;
|
||||||
std::vector<Instance*> postRenderStack = std::vector<Instance*>();
|
std::vector<Instance*> postRenderStack = std::vector<Instance*>();
|
||||||
|
|
||||||
|
std::vector<Instance*> g_selectedInstances = std::vector<Instance*>();
|
||||||
DataModelInstance* g_dataModel = NULL;
|
DataModelInstance* g_dataModel = NULL;
|
||||||
XplicitNgine* g_xplicitNgine = NULL;
|
|
||||||
|
|
||||||
bool running = false;
|
bool running = false;
|
||||||
G3D::TextureRef Globals::surface;
|
G3D::TextureRef Globals::surface;
|
||||||
@@ -15,7 +19,6 @@ POINT Globals::mousepoint;
|
|||||||
|
|
||||||
GFontRef g_fntdominant = NULL;
|
GFontRef g_fntdominant = NULL;
|
||||||
GFontRef g_fntlighttrek = NULL;
|
GFontRef g_fntlighttrek = NULL;
|
||||||
HWND Globals::mainHwnd = NULL;
|
|
||||||
|
|
||||||
Globals::Globals(void){}
|
Globals::Globals(void){}
|
||||||
|
|
||||||
@@ -25,6 +28,4 @@ std::string cameraSound="";
|
|||||||
std::string clickSound="";
|
std::string clickSound="";
|
||||||
std::string dingSound="";
|
std::string dingSound="";
|
||||||
|
|
||||||
Application *g_usableApp = NULL;
|
Application *g_usableApp = NULL;
|
||||||
|
|
||||||
COLORREF g_acrCustClr[16] = {RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255),RGB(255,255,255)};
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "DataModelV2/DataModelInstance.h"
|
#include "DataModelInstance.h"
|
||||||
#include "XplicitNgine/XplicitNgine.h"
|
#include <G3DAll.h>
|
||||||
|
|
||||||
class Application;
|
class Application;
|
||||||
|
|
||||||
@@ -10,7 +10,7 @@ public:
|
|||||||
Globals(void);
|
Globals(void);
|
||||||
~Globals(void);
|
~Globals(void);
|
||||||
static DataModelInstance* dataModel;
|
static DataModelInstance* dataModel;
|
||||||
//static bool showMouse;
|
static bool showMouse;
|
||||||
static POINT mousepoint;
|
static POINT mousepoint;
|
||||||
static bool useMousePoint;
|
static bool useMousePoint;
|
||||||
static const int gen;
|
static const int gen;
|
||||||
@@ -19,23 +19,19 @@ public:
|
|||||||
static const int patch;
|
static const int patch;
|
||||||
static G3D::TextureRef surface;
|
static G3D::TextureRef surface;
|
||||||
static int surfaceId;
|
static int surfaceId;
|
||||||
static const std::string g_appName;
|
static const std::string g_PlaceholderName;
|
||||||
static COLORREF g_acrCustClr[16]; //Will be dynamic later
|
|
||||||
static HWND mainHwnd;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
extern std::vector<Instance*> postRenderStack;
|
extern std::vector<Instance*> postRenderStack;
|
||||||
|
extern std::vector<Instance*> g_selectedInstances;
|
||||||
extern bool running;
|
extern bool running;
|
||||||
extern DataModelInstance* g_dataModel;
|
extern DataModelInstance* g_dataModel;
|
||||||
extern XplicitNgine* g_xplicitNgine;
|
|
||||||
extern Application* g_usableApp;
|
extern Application* g_usableApp;
|
||||||
|
|
||||||
extern GFontRef g_fntdominant;
|
extern GFontRef g_fntdominant;
|
||||||
extern GFontRef g_fntlighttrek;
|
extern GFontRef g_fntlighttrek;
|
||||||
|
|
||||||
extern COLORREF g_acrCustClr[16]; //Will be dynamic later
|
|
||||||
extern std::string cameraSound;
|
extern std::string cameraSound;
|
||||||
extern std::string clickSound;
|
extern std::string clickSound;
|
||||||
extern std::string dingSound;
|
extern std::string dingSound;
|
||||||
extern HWND mainHwnd;
|
const std::string g_PlaceholderName = "HyperCube";
|
||||||
const std::string g_appName = "Blocks3D";
|
|
||||||
30
GroupInstance.cpp
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
#include "GroupInstance.h"
|
||||||
|
|
||||||
|
GroupInstance::GroupInstance(void)
|
||||||
|
{
|
||||||
|
PVInstance::PVInstance();
|
||||||
|
className = "GroupInstance";
|
||||||
|
listicon = 12;
|
||||||
|
}
|
||||||
|
|
||||||
|
GroupInstance::GroupInstance(const GroupInstance &oinst)
|
||||||
|
{
|
||||||
|
PVInstance::PVInstance(oinst);
|
||||||
|
listicon = 12;
|
||||||
|
}
|
||||||
|
|
||||||
|
GroupInstance::~GroupInstance(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
std::vector<PROPGRIDITEM> GroupInstance::getProperties()
|
||||||
|
{
|
||||||
|
std::vector<PROPGRIDITEM> properties = PVInstance::getProperties();
|
||||||
|
return properties;
|
||||||
|
}
|
||||||
|
void GroupInstance::PropUpdate(LPPROPGRIDITEM &pItem)
|
||||||
|
{
|
||||||
|
PVInstance::PropUpdate(pItem);
|
||||||
|
}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "PartInstance.h"
|
#include "PVInstance.h"
|
||||||
|
|
||||||
class GroupInstance :
|
class GroupInstance :
|
||||||
public PVInstance
|
public PVInstance
|
||||||
@@ -10,7 +10,5 @@ public:
|
|||||||
GroupInstance(const GroupInstance &oinst);
|
GroupInstance(const GroupInstance &oinst);
|
||||||
virtual std::vector<PROPGRIDITEM> getProperties();
|
virtual std::vector<PROPGRIDITEM> getProperties();
|
||||||
virtual void PropUpdate(LPPROPGRIDITEM &pItem);
|
virtual void PropUpdate(LPPROPGRIDITEM &pItem);
|
||||||
std::vector<Instance *> unGroup();
|
|
||||||
PartInstance * primaryPart;
|
|
||||||
void render(RenderDevice * r);
|
|
||||||
};
|
};
|
||||||
@@ -1,25 +1,22 @@
|
|||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
#include "G3DAll.h"
|
#include "G3DAll.h"
|
||||||
#include "DataModel/BaseButtonInstance.h"
|
#include "BaseButtonInstance.h"
|
||||||
#include "DataModel/TextButtonInstance.h"
|
#include "TextButtonInstance.h"
|
||||||
#include "DataModel/ImageButtonInstance.h"
|
#include "ImageButtonInstance.h"
|
||||||
#include "DataModel/ToggleImageButtonInstance.h"
|
#include "GuiRoot.h"
|
||||||
#include "DataModel/GuiRootInstance.h"
|
|
||||||
#include "DataModel/ImageButtonInstance.h"
|
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include "StringFunctions.h"
|
#include "StringFunctions.h"
|
||||||
|
|
||||||
#include "Listener/GUDButtonListener.h"
|
#include "GUDButtonListener.h"
|
||||||
#include "Listener/ModeSelectionListener.h"
|
#include "ModeSelectionListener.h"
|
||||||
#include "Listener/MenuButtonListener.h"
|
#include "RotateButtonListener.h"
|
||||||
#include "Listener/RotateButtonListener.h"
|
#include "CameraButtonListener.h"
|
||||||
#include "Listener/CameraButtonListener.h"
|
#include "DeleteListener.h"
|
||||||
#include "Listener/DeleteListener.h"
|
|
||||||
#include "Listener/ToolbarListener.h"
|
|
||||||
|
|
||||||
|
#include "ImageButtonInstance.h"
|
||||||
|
|
||||||
ImageButtonInstance* GuiRootInstance::makeImageButton(G3D::TextureRef newImage = NULL, G3D::TextureRef overImage = NULL, G3D::TextureRef downImage = NULL, G3D::TextureRef disableImage = NULL)
|
ImageButtonInstance* GuiRoot::makeImageButton(G3D::TextureRef newImage = NULL, G3D::TextureRef overImage = NULL, G3D::TextureRef downImage = NULL, G3D::TextureRef disableImage = NULL)
|
||||||
{
|
{
|
||||||
ImageButtonInstance* part = new ImageButtonInstance(newImage,overImage, downImage, disableImage);
|
ImageButtonInstance* part = new ImageButtonInstance(newImage,overImage, downImage, disableImage);
|
||||||
// instances.push_back(part);
|
// instances.push_back(part);
|
||||||
@@ -27,20 +24,17 @@ ImageButtonInstance* GuiRootInstance::makeImageButton(G3D::TextureRef newImage =
|
|||||||
return part;
|
return part;
|
||||||
}
|
}
|
||||||
|
|
||||||
TextButtonInstance* GuiRootInstance::makeTextButton()
|
TextButtonInstance* GuiRoot::makeTextButton()
|
||||||
{
|
{
|
||||||
TextButtonInstance* part = new TextButtonInstance();
|
TextButtonInstance* part = new TextButtonInstance();
|
||||||
return part;
|
return part;
|
||||||
}
|
}
|
||||||
ToolbarListener * toolbar;
|
|
||||||
GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
GuiRoot::GuiRoot() : _message(""), _messageTime(0)
|
||||||
{
|
{
|
||||||
toolbar = new ToolbarListener();
|
|
||||||
toolbar->doDelete = false;
|
|
||||||
g_fntdominant = GFont::fromFile(GetFileInPath("/content/font/dominant.fnt"));
|
g_fntdominant = GFont::fromFile(GetFileInPath("/content/font/dominant.fnt"));
|
||||||
g_fntlighttrek = GFont::fromFile(GetFileInPath("/content/font/lighttrek.fnt"));
|
g_fntlighttrek = GFont::fromFile(GetFileInPath("/content/font/lighttrek.fnt"));
|
||||||
|
|
||||||
//Bottom Left
|
|
||||||
TextButtonInstance* button = makeTextButton();
|
TextButtonInstance* button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0, -24);
|
button->boxBegin = Vector2(0, -24);
|
||||||
button->boxEnd = Vector2(80, 0);
|
button->boxEnd = Vector2(80, 0);
|
||||||
@@ -52,11 +46,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->title = "Hopper";
|
button->title = "Hopper";
|
||||||
button->fontLocationRelativeTo = Vector2(10, 3);
|
button->fontLocationRelativeTo = Vector2(10, 3);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxOutlineColorOvr = Color3(0,255,255);
|
|
||||||
button->boxColorDn = Color4(button->boxColor.r,button->boxColor.g,button->boxColor.b, 0.2F);
|
|
||||||
button->setButtonListener(toolbar);
|
|
||||||
toolbar->addButtonRef(button);
|
|
||||||
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0, -48);
|
button->boxBegin = Vector2(0, -48);
|
||||||
@@ -69,10 +58,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->title = "Controller";
|
button->title = "Controller";
|
||||||
button->fontLocationRelativeTo = Vector2(10, 3);
|
button->fontLocationRelativeTo = Vector2(10, 3);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxOutlineColorOvr = Color3(0,255,255);
|
|
||||||
button->boxColorDn = Color4(button->boxColor.r,button->boxColor.g,button->boxColor.b, 0.2F);
|
|
||||||
button->setButtonListener(toolbar);
|
|
||||||
toolbar->addButtonRef(button);
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0, -72);
|
button->boxBegin = Vector2(0, -72);
|
||||||
@@ -85,10 +70,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->title = "Color";
|
button->title = "Color";
|
||||||
button->fontLocationRelativeTo = Vector2(10, 3);
|
button->fontLocationRelativeTo = Vector2(10, 3);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxOutlineColorOvr = Color3(0,255,255);
|
|
||||||
button->boxColorDn = Color4(button->boxColor.r,button->boxColor.g,button->boxColor.b, 0.2F);
|
|
||||||
button->setButtonListener(toolbar);
|
|
||||||
toolbar->addButtonRef(button);
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0, -96);
|
button->boxBegin = Vector2(0, -96);
|
||||||
@@ -101,10 +82,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->title = "Surface";
|
button->title = "Surface";
|
||||||
button->fontLocationRelativeTo = Vector2(10, 3);
|
button->fontLocationRelativeTo = Vector2(10, 3);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxOutlineColorOvr = Color3(0,255,255);
|
|
||||||
button->boxColorDn = Color4(button->boxColor.r,button->boxColor.g,button->boxColor.b, 0.2F);
|
|
||||||
button->setButtonListener(toolbar);
|
|
||||||
toolbar->addButtonRef(button);
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0, -120);
|
button->boxBegin = Vector2(0, -120);
|
||||||
@@ -113,16 +90,11 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->setParent(this);
|
button->setParent(this);
|
||||||
button->font = g_fntlighttrek;
|
button->font = g_fntlighttrek;
|
||||||
button->textColor = Color3(0,255,255);
|
button->textColor = Color3(0,255,255);
|
||||||
|
button->boxOutlineColor = Color3(0,255,255);
|
||||||
button->title = "Model";
|
button->title = "Model";
|
||||||
button->selected = true;
|
|
||||||
button->fontLocationRelativeTo = Vector2(10, 3);
|
button->fontLocationRelativeTo = Vector2(10, 3);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxOutlineColorOvr = Color3(0,255,255);
|
|
||||||
button->boxColorDn = Color4(button->boxColor.r,button->boxColor.g,button->boxColor.b, 0.2F);
|
|
||||||
button->setButtonListener(toolbar);
|
|
||||||
toolbar->addButtonRef(button);
|
|
||||||
|
|
||||||
//Top bar
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0, 0);
|
button->boxBegin = Vector2(0, 0);
|
||||||
button->boxEnd = Vector2(125, 25);
|
button->boxEnd = Vector2(125, 25);
|
||||||
@@ -135,9 +107,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->textSize = 16;
|
button->textSize = 16;
|
||||||
button->fontLocationRelativeTo = Vector2(10, 0);
|
button->fontLocationRelativeTo = Vector2(10, 0);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxColorOvr = Color4(0.6F,0.6F,0.6F,0.4F);
|
|
||||||
button->name = "file";
|
|
||||||
button->setButtonListener(new MenuButtonListener());
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(125, 0);
|
button->boxBegin = Vector2(125, 0);
|
||||||
@@ -151,7 +120,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->textSize = 16;
|
button->textSize = 16;
|
||||||
button->fontLocationRelativeTo = Vector2(10, 0);
|
button->fontLocationRelativeTo = Vector2(10, 0);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxColorOvr = Color4(0.6F,0.6F,0.6F,0.4F);
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(250, 0);
|
button->boxBegin = Vector2(250, 0);
|
||||||
@@ -165,7 +133,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->textSize = 16;
|
button->textSize = 16;
|
||||||
button->fontLocationRelativeTo = Vector2(10, 0);
|
button->fontLocationRelativeTo = Vector2(10, 0);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxColorOvr = Color4(0.6F,0.6F,0.6F,0.4F);
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(375, 0);
|
button->boxBegin = Vector2(375, 0);
|
||||||
@@ -179,7 +146,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->textSize = 16;
|
button->textSize = 16;
|
||||||
button->fontLocationRelativeTo = Vector2(10, 0);
|
button->fontLocationRelativeTo = Vector2(10, 0);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxColorOvr = Color4(0.6F,0.6F,0.6F,0.4F);
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(500, 0);
|
button->boxBegin = Vector2(500, 0);
|
||||||
@@ -193,10 +159,9 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->textSize = 16;
|
button->textSize = 16;
|
||||||
button->fontLocationRelativeTo = Vector2(10, 0);
|
button->fontLocationRelativeTo = Vector2(10, 0);
|
||||||
button->setAllColorsSame();
|
button->setAllColorsSame();
|
||||||
button->boxColorOvr = Color4(0.6F,0.6F,0.6F,0.4F);
|
|
||||||
|
|
||||||
|
|
||||||
//Menu
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0,215);
|
button->boxBegin = Vector2(0,215);
|
||||||
button->boxEnd = Vector2(80,235);
|
button->boxEnd = Vector2(80,235);
|
||||||
@@ -211,7 +176,7 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->font = g_fntlighttrek;
|
button->font = g_fntlighttrek;
|
||||||
button->fontLocationRelativeTo = Vector2(10, 0);
|
button->fontLocationRelativeTo = Vector2(10, 0);
|
||||||
button->setParent(this);
|
button->setParent(this);
|
||||||
button->setButtonListener(new GUDButtonListener());
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0,240);
|
button->boxBegin = Vector2(0,240);
|
||||||
@@ -227,7 +192,6 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->font = g_fntlighttrek;
|
button->font = g_fntlighttrek;
|
||||||
button->fontLocationRelativeTo = Vector2(10, 0);
|
button->fontLocationRelativeTo = Vector2(10, 0);
|
||||||
button->setParent(this);
|
button->setParent(this);
|
||||||
button->setButtonListener(new GUDButtonListener());
|
|
||||||
|
|
||||||
button = makeTextButton();
|
button = makeTextButton();
|
||||||
button->boxBegin = Vector2(0,265);
|
button->boxBegin = Vector2(0,265);
|
||||||
@@ -245,16 +209,10 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
button->name = "Duplicate";
|
button->name = "Duplicate";
|
||||||
button->setButtonListener(new GUDButtonListener());
|
button->setButtonListener(new GUDButtonListener());
|
||||||
|
|
||||||
ImageButtonInstance* instance = new ToggleImageButtonInstance(
|
ImageButtonInstance* instance = makeImageButton(
|
||||||
Texture::fromFile(GetFileInPath("/content/images/Run.png")),
|
Texture::fromFile(GetFileInPath("/content/images/Run.png")),
|
||||||
Texture::fromFile(GetFileInPath("/content/images/Run_ovr.png")),
|
Texture::fromFile(GetFileInPath("/content/images/Run_ovr.png")),
|
||||||
Texture::fromFile(GetFileInPath("/content/images/Run_dn.png")),
|
Texture::fromFile(GetFileInPath("/content/images/Run_dn.png")));
|
||||||
NULL,
|
|
||||||
Texture::fromFile(GetFileInPath("/content/images/Stop.png")),
|
|
||||||
Texture::fromFile(GetFileInPath("/content/images/Stop_ovr.png")),
|
|
||||||
Texture::fromFile(GetFileInPath("/content/images/Stop_dn.png"))
|
|
||||||
);
|
|
||||||
instance->setButtonListener(new MenuButtonListener());
|
|
||||||
instance->name = "go";
|
instance->name = "go";
|
||||||
instance->size = Vector2(65,65);
|
instance->size = Vector2(65,65);
|
||||||
instance->position = Vector2(6.5, 25);
|
instance->position = Vector2(6.5, 25);
|
||||||
@@ -411,24 +369,24 @@ GuiRootInstance::GuiRootInstance() : _message(""), _messageTime(0)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GuiRootInstance::drawButtons(RenderDevice* rd)
|
void GuiRoot::drawButtons(RenderDevice* rd)
|
||||||
{
|
{
|
||||||
rd->pushState();
|
rd->pushState();
|
||||||
rd->beforePrimitive();
|
rd->beforePrimitive();
|
||||||
//this->render(rd);
|
this->render(rd);
|
||||||
rd->afterPrimitive();
|
rd->afterPrimitive();
|
||||||
rd->popState();
|
rd->popState();
|
||||||
}
|
}
|
||||||
|
|
||||||
void GuiRootInstance::setDebugMessage(std::string msg, G3D::RealTime msgTime)
|
void GuiRoot::setDebugMessage(std::string msg, G3D::RealTime msgTime)
|
||||||
{
|
{
|
||||||
_messageTime = msgTime;
|
_messageTime = msgTime;
|
||||||
_message = msg;
|
_message = msg;
|
||||||
}
|
}
|
||||||
|
|
||||||
//void GuiRootInstance::render(G3D::RenderDevice* renderDevice) {}
|
//void GuiRoot::render(G3D::RenderDevice* renderDevice) {}
|
||||||
|
|
||||||
void GuiRootInstance::renderGUI(G3D::RenderDevice* rd, double fps)
|
void GuiRoot::renderGUI(G3D::RenderDevice* rd, double fps)
|
||||||
{
|
{
|
||||||
//TODO--Move these to their own instance
|
//TODO--Move these to their own instance
|
||||||
|
|
||||||
@@ -445,7 +403,7 @@ void GuiRootInstance::renderGUI(G3D::RenderDevice* rd, double fps)
|
|||||||
#endif
|
#endif
|
||||||
//GUI Boxes
|
//GUI Boxes
|
||||||
Draw::box(G3D::Box(Vector3(0,25,0),Vector3(80,355,0)),rd,Color4(0.6F,0.6F,0.6F,0.4F), Color4(0,0,0,0));
|
Draw::box(G3D::Box(Vector3(0,25,0),Vector3(80,355,0)),rd,Color4(0.6F,0.6F,0.6F,0.4F), Color4(0,0,0,0));
|
||||||
Draw::box(G3D::Box(Vector3(rd->getWidth() - 120,rd->getHeight() - 117,0),Vector3(rd->getWidth(),rd->getHeight(),0)),rd,Color4(0.6F,0.6F,0.6F,0.4F), Color4(0,0,0,0));
|
Draw::box(G3D::Box(Vector3(rd->getWidth() - 120,rd->getHeight() - 120,0),Vector3(rd->getWidth(),rd->getHeight(),0)),rd,Color4(0.6F,0.6F,0.6F,0.4F), Color4(0,0,0,0));
|
||||||
|
|
||||||
//Camera menu title
|
//Camera menu title
|
||||||
g_fntlighttrek->draw2D(rd, "CameraMenu", Vector2(rd->getWidth()-(g_fntlighttrek->get2DStringBounds("CameraMenu", 14).x+1),rd->getHeight() - 120), 14, Color3::white(), Color4(0.5F,0.5F,0.5F,0.5F));
|
g_fntlighttrek->draw2D(rd, "CameraMenu", Vector2(rd->getWidth()-(g_fntlighttrek->get2DStringBounds("CameraMenu", 14).x+1),rd->getHeight() - 120), 14, Color3::white(), Color4(0.5F,0.5F,0.5F,0.5F));
|
||||||
@@ -455,7 +413,7 @@ void GuiRootInstance::renderGUI(G3D::RenderDevice* rd, double fps)
|
|||||||
g_fntlighttrek->draw2D(rd,"MENU", Vector2(10,332), 14, Color3::white(), Color4(0.5F,0.5F,0.5F,0.5F));
|
g_fntlighttrek->draw2D(rd,"MENU", Vector2(10,332), 14, Color3::white(), Color4(0.5F,0.5F,0.5F,0.5F));
|
||||||
|
|
||||||
|
|
||||||
//drawButtons(rd);
|
drawButtons(rd);
|
||||||
if(System::time() - 3 < _messageTime)
|
if(System::time() - 3 < _messageTime)
|
||||||
{
|
{
|
||||||
g_fntdominant->draw2D(rd, _message, Vector2((rd->getWidth()/2)-(g_fntdominant->get2DStringBounds(_message, 20).x/2),(rd->getHeight()/2)-(g_fntdominant->get2DStringBounds(_message, 20).y/2)), 20, Color3::yellow(), Color3::black());
|
g_fntdominant->draw2D(rd, _message, Vector2((rd->getWidth()/2)-(g_fntdominant->get2DStringBounds(_message, 20).x/2),(rd->getHeight()/2)-(g_fntdominant->get2DStringBounds(_message, 20).y/2)), 20, Color3::yellow(), Color3::black());
|
||||||
@@ -465,7 +423,7 @@ void GuiRootInstance::renderGUI(G3D::RenderDevice* rd, double fps)
|
|||||||
render(rd);
|
render(rd);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool GuiRootInstance::mouseInGUI(G3D::RenderDevice* renderDevice,int x,int y)
|
bool GuiRoot::mouseInGUI(G3D::RenderDevice* renderDevice,int x,int y)
|
||||||
{
|
{
|
||||||
std::vector<Instance*> instances_2D = g_dataModel->getGuiRoot()->getAllChildren();
|
std::vector<Instance*> instances_2D = g_dataModel->getGuiRoot()->getAllChildren();
|
||||||
for(size_t i = 0; i < instances_2D.size(); i++)
|
for(size_t i = 0; i < instances_2D.size(); i++)
|
||||||
@@ -481,7 +439,7 @@ bool GuiRootInstance::mouseInGUI(G3D::RenderDevice* renderDevice,int x,int y)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void GuiRootInstance::update()
|
void GuiRoot::update()
|
||||||
{
|
{
|
||||||
Instance * obj6 = this->findFirstChild("Delete");
|
Instance * obj6 = this->findFirstChild("Delete");
|
||||||
Instance * obj = this->findFirstChild("Duplicate");
|
Instance * obj = this->findFirstChild("Duplicate");
|
||||||
@@ -517,12 +475,7 @@ void GuiRootInstance::update()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
GuiRootInstance::~GuiRootInstance()
|
void GuiRoot::onMouseLeftUp(G3D::RenderDevice* renderDevice, int x,int y)
|
||||||
{
|
|
||||||
delete toolbar;
|
|
||||||
}
|
|
||||||
|
|
||||||
void GuiRootInstance::onMouseLeftUp(G3D::RenderDevice* renderDevice, int x,int y)
|
|
||||||
{
|
{
|
||||||
std::vector<Instance*> instances_2D = this->getAllChildren();
|
std::vector<Instance*> instances_2D = this->getAllChildren();
|
||||||
for(size_t i = 0; i < instances_2D.size(); i++)
|
for(size_t i = 0; i < instances_2D.size(); i++)
|
||||||
@@ -5,11 +5,10 @@ class ImageButtonInstance;
|
|||||||
|
|
||||||
class TextButtonInstance;
|
class TextButtonInstance;
|
||||||
|
|
||||||
class GuiRootInstance : public Instance
|
class GuiRoot : public Instance
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
GuiRootInstance();
|
GuiRoot();
|
||||||
GuiRootInstance::~GuiRootInstance();
|
|
||||||
TextButtonInstance* makeTextButton();
|
TextButtonInstance* makeTextButton();
|
||||||
void drawButtons(RenderDevice* rd);
|
void drawButtons(RenderDevice* rd);
|
||||||
ImageButtonInstance* makeImageButton(G3D::TextureRef newImage, G3D::TextureRef overImage, G3D::TextureRef downImage, G3D::TextureRef disableImage);
|
ImageButtonInstance* makeImageButton(G3D::TextureRef newImage, G3D::TextureRef overImage, G3D::TextureRef downImage, G3D::TextureRef disableImage);
|
||||||
105
IEBrowser.cpp
Normal file
@@ -0,0 +1,105 @@
|
|||||||
|
#ifndef WIN32_LEAN_AND_MEAN
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
|
#include "IEBrowser.h"
|
||||||
|
#include "Globals.h"
|
||||||
|
#include "ax.h"
|
||||||
|
//#include "IEDispatcher.h"
|
||||||
|
|
||||||
|
void IEBrowser::Boop(char* test)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
IEBrowser::IEBrowser(HWND attachHWnd) {
|
||||||
|
MSG messages;
|
||||||
|
while (PeekMessage (&messages, NULL, 0, 0,PM_REMOVE))
|
||||||
|
{
|
||||||
|
if (IsDialogMessage(hwnd, &messages) == 0)
|
||||||
|
{
|
||||||
|
TranslateMessage(&messages);
|
||||||
|
DispatchMessage(&messages);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
hwnd = attachHWnd;
|
||||||
|
spDocument = 0;
|
||||||
|
webBrowser = 0;
|
||||||
|
SendMessage(hwnd,AX_INPLACE,1,0);
|
||||||
|
SendMessage(hwnd,AX_QUERYINTERFACE,(WPARAM)&IID_IWebBrowser2,(LPARAM)&webBrowser);
|
||||||
|
}
|
||||||
|
|
||||||
|
IEBrowser::~IEBrowser(void) {
|
||||||
|
if (webBrowser)
|
||||||
|
{
|
||||||
|
webBrowser->Release();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Something goes here
|
||||||
|
int IEBrowser::setExternal(IDispatch** ext)
|
||||||
|
{
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool IEBrowser::navigateSyncURL(wchar_t* url)
|
||||||
|
{
|
||||||
|
MSG messages;
|
||||||
|
if (webBrowser)
|
||||||
|
{
|
||||||
|
webBrowser->Navigate(url,0,0,0,0);
|
||||||
|
for (int i=1;i<1000;i++)
|
||||||
|
{
|
||||||
|
while (PeekMessage (&messages, NULL, 0, 0,PM_REMOVE))
|
||||||
|
{
|
||||||
|
if (IsDialogMessage(hwnd, &messages) == 0)
|
||||||
|
{
|
||||||
|
TranslateMessage(&messages);
|
||||||
|
DispatchMessage(&messages);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Sleep(30);
|
||||||
|
|
||||||
|
HRESULT hresult = webBrowser->get_Document(&spDocument);
|
||||||
|
if (SUCCEEDED(hresult) && (spDocument != 0))
|
||||||
|
{
|
||||||
|
|
||||||
|
IOleObject* spOleObject;
|
||||||
|
if (SUCCEEDED(spDocument->QueryInterface(IID_IOleObject,(void**)&spOleObject)))
|
||||||
|
{
|
||||||
|
IOleClientSite* spClientSite;
|
||||||
|
hresult = spOleObject->GetClientSite(&spClientSite);
|
||||||
|
if (SUCCEEDED(hresult) && spClientSite)
|
||||||
|
{
|
||||||
|
m_spDefaultDocHostUIHandler = spClientSite;
|
||||||
|
ICustomDoc* spCustomDoc;
|
||||||
|
|
||||||
|
//IEDispatcher* spIEDispatcher;
|
||||||
|
if (SUCCEEDED(m_spDefaultDocHostUIHandler->QueryInterface(IID_IDocHostUIHandler,(void**)&m_spHandler)))
|
||||||
|
{
|
||||||
|
if (SUCCEEDED(spDocument->QueryInterface(IID_ICustomDoc,(void**)&spCustomDoc)))
|
||||||
|
{
|
||||||
|
spCustomDoc->SetUIHandler(m_spHandler);
|
||||||
|
|
||||||
|
m_spHandler->GetExternal(&m_spExternal);
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
MessageBox(NULL,"Cannot read IWebBrowser2...",(g_PlaceholderName+" Crash").c_str(),MB_OK);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
23
IEBrowser.h
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
//#include "WindowFunctions.h"
|
||||||
|
#pragma once
|
||||||
|
#include <mshtml.h>
|
||||||
|
#include <exdisp.h>
|
||||||
|
#include <Mshtmhst.h>
|
||||||
|
|
||||||
|
class IEBrowser {
|
||||||
|
public:
|
||||||
|
IEBrowser(HWND attachHWnd);
|
||||||
|
~IEBrowser(void);
|
||||||
|
bool navigateSyncURL(wchar_t* url);
|
||||||
|
void Boop(char* test);
|
||||||
|
private:
|
||||||
|
IWebBrowser2* webBrowser;
|
||||||
|
HWND hwnd;
|
||||||
|
IDispatch* spDocument;
|
||||||
|
IHTMLDocument* spDocument2;
|
||||||
|
IDocHostUIHandler* m_spHandler;
|
||||||
|
IDispatch* m_spExternal;
|
||||||
|
IDispatch* m_newExternal;
|
||||||
|
IOleClientSite* m_spDefaultDocHostUIHandler;
|
||||||
|
int setExternal(IDispatch** ext);
|
||||||
|
};
|
||||||
@@ -2,9 +2,11 @@
|
|||||||
#include "oaidl.h"
|
#include "oaidl.h"
|
||||||
//DEFINE_GUID(CLSID_G3d, 0xB323F8E0L, 0x2E68, 0x11D0, 0x90, 0xEA, 0x00, 0xAA, 0x00, 0x60, 0xF8, 0x6F);
|
//DEFINE_GUID(CLSID_G3d, 0xB323F8E0L, 0x2E68, 0x11D0, 0x90, 0xEA, 0x00, 0xAA, 0x00, 0x60, 0xF8, 0x6F);
|
||||||
|
|
||||||
|
/*
|
||||||
class IEDispatcher : public IDispatch
|
class IEDispatcher : public IDispatch
|
||||||
{
|
{
|
||||||
/*
|
*/
|
||||||
|
|
||||||
EXTERN_C const IID IID_IDispatch;
|
EXTERN_C const IID IID_IDispatch;
|
||||||
|
|
||||||
#if defined(__cplusplus) && !defined(CINTERFACE)
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
@@ -12,7 +14,6 @@ EXTERN_C const IID IID_IDispatch;
|
|||||||
MIDL_INTERFACE("B323F8E0-2E68-11D0-90EA-00AA0060F86F")
|
MIDL_INTERFACE("B323F8E0-2E68-11D0-90EA-00AA0060F86F")
|
||||||
IEDispatcher : public IDispatch
|
IEDispatcher : public IDispatch
|
||||||
{
|
{
|
||||||
*/
|
|
||||||
public:
|
public:
|
||||||
IEDispatcher(void);
|
IEDispatcher(void);
|
||||||
~IEDispatcher(void);
|
~IEDispatcher(void);
|
||||||
@@ -26,4 +27,4 @@ public:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
//#endif
|
#endif
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
#include "DataModel/ImageButtonInstance.h"
|
#include "ImageButtonInstance.h"
|
||||||
|
|
||||||
ImageButtonInstance::ImageButtonInstance(G3D::TextureRef newImage, G3D::TextureRef overImage = NULL, G3D::TextureRef downImage = NULL, G3D::TextureRef disableImage = NULL)
|
ImageButtonInstance::ImageButtonInstance(G3D::TextureRef newImage, G3D::TextureRef overImage = NULL, G3D::TextureRef downImage = NULL, G3D::TextureRef disableImage = NULL)
|
||||||
{
|
{
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
;InnoSetupVersion=5.4.3
|
|
||||||
#define AppVer GetFileVersion('..\Blocks3D.exe')
|
|
||||||
|
|
||||||
[Setup]
|
|
||||||
AppName=Blocks3D
|
|
||||||
AppVersion=v{#AppVer}
|
|
||||||
AppId={{4C5DF268-0208-4CDE-A7F0-65F7E2CB5067}
|
|
||||||
AppPublisherURL=http://blocks3d.com/
|
|
||||||
AppSupportURL=http://blocks3d.com/
|
|
||||||
AppUpdatesURL=http://blocks3d.com/
|
|
||||||
DefaultDirName={%localappdata}\Blocks3D
|
|
||||||
OutputBaseFilename=Blocks3D_Setup_v{#AppVer}
|
|
||||||
Compression=lzma2
|
|
||||||
PrivilegesRequired=lowest
|
|
||||||
WizardImageFile=setup.bmp
|
|
||||||
DefaultGroupName=Blocks3D
|
|
||||||
|
|
||||||
|
|
||||||
[UninstallDelete]
|
|
||||||
Type: filesandordirs; Name: "{app}"
|
|
||||||
|
|
||||||
[Files]
|
|
||||||
Source: "Redist\vcredist_x86.exe"; DestDir: "{tmp}"; Flags: ignoreversion
|
|
||||||
Source: "Redist\vcredist_x64.exe"; DestDir: "{tmp}"; Check: "IsWin64"; Flags: ignoreversion
|
|
||||||
Source: "..\content\*"; DestDir: "{app}\content"; Flags: ignoreversion recursesubdirs
|
|
||||||
Source: "..\SDL.DLL"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs
|
|
||||||
Source: "..\Blocks3D.exe"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs
|
|
||||||
|
|
||||||
[Registry]
|
|
||||||
|
|
||||||
|
|
||||||
[Run]
|
|
||||||
Filename: "{tmp}\vcredist_x86.exe"; Parameters: "/q"; Tasks: instvc;
|
|
||||||
Filename: "{tmp}\vcredist_x64.exe"; Parameters: "/q"; Tasks: instvc; Check: "IsWin64";
|
|
||||||
Filename: "iexplore.exe"; Parameters: "http://www.blocks3d.com/FirstInstall"; Description: Start playing Blocks3D; Flags: shellexec postinstall nowait skipifsilent
|
|
||||||
|
|
||||||
[Icons]
|
|
||||||
Name: "{group}\Play Blocks3D"; Filename: "{%programfiles}\Internet Explorer\iexplore.exe"; Parameters: "http://www.blocks3d.com/Games"; IconFilename: "{app}\Blocks3D.exe"; Tasks: startscut;
|
|
||||||
Name: "{group}\Blocks3D Editor"; Filename: "{app}\Blocks3D.exe"; Tasks: startscut;
|
|
||||||
|
|
||||||
Name: "{userdesktop}\Play Blocks3D"; Filename: "{%programfiles}\Internet Explorer\iexplore.exe"; Parameters: "http://www.blocks3d.com/Games"; IconFilename: "{app}\Blocks3D.exe"; Tasks: startscut;
|
|
||||||
Name: "{userdesktop}\Blocks3D Editor"; Filename: "{app}\Blocks3D.exe"; Tasks: desktopicon
|
|
||||||
|
|
||||||
[Tasks]
|
|
||||||
Name: "instvc"; Description: "Install Visual C++ Redistributable 2005 SP1 (Requires elevated permissions)";
|
|
||||||
Name: "desktopicon"; Description: "Create Desktop Icons";
|
|
||||||
Name: "startscut"; Description: "Create Start Menu Icons";
|
|
||||||
|
|
||||||
|
Before Width: | Height: | Size: 151 KiB |
|
Before Width: | Height: | Size: 6.4 KiB |
@@ -1,7 +1,6 @@
|
|||||||
#define WINVER 0x0400
|
#define WINVER 0x0400
|
||||||
#include <G3DAll.h>
|
#include <G3DAll.h>
|
||||||
#include "DataModelV2/Instance.h"
|
#include "Instance.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Instance::Instance(void)
|
Instance::Instance(void)
|
||||||
@@ -115,6 +114,21 @@ std::vector<Instance* > Instance::getAllChildren()
|
|||||||
return children;
|
return children;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::vector<Instance* > Instance::compileAndGetPVVector()
|
||||||
|
{
|
||||||
|
std::vector<Instance* > totalchildren;
|
||||||
|
if(!children.empty())
|
||||||
|
{
|
||||||
|
for(size_t i = 0; i < children.size(); i++)
|
||||||
|
{
|
||||||
|
std::vector<Instance* > subchildren = children.at(i)->compileAndGetPVVector();
|
||||||
|
if(!subchildren.empty())
|
||||||
|
totalchildren.insert(totalchildren.end(), subchildren.begin(), subchildren.end());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return totalchildren;
|
||||||
|
}
|
||||||
|
|
||||||
void Instance::setParent(Instance* newParent)
|
void Instance::setParent(Instance* newParent)
|
||||||
{
|
{
|
||||||
if(parent != NULL)
|
if(parent != NULL)
|
||||||
@@ -140,10 +154,6 @@ void Instance::addChild(Instance* newChild)
|
|||||||
|
|
||||||
void Instance::clearChildren()
|
void Instance::clearChildren()
|
||||||
{
|
{
|
||||||
for (size_t i = 0; i < children.size(); i++)
|
|
||||||
{
|
|
||||||
delete children.at(i);
|
|
||||||
}
|
|
||||||
children.clear();
|
children.clear();
|
||||||
}
|
}
|
||||||
void Instance::removeChild(Instance* oldChild)
|
void Instance::removeChild(Instance* oldChild)
|
||||||
@@ -1,8 +1,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include <G3DAll.h>
|
#include <G3DAll.h>
|
||||||
#include "propertyGrid.h"
|
#include "propertyGrid.h"
|
||||||
#include "map"
|
|
||||||
//#include "Properties/BoolProperty.h"
|
|
||||||
|
|
||||||
class Instance
|
class Instance
|
||||||
{
|
{
|
||||||
@@ -14,11 +12,11 @@ public:
|
|||||||
std::string name;
|
std::string name;
|
||||||
virtual void render(RenderDevice*);
|
virtual void render(RenderDevice*);
|
||||||
virtual void update();
|
virtual void update();
|
||||||
std::vector<Instance*> children; // All children.
|
|
||||||
std::string getClassName();
|
std::string getClassName();
|
||||||
Instance* findFirstChild(std::string);
|
Instance* findFirstChild(std::string);
|
||||||
std::vector<Instance* > getChildren();
|
std::vector<Instance* > getChildren();
|
||||||
std::vector<Instance* > getAllChildren();
|
std::vector<Instance* > getAllChildren();
|
||||||
|
std::vector<Instance* > compileAndGetPVVector();
|
||||||
virtual void setParent(Instance*);
|
virtual void setParent(Instance*);
|
||||||
void setName(std::string newName);
|
void setName(std::string newName);
|
||||||
void addChild(Instance*);
|
void addChild(Instance*);
|
||||||
@@ -30,9 +28,9 @@ public:
|
|||||||
virtual void PropUpdate(LPPROPGRIDITEM &pItem);
|
virtual void PropUpdate(LPPROPGRIDITEM &pItem);
|
||||||
int listicon;
|
int listicon;
|
||||||
protected:
|
protected:
|
||||||
|
std::vector<Instance*> children; // All children.
|
||||||
std::string className;
|
std::string className;
|
||||||
Instance* parent; // Another pointer.
|
Instance* parent; // Another pointer.
|
||||||
PROPGRIDITEM createPGI(LPSTR catalog, LPSTR propName, LPSTR propDesc, LPARAM curVal, INT type, TCHAR choices[] = NULL);
|
PROPGRIDITEM createPGI(LPSTR catalog, LPSTR propName, LPSTR propDesc, LPARAM curVal, INT type, TCHAR choices[] = NULL);
|
||||||
private:
|
|
||||||
static const std::map<std::string, Instance> g_logLevelsDescriptions;
|
|
||||||
};
|
};
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
#include "DataModel/LevelInstance.h"
|
#include "LevelInstance.h"
|
||||||
|
|
||||||
LevelInstance::LevelInstance(void)
|
LevelInstance::LevelInstance(void)
|
||||||
{
|
{
|
||||||
@@ -5,7 +5,6 @@ class LevelInstance :
|
|||||||
public Instance
|
public Instance
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
std::string SplashHTML;
|
|
||||||
LevelInstance(void);
|
LevelInstance(void);
|
||||||
~LevelInstance(void);
|
~LevelInstance(void);
|
||||||
float timer;
|
float timer;
|
||||||
@@ -1,8 +1,7 @@
|
|||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include "DataModelV2/Instance.h"
|
#include "Instance.h"
|
||||||
#include "Listener/ModeSelectionListener.h"
|
#include "ModeSelectionListener.h"
|
||||||
#include "Application.h"
|
#include "Application.h"
|
||||||
#include "Tool/ArrowTool.h"
|
|
||||||
|
|
||||||
void ModeSelectionListener::onButton1MouseClick(BaseButtonInstance* button)
|
void ModeSelectionListener::onButton1MouseClick(BaseButtonInstance* button)
|
||||||
{
|
{
|
||||||
@@ -21,7 +20,7 @@ void ModeSelectionListener::onButton1MouseClick(BaseButtonInstance* button)
|
|||||||
|
|
||||||
button->selected = true;
|
button->selected = true;
|
||||||
if(button->name == "Cursor")
|
if(button->name == "Cursor")
|
||||||
g_usableApp->changeTool(new ArrowTool());
|
g_usableApp->setMode(CURSOR);
|
||||||
else if(button->name == "Resize")
|
else if(button->name == "Resize")
|
||||||
g_usableApp->setMode(RESIZE);
|
g_usableApp->setMode(RESIZE);
|
||||||
else if(button->name == "Arrows")
|
else if(button->name == "Arrows")
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
Open Dynamics Engine
|
|
||||||
|
|
||||||
Copyright (c) 2001-2004,
|
|
||||||
Russell L. Smith.
|
|
||||||
|
|
||||||
All rights reserved.
|
|
||||||
80
PVInstance.cpp
Normal file
@@ -0,0 +1,80 @@
|
|||||||
|
#include "PVInstance.h"
|
||||||
|
#include "WorkspaceInstance.h"
|
||||||
|
|
||||||
|
PVInstance::PVInstance(void)
|
||||||
|
{
|
||||||
|
Instance::Instance();
|
||||||
|
nameShown = false;
|
||||||
|
className = "PVInstance";
|
||||||
|
listicon = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
PVInstance::PVInstance(const PVInstance &oinst)
|
||||||
|
{
|
||||||
|
Instance::Instance(oinst);
|
||||||
|
}
|
||||||
|
|
||||||
|
PVInstance::~PVInstance(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void PVInstance::postRender(RenderDevice* rd)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void PVInstance::render(RenderDevice* rd)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void PVInstance::setParent(Instance* newParent)
|
||||||
|
{
|
||||||
|
if(parent != NULL)
|
||||||
|
{
|
||||||
|
Instance* workspace = parent;
|
||||||
|
while(workspace != NULL)
|
||||||
|
{
|
||||||
|
if(WorkspaceInstance* wsp = dynamic_cast<WorkspaceInstance*>(workspace))
|
||||||
|
{
|
||||||
|
wsp->removeFromPVector(this);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
workspace = workspace->getParent();
|
||||||
|
}
|
||||||
|
parent->removeChild(this);
|
||||||
|
}
|
||||||
|
parent = newParent;
|
||||||
|
if(newParent != NULL)
|
||||||
|
{
|
||||||
|
Instance* workspace = parent;
|
||||||
|
while(workspace != NULL)
|
||||||
|
{
|
||||||
|
if(WorkspaceInstance* wsp = dynamic_cast<WorkspaceInstance*>(workspace))
|
||||||
|
{
|
||||||
|
wsp->addToPVector(this);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
workspace = workspace->getParent();
|
||||||
|
}
|
||||||
|
newParent->addChild(this);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<PROPGRIDITEM> PVInstance::getProperties()
|
||||||
|
{
|
||||||
|
std::vector<PROPGRIDITEM> properties = Instance::getProperties();
|
||||||
|
properties.push_back(createPGI(
|
||||||
|
"Item",
|
||||||
|
"NameShown",
|
||||||
|
"This chooses whether the item name is shown",
|
||||||
|
nameShown,
|
||||||
|
PIT_CHECK));
|
||||||
|
return properties;
|
||||||
|
}
|
||||||
|
void PVInstance::PropUpdate(LPPROPGRIDITEM &pItem)
|
||||||
|
{
|
||||||
|
if(strcmp(pItem->lpszPropName, "NameShown") == 0)
|
||||||
|
{
|
||||||
|
nameShown = (bool)pItem->lpCurValue;
|
||||||
|
}
|
||||||
|
else Instance::PropUpdate(pItem);
|
||||||
|
}
|
||||||
17
PVInstance.h
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
#pragma once
|
||||||
|
#include "instance.h"
|
||||||
|
|
||||||
|
class PVInstance :
|
||||||
|
public Instance
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
PVInstance(void);
|
||||||
|
~PVInstance(void);
|
||||||
|
PVInstance(const PVInstance &oinst);
|
||||||
|
virtual void postRender(RenderDevice* rd);
|
||||||
|
virtual void setParent(Instance* newParent);
|
||||||
|
virtual std::vector<PROPGRIDITEM> getProperties();
|
||||||
|
virtual void PropUpdate(LPPROPGRIDITEM &pItem);
|
||||||
|
virtual void render(RenderDevice* rd);
|
||||||
|
bool nameShown;
|
||||||
|
};
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
#include "DataModel/PartInstance.h"
|
#include "PartInstance.h"
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
@@ -11,7 +11,7 @@ PartInstance::PartInstance(void) : _bevelSize(0.07f), _parseVert(0), _debugTimer
|
|||||||
name = "Unnamed PVItem";
|
name = "Unnamed PVItem";
|
||||||
className = "Part";
|
className = "Part";
|
||||||
canCollide = true;
|
canCollide = true;
|
||||||
anchored = false;
|
anchored = true;
|
||||||
size = Vector3(2,1,4);
|
size = Vector3(2,1,4);
|
||||||
setCFrame(CoordinateFrame(Vector3(0,0,0)));
|
setCFrame(CoordinateFrame(Vector3(0,0,0)));
|
||||||
color = Color3::gray();
|
color = Color3::gray();
|
||||||
@@ -26,25 +26,6 @@ PartInstance::PartInstance(void) : _bevelSize(0.07f), _parseVert(0), _debugTimer
|
|||||||
shape = Enum::Shape::Block;
|
shape = Enum::Shape::Block;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
Vector3 PartInstance::getVelocity()
|
|
||||||
{
|
|
||||||
return velocity;
|
|
||||||
}
|
|
||||||
Vector3 PartInstance::getRotVelocity()
|
|
||||||
{
|
|
||||||
return rotVelocity;
|
|
||||||
}
|
|
||||||
|
|
||||||
void PartInstance::setVelocity(Vector3 v)
|
|
||||||
{
|
|
||||||
velocity = v;
|
|
||||||
}
|
|
||||||
void PartInstance::setRotVelocity(Vector3 v)
|
|
||||||
{
|
|
||||||
rotVelocity = v;
|
|
||||||
}
|
|
||||||
|
|
||||||
void PartInstance::postRender(RenderDevice *rd)
|
void PartInstance::postRender(RenderDevice *rd)
|
||||||
{
|
{
|
||||||
if(!nameShown)
|
if(!nameShown)
|
||||||
@@ -76,31 +57,6 @@ void PartInstance::postRender(RenderDevice *rd)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void PartInstance::setParent(Instance* prnt)
|
|
||||||
{
|
|
||||||
Instance * cparent = getParent();
|
|
||||||
while(cparent != NULL)
|
|
||||||
{
|
|
||||||
if(WorkspaceInstance* workspace = dynamic_cast<WorkspaceInstance*>(cparent))
|
|
||||||
{
|
|
||||||
std::cout << "Removed from partarray " << std::endl;
|
|
||||||
workspace->partObjects.erase(std::remove(workspace->partObjects.begin(), workspace->partObjects.end(), this), workspace->partObjects.end());
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
cparent = cparent->getParent();
|
|
||||||
}
|
|
||||||
Instance::setParent(prnt);
|
|
||||||
while(parent != NULL)
|
|
||||||
{
|
|
||||||
if(WorkspaceInstance* workspace = dynamic_cast<WorkspaceInstance*>(parent))
|
|
||||||
{
|
|
||||||
workspace->partObjects.push_back(this);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
parent = parent->getParent();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
PartInstance::PartInstance(const PartInstance &oinst) : _bevelSize(0.07f), _parseVert(0), _debugTimer(0)
|
PartInstance::PartInstance(const PartInstance &oinst) : _bevelSize(0.07f), _parseVert(0), _debugTimer(0)
|
||||||
{
|
{
|
||||||
PVInstance::PVInstance(oinst);
|
PVInstance::PVInstance(oinst);
|
||||||
@@ -189,7 +145,7 @@ void PartInstance::setShape(Enum::Shape::Value shape)
|
|||||||
void PartInstance::setPosition(Vector3 pos)
|
void PartInstance::setPosition(Vector3 pos)
|
||||||
{
|
{
|
||||||
position = pos;
|
position = pos;
|
||||||
cFrame = CoordinateFrame(cFrame.rotation, pos);
|
cFrame = CoordinateFrame(pos);
|
||||||
changed = true;
|
changed = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -206,27 +162,8 @@ void PartInstance::setCFrame(CoordinateFrame coordinateFrame)
|
|||||||
// Can probably be deleted
|
// Can probably be deleted
|
||||||
CoordinateFrame PartInstance::getCFrameRenderBased()
|
CoordinateFrame PartInstance::getCFrameRenderBased()
|
||||||
{
|
{
|
||||||
return cFrame;//CoordinateFrame(getCFrame().rotation,Vector3(getCFrame().translation.x, getCFrame().translation.y, getCFrame().translation.z));
|
return CoordinateFrame(getCFrame().rotation,Vector3(getCFrame().translation.x, getCFrame().translation.y, getCFrame().translation.z));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool PartInstance::collides(PartInstance * part)
|
|
||||||
{
|
|
||||||
if(shape == Enum::Shape::Block)
|
|
||||||
{
|
|
||||||
if(part->shape == Enum::Shape::Block)
|
|
||||||
return G3D::CollisionDetection::fixedSolidBoxIntersectsFixedSolidBox(getBox(), part->getBox());
|
|
||||||
else
|
|
||||||
return G3D::CollisionDetection::fixedSolidSphereIntersectsFixedSolidBox(part->getSphere(), getBox());
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if(part->shape == Enum::Shape::Block)
|
|
||||||
return G3D::CollisionDetection::fixedSolidSphereIntersectsFixedSolidBox(getSphere(), part->getBox());
|
|
||||||
else
|
|
||||||
return G3D::CollisionDetection::fixedSolidSphereIntersectsFixedSolidSphere(getSphere(), part->getSphere());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef NEW_BOX_RENDER
|
#ifdef NEW_BOX_RENDER
|
||||||
Box PartInstance::getBox()
|
Box PartInstance::getBox()
|
||||||
{
|
{
|
||||||
@@ -235,13 +172,6 @@ Box PartInstance::getBox()
|
|||||||
itemBox = c.toWorldSpace(box);
|
itemBox = c.toWorldSpace(box);
|
||||||
return itemBox;
|
return itemBox;
|
||||||
}
|
}
|
||||||
Sphere PartInstance::getSphere()
|
|
||||||
{
|
|
||||||
Sphere sphere = Sphere(Vector3(0,0,0), size.y/2);
|
|
||||||
CoordinateFrame c = getCFrameRenderBased();
|
|
||||||
//itemBox = c.toWorldSpace(Sphere);
|
|
||||||
return sphere;//itemBox;
|
|
||||||
}
|
|
||||||
#else
|
#else
|
||||||
Box PartInstance::getBox()
|
Box PartInstance::getBox()
|
||||||
{
|
{
|
||||||
@@ -314,36 +244,22 @@ void PartInstance::addVertex(Vector3 vertexPos,Color3 color)
|
|||||||
addSingularNormal(cross(v1-v3,v2-v3).direction());
|
addSingularNormal(cross(v1-v3,v2-v3).direction());
|
||||||
}
|
}
|
||||||
|
|
||||||
void PartInstance::addQuad(Vector3 v1,Vector3 v2, Vector3 v3, Vector3 v4)
|
void PartInstance::addSmoothTriangle(Vector3 v1,Vector3 v2,Vector3 v3)
|
||||||
{
|
|
||||||
addTriangle(v1, v2, v3);
|
|
||||||
addTriangle(v1, v3, v4);
|
|
||||||
}
|
|
||||||
|
|
||||||
void PartInstance::genSmoothNormals(int count = -1)
|
|
||||||
{
|
|
||||||
if(count < 0)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void PartInstance::addSmoothTriangle(Vector3 v1, Vector3 v2, Vector3 v3)
|
|
||||||
{
|
{
|
||||||
addVertex(v1,color);
|
addVertex(v1,color);
|
||||||
addVertex(v2,color);
|
addVertex(v2,color);
|
||||||
addVertex(v3,color);
|
addVertex(v3,color);
|
||||||
//addNormals(cross(v2-v1,v3-v1).direction());
|
//addNormals(cross(v2-v1,v3-v1).direction());
|
||||||
//addSingularNormal(Vector3(cross(v2-v1,v3-v1) + cross(v3-v2,v1-v2) + cross(v1-v3,v2-v3)).direction());
|
|
||||||
addSingularNormal(v1.direction());
|
addSingularNormal(cross(v2-v1,v3-v1).direction());
|
||||||
addSingularNormal(v2.direction());
|
addSingularNormal(cross(v3-v2,v1-v2).direction());
|
||||||
addSingularNormal(v3.direction());
|
addSingularNormal(cross(v1-v3,v2-v3).direction());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void PartInstance::addPlus(Vector3 v1)
|
void PartInstance::addPlus(Vector3 v1)
|
||||||
{
|
{
|
||||||
float renderY = max(size.z, max(size.x, size.y))/2 * 0.775;
|
float renderY = size.y/2 - 0.25f;
|
||||||
Vector3 vx1 = v1 + Vector3(0, -renderY, -0.1f);
|
Vector3 vx1 = v1 + Vector3(0, -renderY, -0.1f);
|
||||||
Vector3 vx2 = v1 + Vector3(0, -renderY, 0.1f);
|
Vector3 vx2 = v1 + Vector3(0, -renderY, 0.1f);
|
||||||
Vector3 vx3 = v1 + Vector3(0, renderY, 0.1f);
|
Vector3 vx3 = v1 + Vector3(0, renderY, 0.1f);
|
||||||
@@ -397,7 +313,7 @@ void PartInstance::addPlus(Vector3 v1)
|
|||||||
|
|
||||||
void PartInstance::addPlus2(Vector3 v1)
|
void PartInstance::addPlus2(Vector3 v1)
|
||||||
{
|
{
|
||||||
float renderY = max(size.z, max(size.x, size.y))/2 * 0.775;
|
float renderY = max(size.z, max(size.x, size.y))/2 - 0.25f;
|
||||||
Vector3 vx3 = v1 + Vector3(0, -renderY, -0.1f);
|
Vector3 vx3 = v1 + Vector3(0, -renderY, -0.1f);
|
||||||
Vector3 vx2 = v1 + Vector3(0, -renderY, 0.1f);
|
Vector3 vx2 = v1 + Vector3(0, -renderY, 0.1f);
|
||||||
Vector3 vx1 = v1 + Vector3(0, renderY, 0.1f);
|
Vector3 vx1 = v1 + Vector3(0, renderY, 0.1f);
|
||||||
@@ -471,19 +387,6 @@ void PartInstance::addPlus2(Vector3 v1)
|
|||||||
addTriangle(Vector3(_vertices[vertex1],_vertices[vertex1+1],_vertices[vertex1+2]),
|
addTriangle(Vector3(_vertices[vertex1],_vertices[vertex1+1],_vertices[vertex1+2]),
|
||||||
Vector3(_vertices[vertex2],_vertices[vertex2+1],_vertices[vertex2+2]),
|
Vector3(_vertices[vertex2],_vertices[vertex2+1],_vertices[vertex2+2]),
|
||||||
Vector3(_vertices[vertex3],_vertices[vertex3+1],_vertices[vertex3+2]));
|
Vector3(_vertices[vertex3],_vertices[vertex3+1],_vertices[vertex3+2]));
|
||||||
}
|
|
||||||
void PartInstance::fromArrays(float verts[], float norms[], float ind[], unsigned int countVN, unsigned int countInd)
|
|
||||||
{
|
|
||||||
for(unsigned int i = 0; i < countVN; i++)
|
|
||||||
{
|
|
||||||
_vertices.push_back(verts[i]);
|
|
||||||
_normals.push_back(norms[i]);
|
|
||||||
}
|
|
||||||
for(unsigned int i = 0; i < countInd; i++)
|
|
||||||
{
|
|
||||||
_indices.push_back(ind[i]);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
void PartInstance::makeSmoothFace(int vertex1,int vertex2, int vertex3)
|
void PartInstance::makeSmoothFace(int vertex1,int vertex2, int vertex3)
|
||||||
{
|
{
|
||||||
@@ -502,12 +405,8 @@ bool PartInstance::isUniqueVertex(Vector3 pos)
|
|||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
//int rings = 15;
|
|
||||||
//int sectors = 15;
|
|
||||||
void PartInstance::render(RenderDevice* rd) {
|
void PartInstance::render(RenderDevice* rd) {
|
||||||
int sectorCount = 12;
|
|
||||||
int stackCount = 12;
|
|
||||||
float radius = 0.5F;
|
|
||||||
//if(nameShown)
|
//if(nameShown)
|
||||||
//postRenderStack.push_back(this);
|
//postRenderStack.push_back(this);
|
||||||
if (changed)
|
if (changed)
|
||||||
@@ -523,17 +422,122 @@ void PartInstance::render(RenderDevice* rd) {
|
|||||||
{
|
{
|
||||||
case Enum::Shape::Ball:
|
case Enum::Shape::Ball:
|
||||||
{
|
{
|
||||||
glNewList(glList, GL_COMPILE);
|
int obv = _bevelSize;
|
||||||
glColor(this->color);
|
_bevelSize = this->size.y / 3.14159F;
|
||||||
glPushMatrix();
|
// Front
|
||||||
glScalef(renderSize.x, renderSize.y, renderSize.z);
|
addSmoothTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,renderSize.z),
|
||||||
gluSphere(gluNewQuadric(), 1, 20, 20);
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,renderSize.z),
|
||||||
glPopMatrix();
|
Vector3(renderSize.x-_bevelSize,-renderSize.y+_bevelSize,renderSize.z)
|
||||||
glEndList();
|
);
|
||||||
rd->setObjectToWorldMatrix(cFrame);
|
|
||||||
glCallList(glList);
|
addSmoothTriangle(Vector3(-renderSize.x+_bevelSize,renderSize.y-_bevelSize,renderSize.z),
|
||||||
changed = false;
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,renderSize.z),
|
||||||
return;
|
Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,renderSize.z)
|
||||||
|
);
|
||||||
|
|
||||||
|
// Top
|
||||||
|
addSmoothTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y,renderSize.z-_bevelSize),
|
||||||
|
Vector3(renderSize.x-_bevelSize,renderSize.y,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(-renderSize.x+_bevelSize,renderSize.y,renderSize.z-_bevelSize)
|
||||||
|
);
|
||||||
|
addSmoothTriangle(Vector3(-renderSize.x+_bevelSize,renderSize.y,renderSize.z-_bevelSize),
|
||||||
|
Vector3(renderSize.x-_bevelSize,renderSize.y,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(-renderSize.x+_bevelSize,renderSize.y,-renderSize.z+_bevelSize)
|
||||||
|
);
|
||||||
|
|
||||||
|
// Back
|
||||||
|
addSmoothTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,-renderSize.z),
|
||||||
|
Vector3(renderSize.x-_bevelSize,-renderSize.y+_bevelSize,-renderSize.z),
|
||||||
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,-renderSize.z)
|
||||||
|
);
|
||||||
|
addSmoothTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,-renderSize.z),
|
||||||
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,-renderSize.z),
|
||||||
|
Vector3(-renderSize.x+_bevelSize,renderSize.y-_bevelSize,-renderSize.z)
|
||||||
|
);
|
||||||
|
|
||||||
|
// Bottom
|
||||||
|
addSmoothTriangle(Vector3(renderSize.x-_bevelSize,-renderSize.y,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(renderSize.x-_bevelSize,-renderSize.y,renderSize.z-_bevelSize),
|
||||||
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y,renderSize.z-_bevelSize)
|
||||||
|
);
|
||||||
|
addSmoothTriangle(Vector3(-renderSize.x+_bevelSize,-renderSize.y,renderSize.z-_bevelSize),
|
||||||
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(renderSize.x-_bevelSize,-renderSize.y,-renderSize.z+_bevelSize)
|
||||||
|
);
|
||||||
|
// Left
|
||||||
|
addSmoothTriangle(Vector3(-renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(-renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize),
|
||||||
|
Vector3(-renderSize.x,renderSize.y-_bevelSize,renderSize.z-_bevelSize)
|
||||||
|
);
|
||||||
|
addSmoothTriangle(Vector3(-renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize),
|
||||||
|
Vector3(-renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(-renderSize.x,-renderSize.y+_bevelSize,-renderSize.z+_bevelSize)
|
||||||
|
);
|
||||||
|
|
||||||
|
// Right
|
||||||
|
addSmoothTriangle(Vector3(renderSize.x,renderSize.y-_bevelSize,renderSize.z-_bevelSize),
|
||||||
|
Vector3(renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize),
|
||||||
|
Vector3(renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize)
|
||||||
|
);
|
||||||
|
addSmoothTriangle(Vector3(renderSize.x,-renderSize.y+_bevelSize,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize)
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
// Bevel Top Front
|
||||||
|
makeSmoothFace(0,36,48);
|
||||||
|
makeSmoothFace(48,18,0);
|
||||||
|
// Bevel Left Front Corner
|
||||||
|
makeSmoothFace(18,156,162);
|
||||||
|
makeSmoothFace(24,18,162);
|
||||||
|
// Bevel Left Front Top Corner
|
||||||
|
makeSmoothFace(48,156,18);
|
||||||
|
// Bevel Left Front Bottom Corner
|
||||||
|
makeSmoothFace(120,6,150);
|
||||||
|
// Bevel Left Top
|
||||||
|
makeSmoothFace(48,66,156);
|
||||||
|
makeSmoothFace(144,156,66);
|
||||||
|
// Bevel Bottom
|
||||||
|
makeSmoothFace(6,120,114);
|
||||||
|
makeSmoothFace(114,12,6);
|
||||||
|
// Left Bottom
|
||||||
|
makeSmoothFace(120,150,174);
|
||||||
|
makeSmoothFace(174,132,120);
|
||||||
|
// Right Front Top Corner
|
||||||
|
makeSmoothFace(36,0,180);
|
||||||
|
// Right Front Corner
|
||||||
|
makeSmoothFace(180,0,12);
|
||||||
|
makeSmoothFace(186,180,12);
|
||||||
|
// Right Front Bottom Corner
|
||||||
|
makeSmoothFace(186,12,114);
|
||||||
|
// Right Bottom
|
||||||
|
makeSmoothFace(186,114,108);
|
||||||
|
makeSmoothFace(108,198,186);
|
||||||
|
// Right Top Corner
|
||||||
|
makeSmoothFace(180,192,36);
|
||||||
|
makeSmoothFace(192,42,36);
|
||||||
|
// Right Back Top Corner
|
||||||
|
makeSmoothFace(72,42,192);
|
||||||
|
// Right Back Bottom Corner
|
||||||
|
makeSmoothFace(78,198,108);
|
||||||
|
// Right Back Corner
|
||||||
|
makeSmoothFace(72,192,198);
|
||||||
|
makeSmoothFace(198,78,72);
|
||||||
|
// Back Bottom Corner
|
||||||
|
makeSmoothFace(78,108,132);
|
||||||
|
makeSmoothFace(132,84,78);
|
||||||
|
// Back Top
|
||||||
|
makeSmoothFace(42,72,102);
|
||||||
|
makeSmoothFace(102,66,42);
|
||||||
|
// Back Left Top Corner
|
||||||
|
makeSmoothFace(144,66,102);
|
||||||
|
// Back Left Corner
|
||||||
|
makeSmoothFace(144,102,84);
|
||||||
|
makeSmoothFace(84,174,144);
|
||||||
|
// Back Left Bottom Corner
|
||||||
|
makeSmoothFace(174,84,132);
|
||||||
|
_bevelSize = obv;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case Enum::Shape::Block:
|
case Enum::Shape::Block:
|
||||||
@@ -651,76 +655,71 @@ void PartInstance::render(RenderDevice* rd) {
|
|||||||
makeFace(84,174,144);
|
makeFace(84,174,144);
|
||||||
// Back Left Bottom Corner
|
// Back Left Bottom Corner
|
||||||
makeFace(174,84,132);
|
makeFace(174,84,132);
|
||||||
for (unsigned short i=0;i<_vertices.size()/6;i++) {
|
|
||||||
_indices.push_back(i);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case Enum::Shape::Cylinder:
|
case Enum::Shape::Cylinder:
|
||||||
{
|
{
|
||||||
/*int fsize = renderSize.y/(pi()/2);
|
|
||||||
//makeFace(0,0,48);
|
|
||||||
// Front
|
// Front
|
||||||
addTriangle(Vector3(renderSize.x,renderSize.y-fsize,renderSize.z),
|
addTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,renderSize.z),
|
||||||
Vector3(-renderSize.x,-renderSize.y+fsize,renderSize.z),
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,renderSize.z),
|
||||||
Vector3(renderSize.x,-renderSize.y+fsize,renderSize.z)
|
Vector3(renderSize.x-_bevelSize,-renderSize.y+_bevelSize,renderSize.z)
|
||||||
);
|
);
|
||||||
|
|
||||||
addTriangle(Vector3(-renderSize.x,renderSize.y-fsize,renderSize.z),
|
addTriangle(Vector3(-renderSize.x+_bevelSize,renderSize.y-_bevelSize,renderSize.z),
|
||||||
Vector3(-renderSize.x,-renderSize.y+fsize,renderSize.z),
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,renderSize.z),
|
||||||
Vector3(renderSize.x,renderSize.y-fsize,renderSize.z)
|
Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,renderSize.z)
|
||||||
);
|
);
|
||||||
|
|
||||||
// Top
|
// Top
|
||||||
addTriangle(Vector3(renderSize.x,renderSize.y,renderSize.z-fsize),
|
addTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y,renderSize.z-_bevelSize),
|
||||||
Vector3(renderSize.x,renderSize.y,-renderSize.z+fsize),
|
Vector3(renderSize.x-_bevelSize,renderSize.y,-renderSize.z+_bevelSize),
|
||||||
Vector3(-renderSize.x,renderSize.y,renderSize.z-fsize)
|
Vector3(-renderSize.x+_bevelSize,renderSize.y,renderSize.z-_bevelSize)
|
||||||
);
|
);
|
||||||
addTriangle(Vector3(-renderSize.x,renderSize.y,renderSize.z-fsize),
|
addTriangle(Vector3(-renderSize.x+_bevelSize,renderSize.y,renderSize.z-_bevelSize),
|
||||||
Vector3(renderSize.x,renderSize.y,-renderSize.z+fsize),
|
Vector3(renderSize.x-_bevelSize,renderSize.y,-renderSize.z+_bevelSize),
|
||||||
Vector3(-renderSize.x,renderSize.y,-renderSize.z+fsize)
|
Vector3(-renderSize.x+_bevelSize,renderSize.y,-renderSize.z+_bevelSize)
|
||||||
);
|
);
|
||||||
|
|
||||||
// Back
|
// Back
|
||||||
addTriangle(Vector3(renderSize.x,renderSize.y-fsize,-renderSize.z),
|
addTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,-renderSize.z),
|
||||||
Vector3(renderSize.x,-renderSize.y+fsize,-renderSize.z),
|
Vector3(renderSize.x-_bevelSize,-renderSize.y+_bevelSize,-renderSize.z),
|
||||||
Vector3(-renderSize.x,-renderSize.y+fsize,-renderSize.z)
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,-renderSize.z)
|
||||||
);
|
);
|
||||||
addTriangle(Vector3(renderSize.x,renderSize.y-fsize,-renderSize.z),
|
addTriangle(Vector3(renderSize.x-_bevelSize,renderSize.y-_bevelSize,-renderSize.z),
|
||||||
Vector3(-renderSize.x,-renderSize.y+fsize,-renderSize.z),
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y+_bevelSize,-renderSize.z),
|
||||||
Vector3(-renderSize.x,renderSize.y-fsize,-renderSize.z)
|
Vector3(-renderSize.x+_bevelSize,renderSize.y-_bevelSize,-renderSize.z)
|
||||||
);
|
);
|
||||||
|
|
||||||
// Bottom
|
// Bottom
|
||||||
addTriangle(Vector3(renderSize.x,-renderSize.y,-renderSize.z+fsize),
|
addTriangle(Vector3(renderSize.x-_bevelSize,-renderSize.y,-renderSize.z+_bevelSize),
|
||||||
Vector3(renderSize.x,-renderSize.y,renderSize.z-fsize),
|
Vector3(renderSize.x-_bevelSize,-renderSize.y,renderSize.z-_bevelSize),
|
||||||
Vector3(-renderSize.x,-renderSize.y,renderSize.z-fsize)
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y,renderSize.z-_bevelSize)
|
||||||
);
|
);
|
||||||
addTriangle(Vector3(-renderSize.x,-renderSize.y,renderSize.z-fsize),
|
addTriangle(Vector3(-renderSize.x+_bevelSize,-renderSize.y,renderSize.z-_bevelSize),
|
||||||
Vector3(-renderSize.x,-renderSize.y,-renderSize.z+fsize),
|
Vector3(-renderSize.x+_bevelSize,-renderSize.y,-renderSize.z+_bevelSize),
|
||||||
Vector3(renderSize.x,-renderSize.y,-renderSize.z+fsize)
|
Vector3(renderSize.x-_bevelSize,-renderSize.y,-renderSize.z+_bevelSize)
|
||||||
);
|
);
|
||||||
// Left
|
// Left
|
||||||
/*addTriangle(Vector3(-renderSize.x,renderSize.y-fsize,-renderSize.z+fsize),
|
addTriangle(Vector3(-renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize),
|
||||||
Vector3(-renderSize.x,-renderSize.y+fsize,renderSize.z-fsize),
|
Vector3(-renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize),
|
||||||
Vector3(-renderSize.x,renderSize.y-fsize,renderSize.z-fsize)
|
Vector3(-renderSize.x,renderSize.y-_bevelSize,renderSize.z-_bevelSize)
|
||||||
);
|
);
|
||||||
addTriangle(Vector3(-renderSize.x,-renderSize.y+fsize,renderSize.z-fsize),
|
addTriangle(Vector3(-renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize),
|
||||||
Vector3(-renderSize.x,renderSize.y-fsize,-renderSize.z+fsize),
|
Vector3(-renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize),
|
||||||
Vector3(-renderSize.x,-renderSize.y+fsize,-renderSize.z+fsize)
|
Vector3(-renderSize.x,-renderSize.y+_bevelSize,-renderSize.z+_bevelSize)
|
||||||
);
|
);
|
||||||
// Right
|
// Right
|
||||||
addTriangle(Vector3(renderSize.x,renderSize.y-fsize,renderSize.z-fsize),
|
addTriangle(Vector3(renderSize.x,renderSize.y-_bevelSize,renderSize.z-_bevelSize),
|
||||||
Vector3(renderSize.x,-renderSize.y+fsize,renderSize.z-fsize),
|
Vector3(renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize),
|
||||||
Vector3(renderSize.x,renderSize.y-fsize,-renderSize.z+fsize)
|
Vector3(renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize)
|
||||||
|
);
|
||||||
|
addTriangle(Vector3(renderSize.x,-renderSize.y+_bevelSize,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(renderSize.x,renderSize.y-_bevelSize,-renderSize.z+_bevelSize),
|
||||||
|
Vector3(renderSize.x,-renderSize.y+_bevelSize,renderSize.z-_bevelSize)
|
||||||
);
|
);
|
||||||
addTriangle(Vector3(renderSize.x,-renderSize.y+fsize,-renderSize.z+fsize),
|
|
||||||
Vector3(renderSize.x,renderSize.y-fsize,-renderSize.z+fsize),
|
|
||||||
Vector3(renderSize.x,-renderSize.y+fsize,renderSize.z-fsize)
|
|
||||||
);//*/
|
|
||||||
|
|
||||||
|
|
||||||
/*// Bevel Top Front
|
// Bevel Top Front
|
||||||
makeFace(0,36,48);
|
makeFace(0,36,48);
|
||||||
makeFace(48,18,0);
|
makeFace(48,18,0);
|
||||||
// Bevel Left Front Corner
|
// Bevel Left Front Corner
|
||||||
@@ -771,112 +770,29 @@ void PartInstance::render(RenderDevice* rd) {
|
|||||||
makeFace(144,102,84);
|
makeFace(144,102,84);
|
||||||
makeFace(84,174,144);
|
makeFace(84,174,144);
|
||||||
// Back Left Bottom Corner
|
// Back Left Bottom Corner
|
||||||
makeFace(174,84,132);*/
|
makeFace(174,84,132);
|
||||||
/*float radius = renderSize.y + (renderSize.y * (1 - cos(pi() / 12)));
|
|
||||||
Vector2 xy[13];
|
|
||||||
for(int i = 0; i < 13; i++)
|
|
||||||
{
|
|
||||||
//Get the next point
|
|
||||||
float y = radius * cos(((double)i-G3D::toRadians(29)) * pi()/6);
|
|
||||||
float z = radius * sin(((double)i-G3D::toRadians(29)) * pi()/6);
|
|
||||||
xy[i] = Vector2(y,z);
|
|
||||||
}
|
|
||||||
for(int i = 0; i < 12; i++)
|
|
||||||
{
|
|
||||||
//Create a Quad for the face (i to i+1)
|
|
||||||
addSmoothTriangle(
|
|
||||||
Vector3(renderSize.x, xy[i].x, xy[i].y),
|
|
||||||
Vector3(-renderSize.x, xy[i].x, xy[i].y),
|
|
||||||
Vector3(-renderSize.x, xy[i+1].x, xy[i+1].y));
|
|
||||||
addSmoothTriangle(
|
|
||||||
Vector3(renderSize.x, xy[i].x, xy[i].y),
|
|
||||||
Vector3(-renderSize.x, xy[i+1].x, xy[i+1].y),
|
|
||||||
Vector3(renderSize.x, xy[i+1].x, xy[i+1].y));
|
|
||||||
//Cap on the right
|
|
||||||
addTriangle(
|
|
||||||
Vector3(renderSize.x, xy[0].x, xy[0].y),
|
|
||||||
Vector3(renderSize.x, xy[i].x, xy[i].y),
|
|
||||||
Vector3(renderSize.x, xy[i+1].x, xy[i+1].y));
|
|
||||||
//Cap on the left
|
|
||||||
addTriangle(
|
|
||||||
Vector3(-renderSize.x, xy[i+1].x, xy[i+1].y),
|
|
||||||
Vector3(-renderSize.x, xy[i].x, xy[i].y),
|
|
||||||
Vector3(-renderSize.x, xy[0].x, xy[0].y));
|
|
||||||
}*/
|
|
||||||
/*float facetRatio = renderSize.x / (pi() * 0.5F);
|
|
||||||
addQuad(
|
|
||||||
Vector3(renderSize.x, renderSize.y, renderSize.z-facetRatio),
|
|
||||||
Vector3(renderSize.x, renderSize.y, -renderSize.z+facetRatio),
|
|
||||||
Vector3(-renderSize.x, renderSize.y, -renderSize.z+facetRatio),
|
|
||||||
Vector3(-renderSize.x, renderSize.y, renderSize.z-facetRatio));
|
|
||||||
|
|
||||||
addQuad(
|
addPlus(Vector3(-renderSize.x-0.01,0,0));
|
||||||
Vector3(renderSize.x, renderSize.y-facetRatio, renderSize.z),
|
|
||||||
Vector3(-renderSize.x, renderSize.y-facetRatio, renderSize.z),
|
|
||||||
Vector3(-renderSize.x, -renderSize.y+facetRatio, renderSize.z),
|
|
||||||
Vector3(renderSize.x, -renderSize.y+facetRatio, renderSize.z));
|
|
||||||
addQuad(
|
|
||||||
Vector3(-renderSize.x, -renderSize.y, renderSize.z-facetRatio),
|
|
||||||
Vector3(-renderSize.x, -renderSize.y, -renderSize.z+facetRatio),
|
|
||||||
Vector3(renderSize.x, -renderSize.y, -renderSize.z+facetRatio),
|
|
||||||
Vector3(renderSize.x, -renderSize.y, renderSize.z-facetRatio));
|
|
||||||
addQuad(
|
|
||||||
Vector3(renderSize.x, -renderSize.y+facetRatio, -renderSize.z),
|
|
||||||
Vector3(-renderSize.x, -renderSize.y+facetRatio, -renderSize.z),
|
|
||||||
Vector3(-renderSize.x, renderSize.y-facetRatio, -renderSize.z),
|
|
||||||
Vector3(renderSize.x, renderSize.y-facetRatio, -renderSize.z));*/
|
|
||||||
|
|
||||||
/*addPlus(Vector3(-renderSize.x-0.01,0,0));
|
|
||||||
addPlus2(Vector3(renderSize.x+0.01,0,0));
|
addPlus2(Vector3(renderSize.x+0.01,0,0));
|
||||||
|
|
||||||
for (unsigned short i=0;i<_vertices.size()/6;i++) {
|
|
||||||
_indices.push_back(i);
|
|
||||||
}
|
|
||||||
//std::reverse(_vertices.begin(), _vertices.end());
|
|
||||||
//std::reverse(_normals.begin(), _normals.end());
|
|
||||||
)*/
|
|
||||||
GLUquadric* q = gluNewQuadric();
|
|
||||||
|
|
||||||
addPlus(Vector3(-renderSize.x-0.01,0,0));
|
|
||||||
addPlus2(Vector3(renderSize.x+0.01,0,0));
|
|
||||||
for (unsigned short i=0;i<_vertices.size()/6;i++) {
|
|
||||||
_indices.push_back(i);
|
|
||||||
}
|
|
||||||
glVertexPointer(3, GL_FLOAT,6 * sizeof(GLfloat), &_vertices[0]);
|
|
||||||
glColorPointer(3, GL_FLOAT,6 * sizeof(GLfloat), &_vertices[3]);
|
|
||||||
glNormalPointer(GL_FLOAT,3 * sizeof(GLfloat), &_normals[0]);
|
|
||||||
glNewList(glList, GL_COMPILE);
|
|
||||||
glColor(this->color);
|
|
||||||
glPushMatrix();
|
|
||||||
glRotatef(90, 0, 1, 0);
|
|
||||||
glScalef(renderSize.x, renderSize.y, renderSize.z);
|
|
||||||
glTranslatef(0,0,1);
|
|
||||||
gluDisk(q, 0, 1, 12, 12);
|
|
||||||
glTranslatef(0,0,-2);
|
|
||||||
gluCylinder(q, 1, 1, 2, 12, 1);
|
|
||||||
glRotatef(180, 1, 0, 0);
|
|
||||||
gluDisk(q, 0, 1, 12, 12);
|
|
||||||
glPopMatrix();
|
|
||||||
glDrawElements(GL_TRIANGLES, _indices.size(), GL_UNSIGNED_SHORT, &_indices[0]);
|
|
||||||
glEndList();
|
|
||||||
rd->setObjectToWorldMatrix(cFrame);
|
|
||||||
glCallList(glList);
|
|
||||||
changed = false;
|
|
||||||
return;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
for (unsigned short i=0;i<_vertices.size()/6;i++) {
|
||||||
|
_indices.push_back(i);
|
||||||
|
}
|
||||||
changed=false;
|
changed=false;
|
||||||
|
|
||||||
|
glNewList(glList, GL_COMPILE);
|
||||||
glVertexPointer(3, GL_FLOAT,6 * sizeof(GLfloat), &_vertices[0]);
|
glVertexPointer(3, GL_FLOAT,6 * sizeof(GLfloat), &_vertices[0]);
|
||||||
glColorPointer(3, GL_FLOAT,6 * sizeof(GLfloat), &_vertices[3]);
|
glColorPointer(3, GL_FLOAT,6 * sizeof(GLfloat), &_vertices[3]);
|
||||||
glNormalPointer(GL_FLOAT,3 * sizeof(GLfloat), &_normals[0]);
|
glNormalPointer(GL_FLOAT,3 * sizeof(GLfloat), &_normals[0]);
|
||||||
glNewList(glList, GL_COMPILE);
|
glPushMatrix();
|
||||||
//glPushMatrix();
|
|
||||||
//glTranslatef(2,7,0);
|
//glTranslatef(2,7,0);
|
||||||
glDrawElements(GL_TRIANGLES, _indices.size(), GL_UNSIGNED_SHORT, &_indices[0]);
|
glDrawElements(GL_TRIANGLES, _indices.size(), GL_UNSIGNED_SHORT, &_indices[0]);
|
||||||
//glPopMatrix();
|
glPopMatrix();
|
||||||
glEndList();
|
glEndList();
|
||||||
}
|
}
|
||||||
rd->setObjectToWorldMatrix(cFrame);
|
rd->setObjectToWorldMatrix(cFrame);
|
||||||
@@ -993,7 +909,6 @@ static TCHAR* enumStr(int shape)
|
|||||||
case Enum::Shape::Cylinder:
|
case Enum::Shape::Cylinder:
|
||||||
return "Cylinder";
|
return "Cylinder";
|
||||||
}
|
}
|
||||||
return "Block";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void PartInstance::PropUpdate(LPPROPGRIDITEM &item)
|
void PartInstance::PropUpdate(LPPROPGRIDITEM &item)
|
||||||
@@ -1003,11 +918,6 @@ void PartInstance::PropUpdate(LPPROPGRIDITEM &item)
|
|||||||
color = Color3(GetRValue(item->lpCurValue)/255.0F,GetGValue(item->lpCurValue)/255.0F,GetBValue(item->lpCurValue)/255.0F);
|
color = Color3(GetRValue(item->lpCurValue)/255.0F,GetGValue(item->lpCurValue)/255.0F,GetBValue(item->lpCurValue)/255.0F);
|
||||||
changed=true;
|
changed=true;
|
||||||
}
|
}
|
||||||
if(strcmp(item->lpszPropName, "Anchored") == 0)
|
|
||||||
{
|
|
||||||
anchored= item->lpCurValue == TRUE;
|
|
||||||
changed=true;
|
|
||||||
}
|
|
||||||
else if(strcmp(item->lpszPropName, "Offset") == 0)
|
else if(strcmp(item->lpszPropName, "Offset") == 0)
|
||||||
{
|
{
|
||||||
std::string str = (LPTSTR)item->lpCurValue;
|
std::string str = (LPTSTR)item->lpCurValue;
|
||||||
@@ -1087,14 +997,8 @@ std::vector<PROPGRIDITEM> PartInstance::getProperties()
|
|||||||
RGB((color.r*255),(color.g*255),(color.b*255)),
|
RGB((color.r*255),(color.g*255),(color.b*255)),
|
||||||
PIT_COLOR
|
PIT_COLOR
|
||||||
));
|
));
|
||||||
properties.push_back(createPGI(
|
|
||||||
"Item",
|
sprintf_s(pto, "%g, %g, %g", cFrame.translation.x, cFrame.translation.y, cFrame.translation.z);
|
||||||
"Anchored",
|
|
||||||
"Whether the block can move or not",
|
|
||||||
(LPARAM)anchored,
|
|
||||||
PIT_CHECK
|
|
||||||
));
|
|
||||||
sprintf_s(pto, "%g, %g, %g", position.x, position.y, position.z);
|
|
||||||
properties.push_back(createPGI(
|
properties.push_back(createPGI(
|
||||||
"Item",
|
"Item",
|
||||||
"Offset",
|
"Offset",
|
||||||
@@ -1,23 +1,19 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "PVInstance.h"
|
#include "PVInstance.h"
|
||||||
#include "Enum.h"
|
#include "Enum.h"
|
||||||
#define _USE_MATH_DEFINES
|
|
||||||
#include <cmath>
|
#define NEW_BOX_RENDER
|
||||||
|
|
||||||
class PartInstance : public PVInstance
|
class PartInstance : public PVInstance
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
PartInstance(void);
|
PartInstance(void);
|
||||||
PartInstance(const PartInstance &oinst);
|
PartInstance(const PartInstance &oinst);
|
||||||
~PartInstance(void);
|
|
||||||
Instance* clone() const { return new PartInstance(*this); }
|
Instance* clone() const { return new PartInstance(*this); }
|
||||||
|
|
||||||
//Rendering
|
|
||||||
virtual void PartInstance::postRender(RenderDevice* rd);
|
virtual void PartInstance::postRender(RenderDevice* rd);
|
||||||
|
~PartInstance(void);
|
||||||
virtual void render(RenderDevice*);
|
virtual void render(RenderDevice*);
|
||||||
|
Vector3 velocity;
|
||||||
//Surfaces
|
|
||||||
Enum::SurfaceType::Value top;
|
Enum::SurfaceType::Value top;
|
||||||
Enum::SurfaceType::Value front;
|
Enum::SurfaceType::Value front;
|
||||||
Enum::SurfaceType::Value right;
|
Enum::SurfaceType::Value right;
|
||||||
@@ -25,52 +21,52 @@ public:
|
|||||||
Enum::SurfaceType::Value left;
|
Enum::SurfaceType::Value left;
|
||||||
Enum::SurfaceType::Value bottom;
|
Enum::SurfaceType::Value bottom;
|
||||||
Enum::Shape::Value shape;
|
Enum::Shape::Value shape;
|
||||||
|
CoordinateFrame cFrame;
|
||||||
//Variables
|
|
||||||
Color3 color;
|
Color3 color;
|
||||||
bool canCollide;
|
|
||||||
dBodyID physBody;
|
|
||||||
dGeomID physGeom[3];
|
|
||||||
|
|
||||||
//Getters
|
|
||||||
Vector3 getPosition();
|
Vector3 getPosition();
|
||||||
Vector3 getVelocity();
|
|
||||||
Vector3 getRotVelocity();
|
|
||||||
Vector3 getSize();
|
|
||||||
Box getBox();
|
|
||||||
Sphere getSphere();
|
|
||||||
Box getScaledBox();
|
|
||||||
CoordinateFrame getCFrame();
|
|
||||||
|
|
||||||
//Setters
|
|
||||||
void setParent(Instance* parent);
|
|
||||||
void setPosition(Vector3);
|
void setPosition(Vector3);
|
||||||
void setVelocity(Vector3);
|
CoordinateFrame getCFrame();
|
||||||
void setRotVelocity(Vector3);
|
|
||||||
void setCFrame(CoordinateFrame);
|
void setCFrame(CoordinateFrame);
|
||||||
void setCFrameNoSync(CoordinateFrame);
|
Box getBox();
|
||||||
|
Box getScaledBox();
|
||||||
|
CoordinateFrame getCFrameRenderBased();
|
||||||
|
Vector3 getSize();
|
||||||
void setSize(Vector3);
|
void setSize(Vector3);
|
||||||
void setShape(Enum::Shape::Value shape);
|
void setShape(Enum::Shape::Value shape);
|
||||||
void setChanged();
|
bool canCollide;
|
||||||
void setSurface(int face, Enum::SurfaceType::Value surface);
|
bool anchored;
|
||||||
void setAnchored(bool anchored);
|
Vector3 rotVelocity;
|
||||||
bool isAnchored();
|
|
||||||
float getMass();
|
|
||||||
|
|
||||||
//Collision
|
|
||||||
bool collides(PartInstance * part);
|
|
||||||
bool collides(Box);
|
bool collides(Box);
|
||||||
|
|
||||||
//Properties
|
|
||||||
virtual std::vector<PROPGRIDITEM> getProperties();
|
virtual std::vector<PROPGRIDITEM> getProperties();
|
||||||
virtual void PropUpdate(LPPROPGRIDITEM &pItem);
|
virtual void PropUpdate(LPPROPGRIDITEM &pItem);
|
||||||
|
#ifdef NEW_BOX_RENDER
|
||||||
|
void addVertex(Vector3 vertexPos,Color3 color);
|
||||||
|
void addNormals(Vector3 normal);
|
||||||
|
void addSingularNormal(Vector3 normal);
|
||||||
|
void addTriangle(Vector3 vertexPos,Vector3 vertexPos2, Vector3 vertexPos3);
|
||||||
|
void addSmoothTriangle(Vector3 vertexPos,Vector3 vertexPos2, Vector3 vertexPos3);
|
||||||
|
void makeSmoothFace(int vertex1, int vertex2, int vertex3);
|
||||||
|
void addPlus(Vector3 v1);
|
||||||
|
void addPlus2(Vector3 v1);
|
||||||
|
void debugPrintVertexIDs(RenderDevice* rd, GFontRef font, Matrix3 camRot);
|
||||||
|
void makeFace(int vertex1, int vertex2, int vertex3);
|
||||||
|
bool isUniqueVertex(Vector3 pos);
|
||||||
|
#endif
|
||||||
private:
|
private:
|
||||||
bool anchored;
|
|
||||||
Vector3 position;
|
Vector3 position;
|
||||||
Vector3 size;
|
Vector3 size;
|
||||||
Vector3 velocity;
|
float _bevelSize;
|
||||||
Vector3 rotVelocity;
|
int _parseVert;
|
||||||
|
int _debugTimer;
|
||||||
|
std::vector<Vector3> _debugUniqueVertices;
|
||||||
|
#ifdef NEW_BOX_RENDER
|
||||||
|
std::vector<GLfloat> _vertices;
|
||||||
|
std::vector<GLfloat> _normals;
|
||||||
|
#else
|
||||||
|
GLfloat _vertices[96];
|
||||||
|
#endif
|
||||||
|
std::vector<GLushort> _indices;
|
||||||
bool changed;
|
bool changed;
|
||||||
Box itemBox;
|
Box itemBox;
|
||||||
GLuint glList;
|
GLuint glList;
|
||||||
};
|
};
|
||||||
@@ -3,9 +3,15 @@
|
|||||||
#include "WindowFunctions.h"
|
#include "WindowFunctions.h"
|
||||||
#include "resource.h"
|
#include "resource.h"
|
||||||
#include "PropertyWindow.h"
|
#include "PropertyWindow.h"
|
||||||
|
#include "Globals.h"
|
||||||
#include "strsafe.h"
|
#include "strsafe.h"
|
||||||
#include "Application.h"
|
#include "Application.h"
|
||||||
|
|
||||||
|
/*typedef struct typPRGP {
|
||||||
|
Instance* instance; // Declare member types
|
||||||
|
Property ∝
|
||||||
|
} PRGP;*/
|
||||||
|
|
||||||
std::vector<PROPGRIDITEM> prop;
|
std::vector<PROPGRIDITEM> prop;
|
||||||
std::vector<Instance*> children;
|
std::vector<Instance*> children;
|
||||||
Instance * selectedInstance;
|
Instance * selectedInstance;
|
||||||
@@ -171,8 +177,8 @@ LRESULT CALLBACK PropProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
|
|||||||
int ItemIndex = SendMessage((HWND) lParam, (UINT) CB_GETCURSEL, (WPARAM) 0, (LPARAM) 0);
|
int ItemIndex = SendMessage((HWND) lParam, (UINT) CB_GETCURSEL, (WPARAM) 0, (LPARAM) 0);
|
||||||
CHAR ListItem[256];
|
CHAR ListItem[256];
|
||||||
SendMessage((HWND) lParam, (UINT) CB_GETLBTEXT, (WPARAM) ItemIndex, (LPARAM) ListItem);
|
SendMessage((HWND) lParam, (UINT) CB_GETLBTEXT, (WPARAM) ItemIndex, (LPARAM) ListItem);
|
||||||
g_dataModel->getSelectionService()->clearSelection();
|
propWind->ClearProperties();
|
||||||
g_dataModel->getSelectionService()->addSelected(children.at(ItemIndex));
|
g_usableApp->selectInstance(children.at(ItemIndex),propWind);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -202,18 +208,13 @@ LRESULT CALLBACK PropProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PropertyWindow::clearExplorer()
|
void PropertyWindow::refreshExplorer(Instance* selectedInstance)
|
||||||
{
|
{
|
||||||
SendMessage(_explorerComboBox,CB_RESETCONTENT,0,0);
|
|
||||||
SendMessage(_explorerComboBox,CB_SETCURSEL,0,(LPARAM)0);
|
|
||||||
}
|
|
||||||
|
|
||||||
void PropertyWindow::refreshExplorer(std::vector<Instance*> selectedInstances)
|
|
||||||
{
|
|
||||||
Instance * instance = selectedInstances[0];
|
|
||||||
SendMessage(_explorerComboBox,CB_RESETCONTENT,0,0);
|
SendMessage(_explorerComboBox,CB_RESETCONTENT,0,0);
|
||||||
parent = NULL;
|
parent = NULL;
|
||||||
children.clear();
|
children.clear();
|
||||||
|
//g_selectedInstances.clear();
|
||||||
|
//for (unsigned int i=0;i<g_selectedInstances.size();i++) {
|
||||||
children.push_back(selectedInstance);
|
children.push_back(selectedInstance);
|
||||||
SendMessage(_explorerComboBox, CB_ADDSTRING, 0, (LPARAM)selectedInstance->name.c_str());
|
SendMessage(_explorerComboBox, CB_ADDSTRING, 0, (LPARAM)selectedInstance->name.c_str());
|
||||||
if(selectedInstance->getParent() != NULL)
|
if(selectedInstance->getParent() != NULL)
|
||||||
@@ -225,6 +226,7 @@ void PropertyWindow::refreshExplorer(std::vector<Instance*> selectedInstances)
|
|||||||
parent = selectedInstance->getParent();
|
parent = selectedInstance->getParent();
|
||||||
children.push_back(selectedInstance->getParent());
|
children.push_back(selectedInstance->getParent());
|
||||||
}
|
}
|
||||||
|
//children = g_selectedInstances[i]->getChildren();
|
||||||
|
|
||||||
std::vector<Instance*> selectedChildren = selectedInstance->getChildren();
|
std::vector<Instance*> selectedChildren = selectedInstance->getChildren();
|
||||||
for(size_t z = 0; z < selectedChildren.size(); z++)
|
for(size_t z = 0; z < selectedChildren.size(); z++)
|
||||||
@@ -341,17 +343,11 @@ void PropertyWindow::_resize()
|
|||||||
SetWindowPos(_explorerComboBox, NULL, 0, 0, rect.right, 400, SWP_NOMOVE | SWP_NOZORDER | SWP_NOACTIVATE);
|
SetWindowPos(_explorerComboBox, NULL, 0, 0, rect.right, 400, SWP_NOMOVE | SWP_NOZORDER | SWP_NOACTIVATE);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PropertyWindow::UpdateSelected(std::vector<Instance *> instances)
|
void PropertyWindow::UpdateSelected(Instance * instance)
|
||||||
{
|
{
|
||||||
if(instances.size() <= 0)
|
|
||||||
{
|
|
||||||
ClearProperties();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
Instance * instance = instances[0];
|
|
||||||
PropGrid_ResetContent(_propGrid);
|
PropGrid_ResetContent(_propGrid);
|
||||||
prop = instance->getProperties();
|
prop = instance->getProperties();
|
||||||
//if (selectedInstance != instance)
|
if (selectedInstance != instance)
|
||||||
{
|
{
|
||||||
selectedInstance = instance;
|
selectedInstance = instance;
|
||||||
for(size_t i = 0; i < prop.size(); i++)
|
for(size_t i = 0; i < prop.size(); i++)
|
||||||
@@ -365,13 +361,12 @@ void PropertyWindow::UpdateSelected(std::vector<Instance *> instances)
|
|||||||
PropGrid_ExpandAllCatalogs(_propGrid);
|
PropGrid_ExpandAllCatalogs(_propGrid);
|
||||||
//SetWindowLongPtr(_propGrid,GWL_USERDATA,(LONG)this);
|
//SetWindowLongPtr(_propGrid,GWL_USERDATA,(LONG)this);
|
||||||
|
|
||||||
refreshExplorer(instances);
|
refreshExplorer(instance);
|
||||||
_resize();
|
_resize();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void PropertyWindow::ClearProperties()
|
void PropertyWindow::ClearProperties()
|
||||||
{
|
{
|
||||||
clearExplorer();
|
|
||||||
PropGrid_ResetContent(_propGrid);
|
PropGrid_ResetContent(_propGrid);
|
||||||
}
|
}
|
||||||
@@ -1,18 +1,17 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "DataModelV2/Instance.h"
|
#include "Instance.h"
|
||||||
|
|
||||||
class PropertyWindow {
|
class PropertyWindow {
|
||||||
public:
|
public:
|
||||||
PropertyWindow(int x, int y, int sx, int sy, HMODULE hThisInstance);
|
PropertyWindow(int x, int y, int sx, int sy, HMODULE hThisInstance);
|
||||||
bool onCreate(int x, int y, int sx, int sy, HMODULE hThisInstance);
|
bool onCreate(int x, int y, int sx, int sy, HMODULE hThisInstance);
|
||||||
void UpdateSelected(std::vector<Instance *> selection);
|
void UpdateSelected(Instance *);
|
||||||
void ClearProperties();
|
void ClearProperties();
|
||||||
void onResize();
|
void onResize();
|
||||||
void refreshExplorer(std::vector<Instance *> selection);
|
void refreshExplorer(Instance* selectedInstance);
|
||||||
HWND _hwndProp;
|
HWND _hwndProp;
|
||||||
private:
|
private:
|
||||||
HWND _propGrid;
|
HWND _propGrid;
|
||||||
HWND _explorerComboBox;
|
HWND _explorerComboBox;
|
||||||
void _resize();
|
void _resize();
|
||||||
void clearExplorer();
|
|
||||||
};
|
};
|
||||||
@@ -1,13 +1,13 @@
|
|||||||
#include "DataModelV2/BaseButtonInstance.h"
|
#include "BaseButtonInstance.h"
|
||||||
#include "Listener/RotateButtonListener.h"
|
#include "RotateButtonListener.h"
|
||||||
#include "Globals.h"
|
#include "Globals.h"
|
||||||
#include "AudioPlayer.h"
|
#include "AudioPlayer.h"
|
||||||
|
|
||||||
void RotateButtonListener::onButton1MouseClick(BaseButtonInstance* button)
|
void RotateButtonListener::onButton1MouseClick(BaseButtonInstance* button)
|
||||||
{
|
{
|
||||||
if(g_dataModel->getSelectionService()->getSelection().size() > 0)
|
if(g_selectedInstances.size() > 0)
|
||||||
{
|
{
|
||||||
Instance* selectedInstance = g_dataModel->getSelectionService()->getSelection()[0];
|
Instance* selectedInstance = g_selectedInstances.at(0);
|
||||||
AudioPlayer::playSound(clickSound);
|
AudioPlayer::playSound(clickSound);
|
||||||
if(PartInstance* part = dynamic_cast<PartInstance*>(selectedInstance))
|
if(PartInstance* part = dynamic_cast<PartInstance*>(selectedInstance))
|
||||||
{
|
{
|
||||||
9
ShapeRenderer.cpp
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
#include "ShapeRenderer.h"
|
||||||
|
|
||||||
|
ShapeRenderer::ShapeRenderer(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
ShapeRenderer::~ShapeRenderer(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
@@ -2,6 +2,7 @@
|
|||||||
#include <sstream>
|
#include <sstream>
|
||||||
#include "ErrorFunctions.h"
|
#include "ErrorFunctions.h"
|
||||||
#include "StringFunctions.h"
|
#include "StringFunctions.h"
|
||||||
|
#include <windows.h>
|
||||||
|
|
||||||
std::string Convert (float number)
|
std::string Convert (float number)
|
||||||
{
|
{
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
#include "DataModelV2/TextButtonInstance.h"
|
#include "TextButtonInstance.h"
|
||||||
|
|
||||||
|
|
||||||
TextButtonInstance::TextButtonInstance(void)
|
TextButtonInstance::TextButtonInstance(void)
|
||||||
@@ -98,7 +98,12 @@ void TextButtonInstance::drawObj(RenderDevice* rd, Vector2 mousePos, bool mouseD
|
|||||||
Draw::box(Box(point1, point2), rd, boxColorDn, boxOutlineColorDn);
|
Draw::box(Box(point1, point2), rd, boxColorDn, boxOutlineColorDn);
|
||||||
font->draw2D(rd, title, RelativeTo, textSize, textColorDn, textOutlineColorDn);
|
font->draw2D(rd, title, RelativeTo, textSize, textColorDn, textOutlineColorDn);
|
||||||
}
|
}
|
||||||
else if(selected || mouseInArea(point1.x, point1.y, point2.x, point2.y, mousePos.x, mousePos.y))
|
else if(mouseInArea(point1.x, point1.y, point2.x, point2.y, mousePos.x, mousePos.y))
|
||||||
|
{
|
||||||
|
Draw::box(Box(point1, point2), rd, boxColorOvr, boxOutlineColorOvr);
|
||||||
|
font->draw2D(rd, title, RelativeTo, textSize, textColorOvr, textOutlineColorOvr);
|
||||||
|
}
|
||||||
|
else if(selected)
|
||||||
{
|
{
|
||||||
Draw::box(Box(point1, point2), rd, boxColorOvr, boxOutlineColorOvr);
|
Draw::box(Box(point1, point2), rd, boxColorOvr, boxOutlineColorOvr);
|
||||||
font->draw2D(rd, title, RelativeTo, textSize, textColorOvr, textOutlineColorOvr);
|
font->draw2D(rd, title, RelativeTo, textSize, textColorOvr, textOutlineColorOvr);
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
|
|
||||||
#include "WindowFunctions.h"
|
#include "WindowFunctions.h"
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
#include <string>
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
@@ -23,7 +24,7 @@ bool createWindowClass(const char* name,WNDPROC proc,HMODULE hInstance)
|
|||||||
{
|
{
|
||||||
stringstream errMsg;
|
stringstream errMsg;
|
||||||
errMsg<<"Failed to register " << name;
|
errMsg<<"Failed to register " << name;
|
||||||
MessageBox(NULL, errMsg.str().c_str(),"Blocks3D Crash", MB_OK);
|
MessageBox(NULL, errMsg.str().c_str(),"Dynamica Crash", MB_OK);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
@@ -1,5 +1,4 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
|
||||||
|
|
||||||
bool createWindowClass(const char* name,WNDPROC proc,HMODULE hInstance);
|
bool createWindowClass(const char* name,WNDPROC proc,HMODULE hInstance);
|
||||||
23
WorkspaceInstance.cpp
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
#include "WorkspaceInstance.h"
|
||||||
|
|
||||||
|
|
||||||
|
WorkspaceInstance::WorkspaceInstance(void)
|
||||||
|
{
|
||||||
|
GroupInstance::GroupInstance();
|
||||||
|
name = "Workspace";
|
||||||
|
className = "Workspace";
|
||||||
|
canDelete = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
WorkspaceInstance::~WorkspaceInstance(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void WorkspaceInstance::removeFromPVector(PVInstance * instance)
|
||||||
|
{
|
||||||
|
__pvVector.erase(std::remove(__pvVector.begin(), __pvVector.end(), instance), __pvVector.end());
|
||||||
|
}
|
||||||
|
void WorkspaceInstance::addToPVector(PVInstance * instance)
|
||||||
|
{
|
||||||
|
__pvVector.push_back(instance);
|
||||||
|
}
|
||||||
15
WorkspaceInstance.h
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
#pragma once
|
||||||
|
#include "GroupInstance.h"
|
||||||
|
#include <set>
|
||||||
|
|
||||||
|
class WorkspaceInstance :
|
||||||
|
public GroupInstance
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
WorkspaceInstance(void);
|
||||||
|
~WorkspaceInstance(void);
|
||||||
|
void removeFromPVector(PVInstance *);
|
||||||
|
void addToPVector(PVInstance *);
|
||||||
|
std::vector<PVInstance*> __pvVector;
|
||||||
|
std::vector<PVInstance*>* getPVVector();
|
||||||
|
};
|
||||||
@@ -1,13 +1,17 @@
|
|||||||
// AX.CPP
|
// AX.CPP
|
||||||
|
#include <windows.h>
|
||||||
|
#include <comdef.h>
|
||||||
|
#include <exdisp.h>
|
||||||
|
#include <oledlg.h>
|
||||||
#include "ax.h"
|
#include "ax.h"
|
||||||
#include "AudioPlayer.h"
|
|
||||||
#include "Enum.h"
|
|
||||||
|
|
||||||
#pragma warning (disable: 4311)
|
#pragma warning (disable: 4311)
|
||||||
#pragma warning (disable: 4312)
|
#pragma warning (disable: 4312)
|
||||||
#pragma warning (disable: 4244)
|
#pragma warning (disable: 4244)
|
||||||
#pragma warning (disable: 4800)
|
#pragma warning (disable: 4800)
|
||||||
|
|
||||||
|
|
||||||
// AXClientSite class
|
// AXClientSite class
|
||||||
// ------- Implement member functions
|
// ------- Implement member functions
|
||||||
AXClientSite :: AXClientSite()
|
AXClientSite :: AXClientSite()
|
||||||
@@ -22,89 +26,10 @@ AXClientSite :: ~AXClientSite()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: ShowContextMenu(DWORD dwID, POINT *ppt, IUnknown *pcmdtReserved, IDispatch *pdispReserved)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: GetHostInfo(DOCHOSTUIINFO *pInfo)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: ShowUI( DWORD dwID, IOleInPlaceActiveObject *pActiveObject, IOleCommandTarget *pCommandTarget, IOleInPlaceFrame *pFrame, IOleInPlaceUIWindow *pDoc)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: HideUI( void)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: UpdateUI( void)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: OnDocWindowActivate(BOOL fActivate)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: OnFrameWindowActivate(BOOL fActivate)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: ResizeBorder( LPCRECT prcBorder, IOleInPlaceUIWindow *pUIWindow, BOOL fRameWindow)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: TranslateAccelerator( LPMSG lpMsg, const GUID *pguidCmdGroup, DWORD nCmdID)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: GetOptionKeyPath( LPOLESTR *pchKey, DWORD dw)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: GetDropTarget( IDropTarget *pDropTarget, IDropTarget **ppDropTarget)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: GetExternal(IDispatch **ppDispatch)
|
|
||||||
{
|
|
||||||
//IDispatch* disp = ax->GetExternalDispatch();
|
|
||||||
*ppDispatch = this;
|
|
||||||
/* if (disp!=NULL)
|
|
||||||
{
|
|
||||||
*ppDispatch = this;
|
|
||||||
return S_OK;
|
|
||||||
} */
|
|
||||||
return S_OK;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite ::TranslateUrl( DWORD dwTranslate, OLECHAR *pchURLIn, OLECHAR **ppchURLOut)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: FilterDataObject( IDataObject *pDO, IDataObject **ppDORet)
|
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
// IUnknown methods
|
// IUnknown methods
|
||||||
STDMETHODIMP AXClientSite :: QueryInterface(REFIID iid,void**ppvObject)
|
STDMETHODIMP AXClientSite :: QueryInterface(REFIID iid,void**ppvObject)
|
||||||
{
|
{
|
||||||
*ppvObject = 0;
|
*ppvObject = 0;
|
||||||
// if (iid == IID_IOleInPlaceSite)
|
|
||||||
// *ppvObject = (IOleInPlaceSite*)this;
|
|
||||||
if (iid == IID_IOleClientSite)
|
if (iid == IID_IOleClientSite)
|
||||||
*ppvObject = (IOleClientSite*)this;
|
*ppvObject = (IOleClientSite*)this;
|
||||||
if (iid == IID_IUnknown)
|
if (iid == IID_IUnknown)
|
||||||
@@ -113,7 +38,7 @@ STDMETHODIMP AXClientSite :: QueryInterface(REFIID iid,void**ppvObject)
|
|||||||
*ppvObject = (IAdviseSink*)this;
|
*ppvObject = (IAdviseSink*)this;
|
||||||
if (iid == IID_IDispatch)
|
if (iid == IID_IDispatch)
|
||||||
*ppvObject = (IDispatch*)this;
|
*ppvObject = (IDispatch*)this;
|
||||||
//if (ExternalPlace == false)
|
if (ExternalPlace == false)
|
||||||
{
|
{
|
||||||
if (iid == IID_IOleInPlaceSite)
|
if (iid == IID_IOleInPlaceSite)
|
||||||
*ppvObject = (IOleInPlaceSite*)this;
|
*ppvObject = (IOleInPlaceSite*)this;
|
||||||
@@ -121,8 +46,6 @@ STDMETHODIMP AXClientSite :: QueryInterface(REFIID iid,void**ppvObject)
|
|||||||
*ppvObject = (IOleInPlaceFrame*)this;
|
*ppvObject = (IOleInPlaceFrame*)this;
|
||||||
if (iid == IID_IOleInPlaceUIWindow)
|
if (iid == IID_IOleInPlaceUIWindow)
|
||||||
*ppvObject = (IOleInPlaceUIWindow*)this;
|
*ppvObject = (IOleInPlaceUIWindow*)this;
|
||||||
if (iid == IID_IDocHostUIHandler)
|
|
||||||
*ppvObject = (IDocHostUIHandler*)this;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//* Log Call
|
//* Log Call
|
||||||
@@ -306,9 +229,9 @@ STDMETHODIMP AXClientSite :: SetActiveObject(IOleInPlaceActiveObject*pV,LPCOLEST
|
|||||||
|
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: SetStatusText(LPCOLESTR t)
|
STDMETHODIMP AXClientSite :: SetStatusText(LPCOLESTR t)
|
||||||
{
|
{
|
||||||
return E_NOTIMPL;
|
return E_NOTIMPL;
|
||||||
}
|
}
|
||||||
|
|
||||||
STDMETHODIMP AXClientSite :: EnableModeless(BOOL f)
|
STDMETHODIMP AXClientSite :: EnableModeless(BOOL f)
|
||||||
{
|
{
|
||||||
@@ -328,21 +251,14 @@ HRESULT _stdcall AXClientSite :: GetTypeInfoCount(
|
|||||||
HRESULT _stdcall AXClientSite :: GetTypeInfo(
|
HRESULT _stdcall AXClientSite :: GetTypeInfo(
|
||||||
unsigned int iTInfo,
|
unsigned int iTInfo,
|
||||||
LCID lcid,
|
LCID lcid,
|
||||||
ITypeInfo FAR* FAR* ppTInfo)
|
ITypeInfo FAR* FAR* ppTInfo) {return E_NOTIMPL;}
|
||||||
{
|
|
||||||
return E_NOTIMPL;
|
|
||||||
}
|
|
||||||
|
|
||||||
HRESULT _stdcall AXClientSite :: GetIDsOfNames(
|
HRESULT _stdcall AXClientSite :: GetIDsOfNames(
|
||||||
REFIID riid,
|
REFIID riid,
|
||||||
OLECHAR FAR* FAR* ext_function_name,
|
OLECHAR FAR* FAR*,
|
||||||
unsigned int cNames,
|
unsigned int cNames,
|
||||||
LCID lcid,
|
LCID lcid,
|
||||||
DISPID FAR* )
|
DISPID FAR* ) {return E_NOTIMPL;}
|
||||||
{
|
|
||||||
m_lastExternalName = *ext_function_name;
|
|
||||||
return S_OK;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// Other Methods
|
// Other Methods
|
||||||
@@ -368,6 +284,8 @@ AX :: AX(char* cls)
|
|||||||
Init(cls);
|
Init(cls);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void AX :: Clean()
|
void AX :: Clean()
|
||||||
{
|
{
|
||||||
if (Site.InPlace == true)
|
if (Site.InPlace == true)
|
||||||
@@ -504,12 +422,9 @@ HRESULT _stdcall AXClientSite :: Invoke(
|
|||||||
VARIANT FAR* pVarResult,
|
VARIANT FAR* pVarResult,
|
||||||
EXCEPINFO FAR* pExcepInfo,
|
EXCEPINFO FAR* pExcepInfo,
|
||||||
unsigned int FAR* puArgErr)
|
unsigned int FAR* puArgErr)
|
||||||
{
|
{
|
||||||
IEBrowser * browser = (IEBrowser *)GetProp(Window,"Browser");
|
return E_NOTIMPL;
|
||||||
return browser->doExternal(m_lastExternalName,dispIdMember, riid, lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
|
}
|
||||||
|
|
||||||
//return S_OK;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void _stdcall AXClientSite :: OnDataChange(FORMATETC *pFormatEtc,STGMEDIUM *pStgmed)
|
void _stdcall AXClientSite :: OnDataChange(FORMATETC *pFormatEtc,STGMEDIUM *pStgmed)
|
||||||
@@ -616,6 +531,7 @@ LRESULT CALLBACK AXWndProc(HWND hh,UINT mm,WPARAM ww,LPARAM ll)
|
|||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mm == AX_GETAXINTERFACE)
|
if (mm == AX_GETAXINTERFACE)
|
||||||
{
|
{
|
||||||
AX* ax = (AX*)GetWindowLong(hh,GWL_USERDATA);
|
AX* ax = (AX*)GetWindowLong(hh,GWL_USERDATA);
|
||||||
@@ -1,10 +1,4 @@
|
|||||||
// AX.H
|
// AX.H
|
||||||
#pragma once
|
|
||||||
#include "Globals.h"
|
|
||||||
#include <mshtmhst.h>
|
|
||||||
#include <string>
|
|
||||||
#pragma once
|
|
||||||
#include "IEBrowser.h"
|
|
||||||
|
|
||||||
// messages
|
// messages
|
||||||
#define AX_QUERYINTERFACE (WM_USER + 1)
|
#define AX_QUERYINTERFACE (WM_USER + 1)
|
||||||
@@ -15,6 +9,7 @@
|
|||||||
#define AX_SETDATAADVISE (WM_USER + 6)
|
#define AX_SETDATAADVISE (WM_USER + 6)
|
||||||
#define AX_DOVERB (WM_USER + 7)
|
#define AX_DOVERB (WM_USER + 7)
|
||||||
|
|
||||||
|
|
||||||
// Registration function
|
// Registration function
|
||||||
ATOM AXRegister();
|
ATOM AXRegister();
|
||||||
|
|
||||||
@@ -25,8 +20,7 @@ class AXClientSite :
|
|||||||
public IDispatch,
|
public IDispatch,
|
||||||
public IAdviseSink,
|
public IAdviseSink,
|
||||||
public IOleInPlaceSite,
|
public IOleInPlaceSite,
|
||||||
public IOleInPlaceFrame,
|
public IOleInPlaceFrame
|
||||||
public IDocHostUIHandler
|
|
||||||
{
|
{
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
@@ -34,6 +28,7 @@ class AXClientSite :
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
|
||||||
HWND Window;
|
HWND Window;
|
||||||
HWND Parent;
|
HWND Parent;
|
||||||
HMENU Menu;
|
HMENU Menu;
|
||||||
@@ -42,6 +37,7 @@ class AXClientSite :
|
|||||||
bool CalledCanInPlace;
|
bool CalledCanInPlace;
|
||||||
|
|
||||||
class AX* ax;
|
class AX* ax;
|
||||||
|
|
||||||
// MyClientSite Methods
|
// MyClientSite Methods
|
||||||
AXClientSite();
|
AXClientSite();
|
||||||
virtual ~AXClientSite();
|
virtual ~AXClientSite();
|
||||||
@@ -59,64 +55,7 @@ class AXClientSite :
|
|||||||
STDMETHODIMP ShowObject();
|
STDMETHODIMP ShowObject();
|
||||||
STDMETHODIMP OnShowWindow(BOOL f);
|
STDMETHODIMP OnShowWindow(BOOL f);
|
||||||
STDMETHODIMP RequestNewObjectLayout();
|
STDMETHODIMP RequestNewObjectLayout();
|
||||||
|
|
||||||
// IDDocHandler methods
|
|
||||||
STDMETHODIMP ShowContextMenu(
|
|
||||||
/* [in] */ DWORD dwID,
|
|
||||||
/* [in] */ POINT *ppt,
|
|
||||||
/* [in] */ IUnknown *pcmdtReserved,
|
|
||||||
/* [in] */ IDispatch *pdispReserved);
|
|
||||||
|
|
||||||
STDMETHODIMP GetHostInfo(
|
|
||||||
/* [out][in] */ DOCHOSTUIINFO *pInfo);
|
|
||||||
|
|
||||||
STDMETHODIMP ShowUI(
|
|
||||||
/* [in] */ DWORD dwID,
|
|
||||||
/* [in] */ IOleInPlaceActiveObject *pActiveObject,
|
|
||||||
/* [in] */ IOleCommandTarget *pCommandTarget,
|
|
||||||
/* [in] */ IOleInPlaceFrame *pFrame,
|
|
||||||
/* [in] */ IOleInPlaceUIWindow *pDoc);
|
|
||||||
|
|
||||||
STDMETHODIMP HideUI( void);
|
|
||||||
|
|
||||||
STDMETHODIMP UpdateUI( void);
|
|
||||||
|
|
||||||
STDMETHODIMP OnDocWindowActivate(
|
|
||||||
/* [in] */ BOOL fActivate);
|
|
||||||
|
|
||||||
STDMETHODIMP OnFrameWindowActivate(
|
|
||||||
/* [in] */ BOOL fActivate);
|
|
||||||
|
|
||||||
STDMETHODIMP ResizeBorder(
|
|
||||||
/* [in] */ LPCRECT prcBorder,
|
|
||||||
/* [in] */ IOleInPlaceUIWindow *pUIWindow,
|
|
||||||
/* [in] */ BOOL fRameWindow);
|
|
||||||
|
|
||||||
STDMETHODIMP TranslateAccelerator(
|
|
||||||
/* [in] */ LPMSG lpMsg,
|
|
||||||
/* [in] */ const GUID *pguidCmdGroup,
|
|
||||||
/* [in] */ DWORD nCmdID);
|
|
||||||
|
|
||||||
STDMETHODIMP GetOptionKeyPath(
|
|
||||||
/* [out] */ LPOLESTR *pchKey,
|
|
||||||
/* [in] */ DWORD dw);
|
|
||||||
|
|
||||||
STDMETHODIMP GetDropTarget(
|
|
||||||
/* [in] */ IDropTarget *pDropTarget,
|
|
||||||
/* [out] */ IDropTarget **ppDropTarget);
|
|
||||||
|
|
||||||
STDMETHODIMP GetExternal(
|
|
||||||
/* [out] */ IDispatch **ppDispatch);
|
|
||||||
|
|
||||||
STDMETHODIMP TranslateUrl(
|
|
||||||
/* [in] */ DWORD dwTranslate,
|
|
||||||
/* [in] */ OLECHAR *pchURLIn,
|
|
||||||
/* [out] */ OLECHAR **ppchURLOut);
|
|
||||||
|
|
||||||
STDMETHODIMP FilterDataObject(
|
|
||||||
/* [in] */ IDataObject *pDO,
|
|
||||||
/* [out] */ IDataObject **ppDORet);
|
|
||||||
|
|
||||||
// IAdviseSink methods
|
// IAdviseSink methods
|
||||||
STDMETHODIMP_(void) OnDataChange(FORMATETC *pFormatEtc,STGMEDIUM *pStgmed);
|
STDMETHODIMP_(void) OnDataChange(FORMATETC *pFormatEtc,STGMEDIUM *pStgmed);
|
||||||
|
|
||||||
@@ -151,13 +90,14 @@ class AXClientSite :
|
|||||||
STDMETHODIMP EnableModeless(BOOL f);
|
STDMETHODIMP EnableModeless(BOOL f);
|
||||||
STDMETHODIMP TranslateAccelerator(LPMSG,WORD);
|
STDMETHODIMP TranslateAccelerator(LPMSG,WORD);
|
||||||
|
|
||||||
std::wstring m_lastExternalName;
|
|
||||||
|
|
||||||
// IDispatch Methods
|
// IDispatch Methods
|
||||||
HRESULT _stdcall GetTypeInfoCount(unsigned int * pctinfo);
|
HRESULT _stdcall GetTypeInfoCount(unsigned int * pctinfo);
|
||||||
HRESULT _stdcall GetTypeInfo(unsigned int iTInfo,LCID lcid,ITypeInfo FAR* FAR* ppTInfo);
|
HRESULT _stdcall GetTypeInfo(unsigned int iTInfo,LCID lcid,ITypeInfo FAR* FAR* ppTInfo);
|
||||||
HRESULT _stdcall GetIDsOfNames(REFIID riid,OLECHAR FAR* FAR*,unsigned int cNames,LCID lcid,DISPID FAR* );
|
HRESULT _stdcall GetIDsOfNames(REFIID riid,OLECHAR FAR* FAR*,unsigned int cNames,LCID lcid,DISPID FAR* );
|
||||||
HRESULT _stdcall Invoke(DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS FAR* pDispParams,VARIANT FAR* pVarResult,EXCEPINFO FAR* pExcepInfo,unsigned int FAR* puArgErr);
|
HRESULT _stdcall Invoke(DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS FAR* pDispParams,VARIANT FAR* pVarResult,EXCEPINFO FAR* pExcepInfo,unsigned int FAR* puArgErr);
|
||||||
|
|
||||||
|
// IOleControlSite Methods
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -187,9 +127,13 @@ class AX
|
|||||||
//AX_CONNECTSTRUCT* tcs;
|
//AX_CONNECTSTRUCT* tcs;
|
||||||
bool AddMenu;
|
bool AddMenu;
|
||||||
DWORD AdviseToken;
|
DWORD AdviseToken;
|
||||||
DWORD DAdviseToken[100];
|
DWORD DAdviseToken[100];
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
CLSID clsid;
|
CLSID clsid;
|
||||||
|
|
||||||
|
|
||||||
|
Before Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 6.1 KiB |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 950 B |
|
Before Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 3.4 KiB |
|
Before Width: | Height: | Size: 5.2 KiB |
|
Before Width: | Height: | Size: 7.8 KiB |
|
Before Width: | Height: | Size: 3.5 KiB |
|
Before Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 3.4 KiB |
|
Before Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 6.0 KiB |