Solved

3D effects in SVG

Posted on 2001-07-09
3
276 Views
Last Modified: 2008-02-01
I have the following SVG code that generates pie chart.
I need to add some 3D effect on it - even just shadow or something like this.
It is urgent.

<?xml version="1.0" standalone="yes"?>
<svg width="800" height="600">
<g id="series">
<path id="1" d="M 320 112.5 A 162.5 162.5 0 1 1 199.238938 383.733788 L 320 275 Z" style="fill:tomato"/>
<path id="2" d="M 199.238938 383.733788 A 162.5 162.5 0 0 1 168.29325 333.2348 L 320 275 Z" style="fill:magenta"/>
<path id="3" d="M 168.29325 333.2348 A 162.5 162.5 0 0 1 183.715962 186.496162 L 320 275 Z" style="fill:brown"/>
<path id="4" d="M 183.715962 186.496162 A 162.5 162.5 0 0 1 195.51785 170.54695 L 320 275 Z" style="fill:blue"/>
<path id="5" d="M 195.51785 170.54695 A 162.5 162.5 0 0 1 277.941913 118.037025 L 320 275 Z" style="fill:green"/>
<path id="6" d="M 277.941913 118.037025 A 162.5 162.5 0 0 1 320 112.5 L 320 275 Z" style="fill:indigo"/>
</g>
</svg>

Thanks.
0
Comment
Question by:pavlin
3 Comments
 
LVL 2

Accepted Solution

by:
djokov earned 200 total points
Comment Utility
<?xml version="1.0" standalone="yes"?>
<svg width="800" height="600">
<filter id="DropShadowFilter" filterUnits="objectBoundingBox" x="-10%" y="-10%" width="120%" height="120%">
   <feGaussianBlur in="SourceAlpha" stdDeviation="2" result="BlurAlpha"/>
   <feOffset in="BlurAlpha" dx="4" dy="4" result="OffsetBlurAlpha"/>
   <feMerge>
      <feMergeNode in="OffsetBlurAlpha"/>
      <feMergeNode in="SourceGraphic"/>
   </feMerge>
</filter>
<g id="series" style="filter:url(#DropShadowFilter)" transform="scale(1 0.5)">
<path id="1" d="M 320 112.5 A 162.5 162.5 0 1 1 199.238938 383.733788 L 320 275 Z" style="fill:tomato"/>
<path id="2" d="M 199.238938 383.733788 A 162.5 162.5 0 0 1 168.29325 333.2348 L 320 275 Z" style="fill:magenta"/>
<path id="3" d="M 168.29325 333.2348 A 162.5 162.5 0 0 1 183.715962 186.496162 L 320 275 Z" style="fill:brown"/>
<path id="4" d="M 183.715962 186.496162 A 162.5 162.5 0 0 1 195.51785 170.54695 L 320 275 Z" style="fill:blue"/>
<path id="5" d="M 195.51785 170.54695 A 162.5 162.5 0 0 1 277.941913 118.037025 L 320 275 Z" style="fill:green"/>
<path id="6" d="M 277.941913 118.037025 A 162.5 162.5 0 0 1 320 112.5 L 320 275 Z" style="fill:indigo"/>
</g>
</svg>

Will help.
0
 

Author Comment

by:pavlin
Comment Utility
Yes! Thanx friend..
0
 

Expert Comment

by:frankg77777
Comment Utility
pavlin, djokov-
how did you create the vectors for the pie pieces?  can you do it on the fly via transformations or scripting?
i have been unable to even create separate shapes in Illustrator.
thanks
frankg77777
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

The Problem How to write an Xquery that works like a SQL outer join, providing placeholders for absent data on the outer side?  I give a bit more background at the end. The situation expressed as relational data Let’s work through this.  I’ve …
Browsing the questions asked to the Experts of this forum, you will be amazed to see how many times people are headaching about monster regular expressions (regex) to select that specific part of some HTML or XML file they want to extract. The examp…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now