Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
RoFIbots
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Marek Trtík
RoFIbots
Commits
a811d670
There was an error fetching the commit references. Please try again later.
Commit
a811d670
authored
1 year ago
by
Martin Štourač
Browse files
Options
Downloads
Patches
Plain Diff
added giraffe.obj
parent
e8ee5281
No related branches found
No related tags found
No related merge requests found
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
data/models/final_giraffe.obj
+151412
-0
151412 additions, 0 deletions
data/models/final_giraffe.obj
src/gfx/src/obj_loader.cpp
+1
-2
1 addition, 2 deletions
src/gfx/src/obj_loader.cpp
src/studio/src/simulator.cpp
+5
-0
5 additions, 0 deletions
src/studio/src/simulator.cpp
with
151418 additions
and
2 deletions
data/models/final_giraffe.obj
0 → 100644
+
151412
−
0
View file @
a811d670
This diff is collapsed.
Click to expand it.
src/gfx/src/obj_loader.cpp
+
1
−
2
View file @
a811d670
...
...
@@ -3,13 +3,12 @@
object_ptr
load_object
(
std
::
string
const
&
model_path
)
{
// TO DO: rework indices for normals from .obj
tinyobj
::
attrib_t
attrib
;
std
::
vector
<
tinyobj
::
shape_t
>
shapes
;
std
::
vector
<
tinyobj
::
material_t
>
objmaterials
;
std
::
string
warn
,
err
;
if
(
!
tinyobj
::
LoadObj
(
&
attrib
,
&
shapes
,
&
objmaterials
,
&
warn
,
&
err
,
model_path
.
c_str
()))
throw
(
std
::
runtime_error
(
warn
+
err
));
...
...
This diff is collapsed.
Click to expand it.
src/studio/src/simulator.cpp
+
5
−
0
View file @
a811d670
...
...
@@ -308,6 +308,11 @@ void Simulator::createScene()
object_ptr
vase
=
load_object
(
"./data/models/smooth_vase.obj"
);
scene
.
back
()
->
addObject
(
std
::
move
(
vase
));
// /* ADD .OBJ GIRAFFE */
// scene.emplace_back(std::make_shared<Node>(std::make_shared<Frame>(glm::vec3(-5, 1, 3))));
// object_ptr giraffe = load_object("./data/models/final_giraffe.obj");
// scene.back()->addObject(std::move(giraffe));
/* ADD CAMERA */
scene
.
emplace_back
(
std
::
make_shared
<
Node
>
(
std
::
make_shared
<
Frame
>
(
glm
::
vec3
(
0.0
f
,
1.0
f
,
6.0
f
))));
scene
.
back
()
->
addObject
(
std
::
make_shared
<
Camera
>
(
60.0
f
,
scene
.
back
()
->
getFrame
()));
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment