30.
7945 requires 12W.
From 3560 Q&A -
Q. How many devices can the Cisco Catalyst 3560 Series power?
A. The Cisco Catalyst 3560 Series 24-port PoE configurations can support 24 simultaneous full-powered PoE ports at 15.4W for maximum powered device support. Using Cisco Catalyst Intelligent Power Management, the 48-port version can deliver the necessary power to support 24 ports at 15.4W, 48 ports at 7.7W, or any combination in between. The Cisco Catalyst 3560 Compact Switch can support 8 simultaneous full-powered PoE ports at 15.4W.
Use the PoE Calculator tool for any such calculations in future -
http://tools.cisco.com/cpc/PDS.cpc
Hope this helps.
-> Sushil