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
A
AMOEBA
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
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
Amanda Ghassaei
AMOEBA
Commits
2f020dc3
Commit
2f020dc3
authored
May 26, 2016
by
amandaghassaei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
set material working
parent
b65a059b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
js/cells/DMACell.js
js/cells/DMACell.js
+8
-1
No files found.
js/cells/DMACell.js
View file @
2f020dc3
...
@@ -43,6 +43,12 @@ define(['underscore', 'three', 'threeModel', 'lattice', 'appState', 'globals', '
...
@@ -43,6 +43,12 @@ define(['underscore', 'three', 'threeModel', 'lattice', 'appState', 'globals', '
return
this
.
object3D
.
children
[
0
];
return
this
.
object3D
.
children
[
0
];
};
};
DMACell
.
prototype
.
getVisibleMesh
=
function
(){
var
children
=
this
.
object3D
.
children
;
if
(
children
[
1
].
name
==
"
part
"
)
return
children
[
1
];
return
children
[
0
];
};
DMACell
.
prototype
.
_rotateCell
=
function
(
object3D
){
DMACell
.
prototype
.
_rotateCell
=
function
(
object3D
){
return
object3D
;
//by default, no mesh transformations
return
object3D
;
//by default, no mesh transformations
};
};
...
@@ -66,6 +72,7 @@ define(['underscore', 'three', 'threeModel', 'lattice', 'appState', 'globals', '
...
@@ -66,6 +72,7 @@ define(['underscore', 'three', 'threeModel', 'lattice', 'appState', 'globals', '
var
partGeo
=
this
.
_getPartGeo
();
var
partGeo
=
this
.
_getPartGeo
();
if
(
partGeo
){
if
(
partGeo
){
var
partMesh
=
new
THREE
.
Mesh
(
partGeo
,
this
.
getMaterial
(
true
));
var
partMesh
=
new
THREE
.
Mesh
(
partGeo
,
this
.
getMaterial
(
true
));
partMesh
.
name
=
"
part
"
;
meshes
.
push
(
partMesh
);
meshes
.
push
(
partMesh
);
wireframeMesh
=
partMesh
;
wireframeMesh
=
partMesh
;
mesh
.
visible
=
false
;
mesh
.
visible
=
false
;
...
@@ -196,7 +203,7 @@ define(['underscore', 'three', 'threeModel', 'lattice', 'appState', 'globals', '
...
@@ -196,7 +203,7 @@ define(['underscore', 'three', 'threeModel', 'lattice', 'appState', 'globals', '
};
};
DMACell
.
prototype
.
_setTHREEMaterial
=
function
(
threeMaterial
){
DMACell
.
prototype
.
_setTHREEMaterial
=
function
(
threeMaterial
){
this
.
get
Highlighta
bleMesh
().
material
=
threeMaterial
;
this
.
get
Visi
bleMesh
().
material
=
threeMaterial
;
};
};
DMACell
.
prototype
.
getMaterial
=
function
(
returnTHREEObject
){
DMACell
.
prototype
.
getMaterial
=
function
(
returnTHREEObject
){
...
...
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