Preliminary working version of TinyRenderer for standalone demos,
it works without OpenGL dependency now, so it runs in the cloud :-) Add scaling support for TinyRenderer, remove some un-used normal mapping in TinyRenderer shader, expose light_dir_world, remove accidental hard-coded path in tga write_tga_file, Fix InverseDynamicsExampleCreateFunc, enum has to start at 0
This commit is contained in:
@@ -87,10 +87,10 @@ public:
|
||||
|
||||
virtual void resetCamera()
|
||||
{
|
||||
float dist = 3.5;
|
||||
float pitch = -136;
|
||||
float yaw = 28;
|
||||
float targetPos[3]={0.47,0,-0.64};
|
||||
float dist = 1.5;
|
||||
float pitch = -80;
|
||||
float yaw = 10;
|
||||
float targetPos[3]={0,0,0};
|
||||
m_guiHelper->resetCamera(dist,pitch,yaw,targetPos[0],targetPos[1],targetPos[2]);
|
||||
}
|
||||
};
|
||||
@@ -239,7 +239,7 @@ void InverseDynamicsExample::initPhysics()
|
||||
|
||||
}
|
||||
|
||||
|
||||
m_guiHelper->autogenerateGraphicsObjects(m_dynamicsWorld);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -18,8 +18,8 @@ subject to the following restrictions:
|
||||
|
||||
enum btInverseDynamicsExampleOptions
|
||||
{
|
||||
BT_ID_LOAD_URDF=1,
|
||||
BT_ID_PROGRAMMATICALLY=2
|
||||
BT_ID_LOAD_URDF=0,
|
||||
BT_ID_PROGRAMMATICALLY=1
|
||||
};
|
||||
|
||||
class CommonExampleInterface* InverseDynamicsExampleCreateFunc(struct CommonExampleOptions& options);
|
||||
|
||||
@@ -165,3 +165,56 @@ if os.is("MacOSX") then
|
||||
links{"Cocoa.framework"}
|
||||
end
|
||||
|
||||
|
||||
project "App_InverseDynamicsExampleTinyRenderer"
|
||||
|
||||
if _OPTIONS["ios"] then
|
||||
kind "WindowedApp"
|
||||
else
|
||||
kind "ConsoleApp"
|
||||
end
|
||||
defines {"B3_USE_STANDALONE_EXAMPLE"}
|
||||
|
||||
includedirs {"../../src"}
|
||||
|
||||
links {
|
||||
"BulletInverseDynamicsUtils", "BulletInverseDynamics","BulletDynamics","BulletCollision", "LinearMath", "Bullet3Common"
|
||||
}
|
||||
|
||||
language "C++"
|
||||
|
||||
files {
|
||||
"InverseDynamicsExample.cpp",
|
||||
"*.h",
|
||||
"../StandaloneMain/main_tinyrenderer_single_example.cpp",
|
||||
"../OpenGLWindow/SimpleCamera.cpp",
|
||||
"../ExampleBrowser/CollisionShape2TriangleMesh.cpp",
|
||||
"../TinyRenderer/geometry.cpp",
|
||||
"../TinyRenderer/model.cpp",
|
||||
"../TinyRenderer/tgaimage.cpp",
|
||||
"../TinyRenderer/our_gl.cpp",
|
||||
"../TinyRenderer/TinyRenderer.cpp",
|
||||
"../Utils/b3ResourcePath.cpp",
|
||||
"../Utils/b3ResourcePath.cpp",
|
||||
"../Utils/b3ResourcePath.h",
|
||||
"../RenderingExamples/TimeSeriesCanvas.cpp",
|
||||
"../RenderingExamples/TimeSeriesFontData.cpp",
|
||||
"../MultiBody/InvertedPendulumPDControl.cpp",
|
||||
"../ThirdPartyLibs/tinyxml/tinystr.cpp",
|
||||
"../ThirdPartyLibs/tinyxml/tinyxml.cpp",
|
||||
"../ThirdPartyLibs/tinyxml/tinyxmlerror.cpp",
|
||||
"../ThirdPartyLibs/tinyxml/tinyxmlparser.cpp",
|
||||
"../ThirdPartyLibs/Wavefront/tiny_obj_loader.cpp",
|
||||
"../ThirdPartyLibs/Wavefront/tiny_obj_loader.h",
|
||||
"../Importers/ImportColladaDemo/LoadMeshFromCollada.cpp",
|
||||
"../Importers/ImportObjDemo/LoadMeshFromObj.cpp",
|
||||
"../Importers/ImportObjDemo/Wavefront2GLInstanceGraphicsShape.cpp",
|
||||
"../Importers/ImportURDFDemo/BulletUrdfImporter.cpp",
|
||||
"../Importers/ImportURDFDemo/DefaultVisualShapeConverter.cpp",
|
||||
"../Importers/ImportURDFDemo/MyMultiBodyCreator.cpp",
|
||||
"../Importers/ImportURDFDemo/URDF2Bullet.cpp",
|
||||
"../Importers/ImportURDFDemo/UrdfParser.cpp",
|
||||
"../Importers/ImportURDFDemo/urdfStringSplit.cpp",
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user