I want to use vaapi with gstreamer for encoding and decoding purposes. I installed vainfo, it installed the essential drivers and everything worked fine for sometime but now it doesn't work anymore. It fails with error 'failed to initialize display'.
Complete Error Log:
error: can't connect to X server!error: failed to initialize display
I am using Ubuntu 22.04 with 13th Gen Intel(R) Core(TM) i5-13500 CPU.