Pinch-to-zoom is handled by libinput, and exposed to gtk apps. Works fine in firefox. Works in GtkWebkit views. works in Loupe the image viewer. works in Gnome Maps. Even works in Emacs, ffs.
Are you on X or smth?
I have no idea why you've been downvoted? Touchpad pinch-to-zoom has worked out of the box for years now (and also works fine on X11, also).
I'm actually on a desktop without a touchpad.