No, this is not a tutorial. Rather, here is a nice cupcake idea from Magnolia Bakery, which sold this in honor of the season premiere for the TV show Dexter.
Looking at the picture, they used their Red Velvet with Vanilla Frosting Cupcake as the base. The “glass shard” is probably made out of sugar, while the “blood” is probably corn syrup dyed red. You can certainly try that at home, with so many Red Velvet Cupcake recipes online.
As for the “glass shards,” you can look at this good tutorial on Instructables.
You can just make the “glass” portion into bigger squares, and once it is set, use a knife or a small hammer to break if up to pieces. Then proceed to decorate your cupcake. Be sure to put a lot of “blood” and enjoy your bloody Halloween cupcake!