OnVif and OpenWrt?

Hi, I have some questions about OpenWrt:

1.OpenWrt is basically Linux headless PC?
So i could instal custom software/service on it?

  1. https://github.com/KoynovStas/onvif_srvd
    This Linux OnVif service from git-hub repo could be installed as custom package on OpenWrt? (if you have know how)

  2. Is there any limitation in OpenWrt software that I could not run OnVif services only on WAN interface of router instead of LAN? (Rutter would behave as IP Camera, It would provide RTSP service on 554 port and OnVif service on port 80 and 443)

  3. Is there any active OpenWrt project which turn router to IP PTZ camera? I have seen that there is a lot of support for USB cameras in OpenWrt (Video4Linux2)

  4. Is there any active project to turn router with OpenWrt to NDVR(Network Digital Video Recorder)?

Make sure to check system requirements.
Your device must be powerful enough to handle the task.
Otherwise it's pointless.

This is the bare minimum you need to study:

  1. You can use ffmpeg and record video on USB Storage. Most routers have almost no Space for user data, so external Storage is required (you also can use some network FS like sshfs, FTP etc.). And you are limited to only copy stream into file without conversion on the fly, due to low computing power of CPU. I have working poc using asus ac51u and camera that stream 1080p 25fps with mono sound H.264 on port 554. Average load is about 0.5 when I use Luci to visualise load. So I think one router like mine can handle maximum 2 camera maybe 3 or 4 with some optimalization or in lower resolution.