Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
O
Oersted
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Pries, Jason
Oersted
Commits
3c94da51
Commit
3c94da51
authored
Oct 09, 2017
by
Pries, Jason
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't pass shared_ptr by reference
parent
0abb4580
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
12 deletions
+12
-12
CMakeLists.txt
CMakeLists.txt
+2
-2
src/Sketch/CMakeLists.txt
src/Sketch/CMakeLists.txt
+1
-1
src/Sketch/src/Sketch.cpp
src/Sketch/src/Sketch.cpp
+3
-3
src/Sketch/src/Sketch.h
src/Sketch/src/Sketch.h
+6
-6
No files found.
CMakeLists.txt
View file @
3c94da51
...
...
@@ -3,8 +3,8 @@ cmake_minimum_required(VERSION 3.2)
project
(
Oersted
)
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-std=gnu++17"
)
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-g -O3 --coverage -fopenmp"
)
#
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O3 -fopenmp")
#
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O3 --coverage -fopenmp")
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-g -O3 -fopenmp"
)
include_directories
(
./lib/
)
include_directories
(
./lib/Eigen/
)
...
...
src/Sketch/CMakeLists.txt
View file @
3c94da51
...
...
@@ -40,7 +40,7 @@ set(SOURCE_FILES
./src/Constellation.h ./src/Constellation.cpp
./src/Contour.h ./src/Contour.cpp
src/BoundingBall.cpp src/BoundingBall.h
)
src/BoundingBall.cpp src/BoundingBall.h
src/CylindricalAirgap.cpp src/CylindricalAirgap.h
)
add_library
(
sketch SHARED
${
SOURCE_FILES
}
)
...
...
src/Sketch/src/Sketch.cpp
View file @
3c94da51
...
...
@@ -203,7 +203,7 @@ void Sketch::save_as<SaveMethod::Rasterize>(std::string path, std::string file_n
fs
.
close
();
}
std
::
vector
<
PeriodicBoundaryPair
>
Sketch
::
select_periodic_boundary_pairs
(
std
::
shared_ptr
<
Vertex
const
>
const
&
v0
,
double_t
angle
)
const
{
std
::
vector
<
PeriodicBoundaryPair
>
Sketch
::
select_periodic_boundary_pairs
(
std
::
shared_ptr
<
Vertex
const
>
v0
,
double_t
angle
)
const
{
std
::
vector
<
PeriodicBoundaryPair
>
cbp
;
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
bc
=
Boundary
->
curves
();
...
...
@@ -247,7 +247,7 @@ std::vector<PeriodicBoundaryPair> Sketch::select_periodic_boundary_pairs(std::sh
return
cbp
;
}
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
Sketch
::
select_radial_boundary
(
std
::
shared_ptr
<
Vertex
const
>
const
&
v0
,
double_t
radius
)
const
{
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
Sketch
::
select_radial_boundary
(
std
::
shared_ptr
<
Vertex
const
>
v0
,
double_t
radius
)
const
{
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
rb
;
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
bc
=
Boundary
->
curves
();
...
...
@@ -262,7 +262,7 @@ std::vector<std::shared_ptr<Curve const>> Sketch::select_radial_boundary(std::sh
return
rb
;
}
std
::
shared_ptr
<
Vertex
const
>
Sketch
::
select_periodic_vertex
(
std
::
shared_ptr
<
Vertex
const
>
const
&
v
,
std
::
shared_ptr
<
Vertex
const
>
const
&
origin
,
double_t
angle
)
const
{
std
::
shared_ptr
<
Vertex
const
>
Sketch
::
select_periodic_vertex
(
std
::
shared_ptr
<
Vertex
const
>
v
,
std
::
shared_ptr
<
Vertex
const
>
origin
,
double_t
angle
)
const
{
for
(
auto
const
&
v_test
:
Verticies
)
{
if
(
v_test
->
is_identical
(
v
,
origin
,
angle
))
{
return
v_test
;
...
...
src/Sketch/src/Sketch.h
View file @
3c94da51
...
...
@@ -43,9 +43,9 @@ public:
bool
build
();
// TODO: Detailed return enum
double
characteristic_length
()
const
;
double
_t
characteristic_length
()
const
;
double
solve
();
// TODO: Detailed return enum
double
_t
solve
();
// TODO: Detailed return enum
void
add_element
(
std
::
shared_ptr
<
Constraint
>
c
);
...
...
@@ -57,7 +57,7 @@ public:
void
add_parameter
(
std
::
shared_ptr
<
Variable
>
v
)
{
add_parameter
(
Variables
,
v
);
};
void
perturb
(
Eigen
::
VectorXd
&
delta
,
double
scale
)
const
;
void
perturb
(
Eigen
::
VectorXd
&
delta
,
double
_t
scale
)
const
;
void
update_linearization
(
Eigen
::
MatrixXd
&
J
,
Eigen
::
VectorXd
&
r
)
const
;
...
...
@@ -83,11 +83,11 @@ public:
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
const
curves
()
{
return
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
{
Curves
.
begin
(),
Curves
.
end
()};
};
std
::
vector
<
PeriodicBoundaryPair
>
select_periodic_boundary_pairs
(
std
::
shared_ptr
<
Vertex
const
>
const
&
v0
,
double_t
angle
)
const
;
std
::
vector
<
PeriodicBoundaryPair
>
select_periodic_boundary_pairs
(
std
::
shared_ptr
<
Vertex
const
>
v0
,
double_t
angle
)
const
;
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
select_radial_boundary
(
std
::
shared_ptr
<
Vertex
const
>
const
&
v0
,
double_t
radius
)
const
;
std
::
vector
<
std
::
shared_ptr
<
Curve
const
>>
select_radial_boundary
(
std
::
shared_ptr
<
Vertex
const
>
v0
,
double_t
radius
)
const
;
std
::
shared_ptr
<
Vertex
const
>
select_periodic_vertex
(
std
::
shared_ptr
<
Vertex
const
>
const
&
v1
,
std
::
shared_ptr
<
Vertex
const
>
const
&
origin
,
double_t
angle
)
const
;
std
::
shared_ptr
<
Vertex
const
>
select_periodic_vertex
(
std
::
shared_ptr
<
Vertex
const
>
v1
,
std
::
shared_ptr
<
Vertex
const
>
origin
,
double_t
angle
)
const
;
std
::
vector
<
std
::
shared_ptr
<
Contour
const
>>
select_contours
(
BoundingBall
bb
)
const
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment