Media Cache may be corrupt on the iMac.
You can delete it. It will rebuild automatically…though initially, it will take a long time. Maybe do it overnight. Should open fairly quickly after that.
If its still slow, then the problem lies elsewhere.
Does the MacBook have an SSD and the iMac a spinning drive?