Part of it is software (drivers), and that’s something that hardware vendors have traditionally been poor at writing. The bar for a driver is “it technically works and doesn’t bluescreen” rather than “it works well”. It’s just more evident in this case because the continuous-input nature of a trackpad makes the poor functionality much more apparent.
The other is that I don’t think most laptop vendors spend nearly as much on their trackpads. MacBook trackpads have for a long time shared their touch sensitivity hardware with iPhones, which makes them extremely responsive and precise, and this is paired with a high end haptic motor to produce click sensations. Finally, their surface is oleophobic glass which reduces friction. This all combines to produce a great experience, but I’m positive that they cost notably more than the typical plastic diving board fare, and most laptop manufacturers are squeezing out margin with cheaper parts wherever they can.
The other is that I don’t think most laptop vendors spend nearly as much on their trackpads. MacBook trackpads have for a long time shared their touch sensitivity hardware with iPhones, which makes them extremely responsive and precise, and this is paired with a high end haptic motor to produce click sensations. Finally, their surface is oleophobic glass which reduces friction. This all combines to produce a great experience, but I’m positive that they cost notably more than the typical plastic diving board fare, and most laptop manufacturers are squeezing out margin with cheaper parts wherever they can.