In Cognitive Radio (CR) networks, the licensed but vacant spectrum bands are assigned to the CR users in an opportunistic manner. These assignments should be realized according to the activities of the licensed users in the spectrum as well as the throughput requirements of the CR users. Considering these two main challenges, in this paper, we investigate the spectrum assignment problem in centralized cognitive radio (CR) networks using a cross-layer perspective. The proposed cross-layer approach, so-called Xpec, combines the observation of the licensed users' activities and the throughput requirements of the CR users. More specifically, Xpec takes the SNR observations of the licensed users' activities from the physical layer and the throughput requests of the CR users from the MAC layer to derive a weighted spectrum assignment strategy. The evaluations show that the proposed Xpec provides higher spectrum utilization and better fairness than the traditional layered strategy under heterogeneous channel conditions.