Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
creativeProjects2
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
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kevin Dang
creativeProjects2
Commits
5a29850b
Commit
5a29850b
authored
Apr 14, 2016
by
Kevin Dang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
some slight changes to previous code
parent
75219f04
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
15 deletions
+7
-15
Lux/.DS_Store
Lux/.DS_Store
+0
-0
Lux/Lux.xcodeproj/project.xcworkspace/xcuserdata/Kevin.xcuserdatad/UserInterfaceState.xcuserstate
...userdata/Kevin.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
Lux/src/lightDrawing.cpp
Lux/src/lightDrawing.cpp
+6
-11
Lux/src/lightDrawing.h
Lux/src/lightDrawing.h
+1
-4
No files found.
Lux/.DS_Store
View file @
5a29850b
No preview for this file type
Lux/Lux.xcodeproj/project.xcworkspace/xcuserdata/Kevin.xcuserdatad/UserInterfaceState.xcuserstate
View file @
5a29850b
No preview for this file type
Lux/src/lightDrawing.cpp
View file @
5a29850b
...
...
@@ -68,19 +68,17 @@ void lightDrawing::draw() {
void
lightDrawing
::
clearAllLines
()
{
drawLine
.
clear
();
void
lightDrawing
::
clearPreviousLine
()
{
// only allows you to delete the last added element
if
(
drawLine
.
size
()
>
0
)
{
// you need this condition or the program will crash
drawLine
.
pop_back
();
}
}
void
lightDrawing
::
mouseDragged
(
ofVec3f
_pos
)
{
drawLine
[
drawLine
.
size
()
-
1
].
addVertex
(
_pos
);
drawLine
[
drawLine
.
size
()
-
1
].
addVertex
(
_pos
);
}
...
...
@@ -91,13 +89,10 @@ void lightDrawing::mouseRPressed() {
void
lightDrawing
::
mousePressed
(
ofVec3f
_pos
)
{
// drawLine.push_back(ofPolyline());
rightMouseButtonPressed
=
true
;
currentPolyline
.
curveTo
(
_pos
.
x
,
_pos
.
y
,
_pos
.
z
);
currentPolyline
.
curveTo
(
_pos
.
x
,
_pos
.
y
,
_pos
.
z
);
lastPoint
.
set
(
_pos
.
x
,
_pos
.
y
,
_pos
.
z
);
}
...
...
Lux/src/lightDrawing.h
View file @
5a29850b
...
...
@@ -21,7 +21,7 @@ public:
void
setup
();
void
draw
();
void
clear
AllLines
();
void
clear
PreviousLine
();
void
mouseDragged
(
ofVec3f
_pos
);
void
mouseRPressed
();
...
...
@@ -36,15 +36,12 @@ public:
void
mousePressed
(
ofVec3f
_pos
);
void
mouseReleased
(
ofVec3f
_pos
);
vector
<
ofSpherePrimitive
>
storeSphere
;
ofSpherePrimitive
sphere
;
void
bubblesetup
();
void
bubbledraw
();
void
createbubble
(
ofVec3f
_pos
);
};
...
...
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