I am working on small pie chart visual in js and using Google charts SDK for the same
Everything works fine but when i sliced the pie and rotated pie start angle the sliced one is not coming in 3d
Expected chart :
Google chart with pie sliced and rotated looks like this
I need to get the sliced pie as like 3d sliced pie(green color) in the above image along with blue background for whole piechart
Attached the snipper for the same
and please let know if any other thing is need to fix this
<html>
<head>
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script type="text/javascript">
google.charts.load("current", {packages:["corechart"]});
google.charts.setOnLoadCallback(drawChart);
function drawChart() {
var data = google.visualization.arrayToDataTable([
['Task', 'Hours per Day'],
['Work', 75],
['Eat', 25],
]);
var options = {
title: 'My Daily Activities',
is3D: true,
slices: { 1: {offset: 0.2},
},
pieStartAngle: 100,
};
var chart = new google.visualization.PieChart(document.getElementById('piechart_3d'));
chart.draw(data, options);
}
</script>
</head>
<body>
<div id="piechart_3d" style="width: 900px; height: 500px;"></div>
</body>
</html>


i found that if you reverse the order of the rows,
you can get the 3d effect to display properly.
with the slices reversed, I've manually provided the colors to match the default.
the only other difference is the order of the legend entries.
see following working snippet...
EDIT
as for adding a background color to the chart area,
I wasn't able to get config option
chartArea.backgroundColorto work.as far as I can tell, for the pie chart, the entire chart is the chart area, unlike other charts.
the only other option I could come up with, would be to add a custom chart element on the chart's ready event.
finding the exact placement of the background element will be tricky.
I wasn't able to come up with anything quickly, I've left some hints on how that might be accomplished.
in the following example, the background element's placement is hard-coded, using a
<circle>element.but you could use any other element, such as
<rect>, or<path>...