Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
MasterTestProjekt
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kai Westerkamp
MasterTestProjekt
Commits
754476dc
Commit
754476dc
authored
Apr 27, 2017
by
wester
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lod an negative distance (inside bounding)
parent
2906199f
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
4 deletions
+5
-4
Minimal_Default.umap
Content/MobileStarterContent/Maps/Minimal_Default.umap
+0
-0
Minimal_Default_BuiltData.uasset
...obileStarterContent/Maps/Minimal_Default_BuiltData.uasset
+0
-0
Tileset.cpp
Source/MasterTestProject/Tileset.cpp
+5
-4
No files found.
Content/MobileStarterContent/Maps/Minimal_Default.umap
View file @
754476dc
No preview for this file type
Content/MobileStarterContent/Maps/Minimal_Default_BuiltData.uasset
View file @
754476dc
No preview for this file type
Source/MasterTestProject/Tileset.cpp
View file @
754476dc
...
@@ -98,7 +98,7 @@ double FTile::getScreenSpaceError(double lambda, FVector CamLocation)
...
@@ -98,7 +98,7 @@ double FTile::getScreenSpaceError(double lambda, FVector CamLocation)
//SSE http://folk.uio.no/inftt/Div/visualization2.pdf
//SSE http://folk.uio.no/inftt/Div/visualization2.pdf
double
sse
=
lambda
*
this
->
geometricError
/
dist
;
double
sse
=
lambda
*
this
->
geometricError
/
dist
;
//
UE_LOG(TILES, Error, TEXT("sse = %f, geoE = %f Dist %f"), sse, this->geometricError, dist);
UE_LOG
(
TILES
,
Error
,
TEXT
(
"sse = %f, geoE = %f Dist %f"
),
sse
,
this
->
geometricError
,
dist
);
return
sse
;
return
sse
;
}
}
...
@@ -135,7 +135,7 @@ void ATilesetActor::updateScreenSpaceError(FTile* current, double currentSSE, do
...
@@ -135,7 +135,7 @@ void ATilesetActor::updateScreenSpaceError(FTile* current, double currentSSE, do
{
{
double
ScreenSpaceError1
=
current
->
getScreenSpaceError
(
constant
,
CamLocation
);
double
ScreenSpaceError1
=
current
->
getScreenSpaceError
(
constant
,
CamLocation
);
if
(
ScreenSpaceError1
>
LODtreshold
&&
current
->
children
.
Num
()
>
0
)
{
if
(
(
ScreenSpaceError1
>
LODtreshold
||
ScreenSpaceError1
<
0
)
&&
current
->
children
.
Num
()
>
0
)
{
for
(
FTile
*
child
:
current
->
children
)
for
(
FTile
*
child
:
current
->
children
)
{
{
updateScreenSpaceError
(
child
,
0
,
constant
,
CamLocation
);
updateScreenSpaceError
(
child
,
0
,
constant
,
CamLocation
);
...
@@ -405,7 +405,7 @@ float FBoundingVolume::getDistanceTo(FVector Position, FMatrix bouindingTransfor
...
@@ -405,7 +405,7 @@ float FBoundingVolume::getDistanceTo(FVector Position, FMatrix bouindingTransfor
FVector
ZAxis
=
FVector
(
box
[
9
],
box
[
10
],
box
[
11
]);
FVector
ZAxis
=
FVector
(
box
[
9
],
box
[
10
],
box
[
11
]);
//TODO FIXME is currently spher distance
//TODO FIXME is currently spher distance
UE_LOG
(
TILES
,
Error
,
TEXT
(
"Box distance is not implemented"
));
//
UE_LOG(TILES, Error, TEXT("Box distance is not implemented"));
double
dist
=
(
localPos
-
Center
).
Size
();
double
dist
=
(
localPos
-
Center
).
Size
();
distance
=
dist
-
FMath
::
Max3
(
XAxis
.
Size
(),
YAxis
.
Size
(),
ZAxis
.
Size
());
distance
=
dist
-
FMath
::
Max3
(
XAxis
.
Size
(),
YAxis
.
Size
(),
ZAxis
.
Size
());
...
@@ -413,8 +413,9 @@ float FBoundingVolume::getDistanceTo(FVector Position, FMatrix bouindingTransfor
...
@@ -413,8 +413,9 @@ float FBoundingVolume::getDistanceTo(FVector Position, FMatrix bouindingTransfor
else
if
(
region
.
Num
()
==
6
)
{
else
if
(
region
.
Num
()
==
6
)
{
// WGS84
// WGS84
//TODO FIXME is currently spher distance
//TODO FIXME is currently spher distance
UE_LOG
(
TILES
,
Error
,
TEXT
(
"Region distance is not implemented"
));
//
UE_LOG(TILES, Error, TEXT("Region distance is not implemented"));
FVector
Center
=
FVector
(
0
,
0
,
6378137
);
FVector
Center
=
FVector
(
0
,
0
,
6378137
);
UE_LOG
(
TILES
,
Error
,
TEXT
(
"Position %s, Center %s, Transform %s"
),
*
Position
.
ToString
(),
*
Center
.
ToString
(),
*
bouindingTransformation
.
ToString
());
double
dist
=
(
Position
-
Center
).
Size
();
double
dist
=
(
Position
-
Center
).
Size
();
distance
=
dist
;
distance
=
dist
;
}
else
if
(
sphere
.
Num
()
==
4
)
{
}
else
if
(
sphere
.
Num
()
==
4
)
{
...
...
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