The endocardium underlies the much more voluminous myocardium, the muscular tissue responsible for the contraction of the heart. The outer layer of the heart is termed epicardium and the heart is surrounded by a small amount of fluid enclosed by a fibrous sac called the pericardium. 1 Function.