Beiträge von johns

    Das Zoom Feature einzubauen ist wirklich nicht schwiierig. Etwas Programmierkenntnisse vorausgesetzt.


    Suche Zoom. Es gibt mehrere Zoommethoden (enum) diese um ZoomUser1 ... ZoomUser2 erweitern.

    Beim Setzen des Zooms die Berechnung vom Benutzerzoom einbauen.

    Globale Variablen für den Benutzerzoom einbauen.


    Mehr Arbeit ist es im Setup und Menus einzubauen.


    Luxus Variante für spezielle Formate sollte auch nicht so schwierig sein.

    Rahmenerkennung ist ja für 4:3 in 16:9 schon vorhanden.

    Johns

    Auch wenn ich mich wiederhole. Bei der letzten Suche, war das Speicherleak, auch nicht weg, wenn mal alle SoftHdDevice Funktion auf noop gesetzt hatte.


    Code
    19:09:22 up 21 days, 11:38,  1 user,  load average: 0.30, 0.19, 0.16
    0000000000400000   1456K r-x-- vdr
    000000000076b000     68K r---- vdr
    000000000077c000      8K rw--- vdr
    000000000077e000    388K rw---   [ anon ]
    0000000001bd8000    136K rw---   [ anon ]
    0000000001bfa000 240616K rw---   [ anon ]

    Ist aber uralt VDR mit uralt SoftHdDevice.


    Johns

    Man muss im Source von softhddevice den OSD Puffer vergrößern. Ansonsten wird nichts mit 4k.

    Vielleicht ist deine Version schon gepatcht?


    Code
    static const uint8_t OsdZeros[1920 * 1200 * 4]; ///< 0 for clear osd

    und

    Code
    if (OsdWidth * OsdHeight > 1920 * 1200) {
    
    Error(_("video/vdpau: osd too big: unsupported\n"));
    
    return;
    
    }


    Ansonsten OSD fest auf 1920x1080 stellen und dann auf 4k skalieren.


    Johns


    The log is not so important, is the video smooth?


    I have a very simple renderer it outputs a frame every 1/50s or 1/60s which depends on your display rate. When the video is too slow, i show the last frame twice, if the video is to fast i skip frames. When i look into the log, it looks good, it just renders the video without any duplications or drops.


    Johns

    I don't know if it works, never tested this: You should set your X11 resolution to 60Hz.


    The repeat bit can't be set or be used in your source:

    Code
    if (frame->repeat_pict && !VideoIgnoreRepeatPict) {
    
    Warning(_("video: repeated pict %d found, but not handled\n"), frame->repeat_pict);


    I have this in the source and you get a big warning in the syslog, if it is found.

    Zitat

    "Don't expect anything from the input and just use the timestamps.


    This correct and bullshit. This is what I do and what you see is what happens.


    For good quality the X11 resolution must be a multiple of 20hz and 30hz.

    And then the renderer must render the frames multiple time to get them in correct sync.

    But this is not supported, by my render engine.


    Johns

    Also wenn ich es richtig sehe wird die PTS falsch berechnet oder falsch gesendet.


    Code
    2017.Aug.07|07:58:52 video: render frame pts 25:28:27.623 closing 0
    2017.Aug.07|07:58:53 video: render frame pts 25:28:27.673 closing 0
    2017.Aug.07|07:58:53 video: render frame pts 25:28:27.707 closing 0
    2017.Aug.07|07:58:53 video: render frame pts 25:28:27.757 closing 0
    2017.Aug.07|07:58:53 video: render frame pts 25:28:27.790 closing 0
    2017.Aug.07|07:58:53 video: render frame pts 25:28:27.840 closing 0
    2017.Aug.07|07:58:53 video: render frame pts 25:28:27.873 closing 0
    2017.Aug.07|07:58:53 video: render frame pts 25:28:27.923 closing 0


    623->673 = 50ms, 673->707 = 34ms, 707->757 = 50ms, 757->790 = 33ms, 790->840 = 50ms, 840->873 = 33ms, 873->923 = 50ms


    Looks like some speedup source material. Its a 20Hz frame interleaved with a 30Hz frame.
    I have no idea how to render this.


    The decoder and rendering looks ok. But my frame render didn't support dynamic frequency changes.


    Johns

    you must build with -DDEBUG otherwise all the debug macros aren't working.


    Code
    void VideoRenderFrame(VideoHwDecoder * hw_decoder,
        const AVCodecContext * video_ctx, const AVFrame * frame)
    {
    #if 0
        fprintf(stderr, "video: render frame pts %s closing %d\n",
            Timestamp2String(frame->pkt_pts), hw_decoder->Vdpau.Closing);
    #endif


    Change here the #if 0 to #if 1, here it prints every frame, if correct decoded.
    When this is ok, than the failure is in the display part.
    If here are frames missing, incorrect order, than the failure is in the decoder part.
    This logs to console and not syslog. If you need syslog change the fprintf(stderr, to Debug(2,


    Look if there are no errors in the syslog. I check some errors in the format.


    In CodecVideoDecode,

    Code
    Debug(4, "%s: %p %d -> %d %d\n", __FUNCTION__, pkt->data, pkt->size, used,
            got_frame);


    Chenge the 4 to 3 or less to see the debug.
    Here decodes ffmpeg 1 video packet to 1 video frame. The complete packet should be used
    and give 1 frame.


    With above debug you should see the message 50x per second (50 Hz station).


    Without any knowledge it is hard to find the bug. But MPEG, H264 and TS are well documented.
    And the failure is somewhere in the parsing.


    Johns

    LibreElec bzw. OpenElec sind minimalistische Betriebssysteme.
    Nicht vorgesehene Erweiterungen zuinstallieren ist schwierig, also nichts für nicht Linux Gurus.


    Wobei AutoFs und SshFs sollte nicht gebraucht werden. USB Platten, Sticks usw. werden automatisch eingebunden.
    Genauso SMB, NFS, SSHFS, ... kann eingebunden werden zum abspielen.


    Ansonsten gibts noch Armbian für vollwertiges Debian, aber nicht alles wird von Armbian unterstützt.


    Zitat


    Hier würde ich einfach https://osmc.tv/ empfehlen da es genau so wie raspbian auf debian basiert.


    Schweineteuer ARM. Dann gleich Intel mit 4K/60Hz Support nehmen.


    Johns

    Jede 30Euro S905 Kiste sollte es tun.


    Habe hier eine Probox2 Z, die funktioniert einwandfrei als Kodi Player mit LibreElec.
    Abspielen vom Server mit streamdev (HTTP) funktioniert ohne Probleme, ist aber nicht gut zubedienen.


    Aber mit vnsi habe ich Probleme. Habe Server -> Streamdev -> S905 -> Streamdev -> vnsi -> Kodi.
    Beiim Zappen bleibt es manchmal hängen, kann aber auch am komplizierten Weg liegen, aber auf
    meinem Server kommt kein Schrott VNSI.


    Leider hat Kodi den direkten streamdev Support entfernt, der ging früher immer gut.
    VNSI hat bei mir nie vernünftig funktioniert.


    Als Tipp würde ich auf die Fernbedienung achten und auf den Preis.
    Speicher 1GB oder 2GB ist eigentlich egal, merke keinen Unterschied mit Kodi.
    Flash 8GB oder 16GB ist auch egal, LibreElec habe ich auf SDHC, aber passt in 8GB.
    Netzwerk habe ich 1Gbit genommen, deshalb die obige Box, war die einzige <30Euro mit Gbit.


    Johns


    Werde ich im Endausbau ganz bestimmt machen.
    Kann man das einfach durch Aufruf von 'xrandr' erreichen? Was müsste ich denn dazu angeben?


    Entweder ist die Aulösung schon vorhanden.
    Dann "xrandr --rate 50", wenn nicht kappt, dann auch "xrandr --output LVDS-0 --mode 1920x1080 --rate 50".
    Mit z.b. glxgears kann ich einfach prüfen, ob auch wirklich umgeschaltet.


    Wenn Modus 50 Hz nicht erkannt wird, dann von Hand in xorg.conf eintragen.

    Code
    Section "Monitor"
    ....
        # 1920x1080p @ 50Hz (EIA/CEA-861B)
        ModeLine "1920x1080@50" 148.500 1920 2448 2492 2640 1080 1084 1089 1125 +hsync +vsync
    ---


    Man könnte neuen Mode auch mit xrandr anlegen, einfach man-Seite lesen.



    Sollten eigentlich zusammengefasst werden (über den Format String vom printf), entweder vergessen oder die Funktion stand an der Stelle nicht zur Verfügung.


    Zitat

    BTW: was hat es eigentlich in Meldungen wie


    Mar 1 10:50:14 vdr3 vdr: video: 21:55:09.357 +3 439 0/\ms 69+3 v-buf


    mit dem "/\" auf sich? Ist das ein Tippfehler oder hat das eine Bedeutung?


    Soll "Delta" dastellen, ist der Fehler in den Zeitstempeln, der in den Eingangs Paketen auftritt.
    Tritt durch ffmpeg/libav, kann sein, daß er inzwischen immer 0 ist.


    Johns

    Ja, der Monitor hat 60Hz. Danke für den Tipp, hab die Option jetzt mal eingeschaltet.


    Das Logging bei softhddevice muß echt verbessert werden, das geht so gar nicht.
    Mal sehen, wenn ich das künftig tatsächlich in meinem Haupt-VDR verwende muß ich da mal mit dem eisernen Besen auskehren ;-).


    Klaus


    Ich würde den Monitor auf 50Hz setzen. Mit 99% der Monitore geht es mit xrand 50 Hz zuerzwingen.
    (Zumindest mit NVidia Karten), sogar mein Laptop LCD läuft dann mit 50Hz.


    Es kommen nur Meldung wenn es nicht rund läuft, wenn alles in Ordnung ist, ist dann eigentlich Ruhe.
    Ohne die Meldungen hättest du nie nach der Ursache gesucht.


    Am Besten SoftHdDevice im VDR einbauen bzw, zuübernehmen oder Software Decoder Eigenbau.


    Johns

    Die Funktion, dass softhddevice den X-Server mitstartet, bringt nichts. Hat nie richtig funktioniert. Der X-Server ist immer zu spät da. Teile des OSDs werden verschluckt. Mit softhddevice muss ein X-Server bereit sein bevor der VDR gestartet wird. Nein, detaching wird nicht sein was Klaus will, denn auch dann sind teile des OSDs schon "abgefrühstückt" bevor eine Ausgabe bereit ist. Zum Beispiel entfällt dann das Aufpoppen der Kanal-Info beim Starten. Für Entwicklungszwecke würde ich die aber sehen wollen.


    Das ist aber kein Fehler, sondern ein Feature. Und wenn du umbedingt ein OSD willst, dann einfach eine Option für warten auf X11 Server einbauen.


    Wobei ich nicht sehe, warum man umbedingt ein OSD beim Starten sehen will. Anlernen der Fernbedienung hatte funktioniert.


    Johns