Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
P
Project 3 Star Gazing
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Eric Walsh
Project 3 Star Gazing
Commits
4e1ad862
Commit
4e1ad862
authored
Mar 18, 2019
by
Walterio Montanez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
autosave
parent
0059ba13
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
1 deletion
+23
-1
Input stuff/Functions.cpp
Input stuff/Functions.cpp
+23
-1
No files found.
Input stuff/Functions.cpp
View file @
4e1ad862
...
...
@@ -441,4 +441,26 @@ vector <pair<double, double>> viewFinder (pair <double, double> centerPt) { // f
}
}
return
corners
;
}
\ No newline at end of file
}
void
viewWindow
(
vector
<
pair
<
double
,
double
>>
corners
,
pair
<
double
,
double
>
constellationCoord
)
{
pair
<
double
,
double
>
coordinates1
;
pair
<
double
,
double
>
coordinates2
;
pair
<
double
,
double
>
coordinates3
;
pair
<
double
,
double
>
coordinates4
;
if
(
corners
.
coordinates1
.
first
>
constellationCoord
.
first
&&
corners
.
coordinates1
.
second
>
constellationCoord
.
second
&&
corners
.
coordinates2
.
first
<
constellationCoord
.
first
&&
corners
.
coordinates2
.
second
>
constellationCoord
.
second
&&
corners
.
coordinates3
.
first
>
constellationCoord
.
first
&&
corners
.
coordinates3
.
second
<
constellationCoord
.
second
&&
corners
.
coordinates4
.
first
<
constellationCoord
.
first
&&
corners
.
coordinates4
.
second
<
constellationCoord
.
second
)
{
cout
<<
"Constellation is fully in view"
<<
endl
;
}
else
if
(
corners
.
coordinates1
.
first
>
constellationCoord
.
first
||
corners
.
coordinates1
.
second
>
constellationCoord
.
second
||
corners
.
coordinates2
.
first
<
constellationCoord
.
first
||
corners
.
coordinates2
.
second
>
constellationCoord
.
second
||
corners
.
coordinates3
.
first
>
constellationCoord
.
first
||
corners
.
coordinates3
.
second
<
constellationCoord
.
second
||
corners
.
coordinates4
.
first
<
constellationCoord
.
first
||
corners
.
coordinates4
.
second
<
constellationCoord
.
second
)
{
cout
<<
"Constellation is partially in view"
<<
endl
;
}
else
{
cout
<<
"Constellation is not in view"
<<
endl
;
}
}
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