Is it possible to write an encoder and decoder generic lib using CUDA programming which can support all nvidia boards and G...

I want to write encoder and decoder lib and i have many laptops which supports nvidia but the problem is that some laptops are quite old which does not support NvEnc and NvDec so is it possible to write a generic code for all systems. If it is possible pls share me the sample link which can run on all systems of nvidia.