As others have said i think wood can very smooth after sanding and varnishing. Physics was a long time ago, but it is also important to add that if you weigh 100kg that would be 50kg of force on both sides, plus include a little jumping and jerking and is your wood able to withstand that sort of force without compressing? Some hard woods perhaps, but Pine, i dont htink so.
A lot of pressure is needed to prevent the bar from slipping under load. A door frame could give way here. There is also more friction with masonry than with a smooth door frame.