Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
6814acb6
Commit
6814acb6
authored
Mar 24, 2016
by
GoshaZotov
Committed by
Alexander.Trofimov
May 19, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
изменил очередность отрисовки граней для hbar chart
parent
1ef99f08
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
47 additions
and
2 deletions
+47
-2
common/Charts/ChartsDrawer.js
common/Charts/ChartsDrawer.js
+47
-2
No files found.
common/Charts/ChartsDrawer.js
View file @
6814acb6
...
@@ -5943,7 +5943,24 @@ drawHBarChart.prototype =
...
@@ -5943,7 +5943,24 @@ drawHBarChart.prototype =
paths
=
this
.
cChartDrawer
.
calculateRect3D
(
point1
,
point2
,
point3
,
point4
,
point5
,
point6
,
point7
,
point8
,
val
);
paths
=
this
.
cChartDrawer
.
calculateRect3D
(
point1
,
point2
,
point3
,
point4
,
point5
,
point6
,
point7
,
point8
,
val
);
this
.
sortZIndexPaths
.
push
({
seria
:
i
,
point
:
idx
,
paths
:
paths
,
x
:
point1
.
x
,
y
:
point1
.
y
,
zIndex
:
point1
.
z
});
//расскомментируем, чтобы включить старую схему отрисовки(+ переименовать функции _DrawBars3D -> _DrawBars3D2)
//this.sortZIndexPaths.push({seria: i, point: idx, paths: paths, x: point1.x, y: point1.y, zIndex: point1.z});
width
=
this
.
chartProp
.
widthCanvas
-
this
.
chartProp
.
chartGutter
.
_left
-
this
.
chartProp
.
chartGutter
.
_right
;
var
controlPoint1
=
this
.
cChartDrawer
.
_convertAndTurnPoint
(
x5
+
width
/
2
,
y5
-
individualBarHeight
/
2
,
z5
);
var
controlPoint2
=
this
.
cChartDrawer
.
_convertAndTurnPoint
(
x5
+
width
/
2
,
y5
,
z5
+
perspectiveDepth
/
2
);
var
controlPoint3
=
this
.
cChartDrawer
.
_convertAndTurnPoint
(
x5
,
y5
-
individualBarHeight
/
2
,
z5
+
perspectiveDepth
/
2
);
var
controlPoint4
=
this
.
cChartDrawer
.
_convertAndTurnPoint
(
x8
,
y8
-
individualBarHeight
/
2
,
z8
+
perspectiveDepth
/
2
);
var
controlPoint5
=
this
.
cChartDrawer
.
_convertAndTurnPoint
(
x1
+
width
/
2
,
y1
,
z1
+
perspectiveDepth
/
2
);
var
controlPoint6
=
this
.
cChartDrawer
.
_convertAndTurnPoint
(
x6
+
width
/
2
,
y6
-
individualBarHeight
/
2
,
z6
);
var
sortPaths
=
[
controlPoint1
,
controlPoint2
,
controlPoint3
,
controlPoint4
,
controlPoint5
,
controlPoint6
];
for
(
var
k
=
0
;
k
<
paths
.
length
;
k
++
)
{
this
.
sortZIndexPaths
.
push
({
seria
:
i
,
point
:
idx
,
verge
:
k
,
paths
:
paths
[
k
],
x
:
sortPaths
[
k
].
x
,
y
:
sortPaths
[
k
].
y
,
zIndex
:
sortPaths
[
k
].
z
});
}
}
}
else
else
{
{
...
@@ -6330,7 +6347,7 @@ drawHBarChart.prototype =
...
@@ -6330,7 +6347,7 @@ drawHBarChart.prototype =
},
},
_DrawBars3D
:
function
()
_DrawBars3D
3
:
function
()
{
{
var
t
=
this
;
var
t
=
this
;
var
processor3D
=
this
.
cChartDrawer
.
processor3D
;
var
processor3D
=
this
.
cChartDrawer
.
processor3D
;
...
@@ -6387,6 +6404,34 @@ drawHBarChart.prototype =
...
@@ -6387,6 +6404,34 @@ drawHBarChart.prototype =
}
}
},
},
_DrawBars3D
:
function
()
{
var
t
=
this
;
var
processor3D
=
this
.
cChartDrawer
.
processor3D
;
var
drawVerges
=
function
(
i
,
j
,
paths
,
onlyLessNull
,
k
)
{
var
brush
,
pen
,
options
;
options
=
t
.
_getOptionsForDrawing
(
i
,
j
,
onlyLessNull
);
if
(
paths
!==
null
&&
options
!==
null
)
{
pen
=
options
.
pen
;
brush
=
options
.
brush
;
t
.
_drawBar3D
(
paths
,
pen
,
brush
,
k
);
}
};
for
(
var
i
=
0
;
i
<
this
.
sortZIndexPaths
.
length
;
i
++
)
{
drawVerges
(
this
.
sortZIndexPaths
[
i
].
seria
,
this
.
sortZIndexPaths
[
i
].
point
,
this
.
sortZIndexPaths
[
i
].
paths
,
true
,
this
.
sortZIndexPaths
[
i
].
verge
);
}
for
(
var
i
=
0
;
i
<
this
.
sortZIndexPaths
.
length
;
i
++
)
{
drawVerges
(
this
.
sortZIndexPaths
[
i
].
seria
,
this
.
sortZIndexPaths
[
i
].
point
,
this
.
sortZIndexPaths
[
i
].
paths
,
false
,
this
.
sortZIndexPaths
[
i
].
verge
);
}
},
_drawBar3D
:
function
(
path
,
pen
,
brush
,
k
)
_drawBar3D
:
function
(
path
,
pen
,
brush
,
k
)
{
{
...
...
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