Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fslpy
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
FSL
fslpy
Commits
c04c0a80
Commit
c04c0a80
authored
10 years ago
by
Paul McCarthy
Browse files
Options
Downloads
Patches
Plain Diff
Inane code reformatting, and a small comment
parent
4759dd32
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
fsl/fslview/slicecanvas.py
+20
-11
20 additions, 11 deletions
fsl/fslview/slicecanvas.py
with
20 additions
and
11 deletions
fsl/fslview/slicecanvas.py
+
20
−
11
View file @
c04c0a80
...
@@ -306,19 +306,22 @@ class SliceCanvas(wxgl.GLCanvas):
...
@@ -306,19 +306,22 @@ class SliceCanvas(wxgl.GLCanvas):
for
image
in
self
.
imageList
:
for
image
in
self
.
imageList
:
try
:
try
:
glData
=
image
.
getAttribute
(
self
.
name
)
glData
=
image
.
getAttribute
(
self
.
name
)
except
:
continue
glData
=
glimagedata
.
GLImageData
(
image
,
self
.
xax
,
self
.
yax
)
except
KeyError
:
image
.
setAttribute
(
self
.
name
,
glData
)
pass
glData
=
glimagedata
.
GLImageData
(
image
,
self
.
xax
,
self
.
yax
)
image
.
setAttribute
(
self
.
name
,
glData
)
def
refresh
(
*
a
):
def
refresh
(
*
a
):
self
.
Refresh
()
self
.
Refresh
()
image
.
display
.
addListener
(
'
enabled
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
enabled
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
alpha
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
alpha
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
displayMin
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
displayMin
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
displayMax
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
displayMax
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
rangeClip
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
rangeClip
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
cmap
'
,
self
.
name
,
refresh
)
image
.
display
.
addListener
(
'
cmap
'
,
self
.
name
,
refresh
)
self
.
Refresh
()
self
.
Refresh
()
...
@@ -475,6 +478,12 @@ class SliceCanvas(wxgl.GLCanvas):
...
@@ -475,6 +478,12 @@ class SliceCanvas(wxgl.GLCanvas):
self
.
ymin
,
self
.
ymax
,
self
.
ymin
,
self
.
ymax
,
self
.
zmin
-
100
,
self
.
zmax
+
100
)
self
.
zmin
-
100
,
self
.
zmax
+
100
)
# I don't know why the above +/-100 is necessary :(
# I don't know why the above +/-100 is necessary :(
# The '100' is arbitrary, but it seems that I need
# to extend the depth clipping range beyond the
# range of the data. This is despite the fact that
# below, I'm actually translating the displayed
# slice to Z=0! I don't understand OpenGL sometimes.
# Most of the time.
gl
.
glMatrixMode
(
gl
.
GL_MODELVIEW
)
gl
.
glMatrixMode
(
gl
.
GL_MODELVIEW
)
gl
.
glLoadIdentity
()
gl
.
glLoadIdentity
()
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment