Question / Help x264 help?

TexasStu

New Member
Howdy!
I believe I am at the point where only x264 options might improve my twitch stream so I can run some charity streams (for American Cancer Society, American Heart Association, AbleGamers.org, AND Gamers Outreach Foundation - Project GO KARTS)

Example stream: https://www.twitch.tv/videos/347015399 (ring in the shadow of gas giant)
Example stream: https://www.twitch.tv/videos/347015399 (ring in the light)

Background: I live in a rural area and the maximum connection I can get (no cable company) is Uverse with ~6 Mbps Downstream & 1 Mbps Upstream
I have been working hard to try to be able to stream Elite: Dangerous with the intention of running some charity streams and I have been climbing the learning-curve that is Mt. Everest but I believe I'm stumped to see much more improvement without some help..
I have made excellent use of the posted resource for low upstream streamers ( https://obsproject.com/forum/resources/low-upload-speed-how-to-find-the-right-settings.185/ ) and I that the poster for that AWESOME resource!..
Here is my dxdiag and I added the OBS settings AT THE TOP of it.
------------------
OBS Settings:
-------------
OUTPUT: Advanced
x264 Encoder
CBR Rate Control
700 Bitrate
2 Keyframe Interval
veryfast CPU Usage
high Profile
animation Tune
-------------
VIDEO:
1280x720 Base (canvas) Resolution
640x360 Output (Scaled) Resolution
Lanczos Downscale Filter
34 FPS
__________________
DXDIAG (dump)
------------------
System Information
------------------
Time of this report: 12/9/2018, 14:23:37
Machine name: (name is changed to protect the innocent)
Machine Id: **********************************
Operating System: Windows 10 Home 64-bit (10.0, Build 17134) (17134.rs4_release.180410-1804)
Language: English (Regional Setting: English)
System Manufacturer: LENOVO
System Model: 90FL003GUS
BIOS: O2DKT20A (type: UEFI)
Processor: Intel(R) Core(TM) i7-6700 CPU @ 3.40GHz (8 CPUs), ~3.4GHz
Memory: 16384MB RAM
Available OS Memory: 16338MB RAM
Page File: 27387MB used, 8405MB available
Windows Dir: C:\WINDOWS
DirectX Version: DirectX 12
DX Setup Parameters: Not found
User DPI Setting: 96 DPI (100 percent)
System DPI Setting: 96 DPI (100 percent)
DWM DPI Scaling: Disabled
Miracast: Available, with HDCP
Microsoft Graphics Hybrid: Not Supported
DxDiag Version: 10.00.17134.0001 64bit Unicode

------------
DxDiag Notes
------------
Display Tab 1: No problems found.
Display Tab 2: No problems found.
Sound Tab 1: The file vbaudio_vmvaio64_win7.sys is not digitally signed, which means that it has not been tested by Microsoft's Windows Hardware Quality Labs (WHQL). You may be able to get a WHQL logo'd driver from the hardware manufacturer.
Sound Tab 2: The file vbaudio_cableb64_win7.sys is not digitally signed, which means that it has not been tested by Microsoft's Windows Hardware Quality Labs (WHQL). You may be able to get a WHQL logo'd driver from the hardware manufacturer.
Sound Tab 3: The file vbaudio_vmauxvaio64_win7.sys is not digitally signed, which means that it has not been tested by Microsoft's Windows Hardware Quality Labs (WHQL). You may be able to get a WHQL logo'd driver from the hardware manufacturer.
Sound Tab 4: No problems found.
Sound Tab 5: The file vbaudio_cablea64_win7.sys is not digitally signed, which means that it has not been tested by Microsoft's Windows Hardware Quality Labs (WHQL). You may be able to get a WHQL logo'd driver from the hardware manufacturer.
Sound Tab 6: No problems found.
Sound Tab 7: The file vbaudio_cablea64_win7.sys is not digitally signed, which means that it has not been tested by Microsoft's Windows Hardware Quality Labs (WHQL). You may be able to get a WHQL logo'd driver from the hardware manufacturer.
Sound Tab 8: No problems found.
Sound Tab 9: The file vbaudio_cable64_win7.sys is not digitally signed, which means that it has not been tested by Microsoft's Windows Hardware Quality Labs (WHQL). You may be able to get a WHQL logo'd driver from the hardware manufacturer.
Input Tab: No problems found.

--------------------
DirectX Debug Levels
--------------------
Direct3D: 0/4 (retail)
DirectDraw: 0/4 (retail)
DirectInput: 0/5 (retail)
DirectMusic: 0/5 (retail)
DirectPlay: 0/9 (retail)
DirectSound: 0/5 (retail)
DirectShow: 0/6 (retail)

---------------
Display Devices
---------------
Card name: NVIDIA GeForce GTX 1070
Manufacturer: NVIDIA
Chip type: GeForce GTX 1070
DAC type: Integrated RAMDAC
Device Type: Full Device (POST)
Device Key: Enum\PCI\VEN_10DE&DEV_1B81&SUBSYS_119D10DE&REV_A1
Device Status: 0180200A [DN_DRIVER_LOADED|DN_STARTED|DN_DISABLEABLE|DN_NT_ENUMERATOR|DN_NT_DRIVER]
Device Problem Code: No Problem
Driver Problem Code: Unknown
Display Memory: 16264 MB
Dedicated Memory: 8096 MB
Shared Memory: 8168 MB
Current Mode: 1920 x 1080 (32 bit) (60Hz)
HDR Support: Not Supported
Display Topology: Extend
Display Color Space: DXGI_COLOR_SPACE_RGB_FULL_G22_NONE_P709
Color Primaries: Red(0.650891,0.329602), Green(0.331555,0.622570), Blue(0.151867,0.053234), White Point(0.313977,0.329602)
Display Luminance: Min Luminance = 0.500000, Max Luminance = 270.000000, MaxFullFrameLuminance = 270.000000
Monitor Name: Generic PnP Monitor
Monitor Model: VG248
Monitor Id: ACI24A4
Native Mode: 1920 x 1080(p) (60.000Hz)
Output Type: Displayport External
Monitor Capabilities: HDR Not Supported
Display Pixel Format: DISPLAYCONFIG_PIXELFORMAT_32BPP
Advanced Color: Not Supported

In game: ( ELite: Dangerous )
I changed my DISPLAY SETTINGS/OPTIONS as follows:
RESOLUTION 1,280 x 720 (from 1,920 x 1,080)
FRAME RATE LIMIT 30 HZ (from OFF)
 

Attachments

  • OBS_logfile)2018-12-08 01-56-26.txt
    80.6 KB · Views: 13
  • DxDiag201812091420.txt
    95.4 KB · Views: 9
Last edited:

DEDRICK

Member
Considering your bitrate situation and the resolution you are running...crank your CPU Preset as high as it will go without Skipping frames.

@ 360p I would expect a 6700 to be able to do atleast Slow, possibly Slower or Very Slow, while barely impacting CPU usage / Skipped Frames or FPS in game. I see a Medium test in there with no skipped frames, so you should be able to do higher on CPU.

This is the only realistic way to increase the quality given the bitrate restriction, make x264 smarter with the bits it has.

Now, you're not doing yourself any favors by streaming over wireless, wire your PC to your router. All the stuttering in your test streams is from bandwidth, not CPU preset. Your max upload is 1Mbps to the speedtest server, not Twitch.

Code:
23:22:44.076: [x264 encoder: 'streaming_h264'] preset: medium
23:22:44.076: [x264 encoder: 'streaming_h264'] profile: high
23:22:44.076: [x264 encoder: 'streaming_h264'] tune: animation
23:22:44.076: [x264 encoder: 'streaming_h264'] settings:
23:22:44.076:     rate_control: CBR
23:22:44.076:     bitrate:      800
23:22:44.076:     buffer size:  800
23:22:44.076:     crf:          0
23:22:44.076:     fps_num:      35
23:22:44.076:     fps_den:      1
23:22:44.076:     width:        640
23:22:44.076:     height:       360
23:22:44.076:     keyint:       70
23:22:44.076:
23:22:44.095: ---------------------------------
23:22:44.095: [FFmpeg aac encoder: 'Track1'] bitrate: 64, channels: 2, channel_layout: 3
23:22:44.095:
23:22:44.098: [rtmp stream: 'adv_stream'] Connecting to RTMP URL rtmp://live-dfw.twitch.tv/app...
23:22:44.164: [rtmp stream: 'adv_stream'] Interface: Killer Wireless-n/a/ac 1535 Wireless Network Adapter (802.11, 866 mbps)
23:22:45.031: [rtmp stream: 'adv_stream'] Connection to rtmp://live-dfw.twitch.tv/app successful
23:22:45.038: ==== Streaming Start ===============================================
23:37:18.073: [rtmp stream: 'adv_stream'] User stopped the stream
23:37:18.073: Output 'adv_stream': stopping
23:37:18.073: Output 'adv_stream': Total frames output: 26798 (30493 attempted)
23:37:18.073: Output 'adv_stream': Total drawn frames: 30518 (30589 attempted)
23:37:18.073: Output 'adv_stream': Number of lagged frames due to rendering lag/stalls: 71 (0.2%)
23:37:18.073: Output 'adv_stream': Number of dropped frames due to insufficient bandwidth/connection stalls: 3695 (12.1%)
 
Last edited:

TryHD

Member
make your stream from somewhere else, you want viewer for a charity stream and with 360p you won't get any
 

TexasStu

New Member
I am currently in-process of changing over to wired (router to PC) but require some curved staples for IW install..
In the NEAR future I am having a dedicated (second) Uverse installed that will be exclusively for my computer (ONLY) and have it's own 'home-run' line from router to P.C.so that will not be a problem portion of this equation/solution.

How does the 'slow' mesh up with the 'Mid-Motion RTS' data (see: https://obsproject.com/forum/resources/low-upload-speed-how-to-find-the-right-settings.185/ ).. Today I have been seeing some (7.5%) frame losses and lowered Bitrate to 600 Kbps, veryfast, 27 FPS because of spiking or audio or a combination of things...
Using the cheat-graphic, 600 Kbps/veryfast/27 FPS is the only thing under 600 Kbps that is 'green'? All others are 'not recommended'?
I will do some testing with 600 Kbps/slow (increasing as I go) and apply the 21 FPS and see how it looks.
Thank you for your feedback! :-) It is very valuable to me to get it and kind or turn me in the correct direction and gently nudge me 'tat-a-way'! :-)
Enjoy!
Stu

Considering your bitrate situation and the resolution you are running...crank your CPU Preset as high as it will go without Skipping frames.

@ 360p I would expect a 6700 to be able to do atleast Slow, possibly Slower or Very Slow, while barely impacting CPU usage / Skipped Frames or FPS in game. I see a Medium test in there with no skipped frames, so you should be able to do higher on CPU.

This is the only realistic way to increase the quality given the bitrate restriction, make x264 smarter with the bits it has.

Now, you're not doing yourself any favors by streaming over wireless, wire your PC to your router. All the stuttering in your test streams is from bandwidth, not CPU preset. Your max upload is 1Mbps to the speedtest server, not Twitch.

Code:
23:22:44.076: [x264 encoder: 'streaming_h264'] preset: medium
23:22:44.076: [x264 encoder: 'streaming_h264'] profile: high
23:22:44.076: [x264 encoder: 'streaming_h264'] tune: animation
23:22:44.076: [x264 encoder: 'streaming_h264'] settings:
23:22:44.076:     rate_control: CBR
23:22:44.076:     bitrate:      800
23:22:44.076:     buffer size:  800
23:22:44.076:     crf:          0
23:22:44.076:     fps_num:      35
23:22:44.076:     fps_den:      1
23:22:44.076:     width:        640
23:22:44.076:     height:       360
23:22:44.076:     keyint:       70
23:22:44.076:
23:22:44.095: ---------------------------------
23:22:44.095: [FFmpeg aac encoder: 'Track1'] bitrate: 64, channels: 2, channel_layout: 3
23:22:44.095:
23:22:44.098: [rtmp stream: 'adv_stream'] Connecting to RTMP URL rtmp://live-dfw.twitch.tv/app...
23:22:44.164: [rtmp stream: 'adv_stream'] Interface: Killer Wireless-n/a/ac 1535 Wireless Network Adapter (802.11, 866 mbps)
23:22:45.031: [rtmp stream: 'adv_stream'] Connection to rtmp://live-dfw.twitch.tv/app successful
23:22:45.038: ==== Streaming Start ===============================================
23:37:18.073: [rtmp stream: 'adv_stream'] User stopped the stream
23:37:18.073: Output 'adv_stream': stopping
23:37:18.073: Output 'adv_stream': Total frames output: 26798 (30493 attempted)
23:37:18.073: Output 'adv_stream': Total drawn frames: 30518 (30589 attempted)
23:37:18.073: Output 'adv_stream': Number of lagged frames due to rendering lag/stalls: 71 (0.2%)
23:37:18.073: Output 'adv_stream': Number of dropped frames due to insufficient bandwidth/connection stalls: 3695 (12.1%)
 

TexasStu

New Member
I'm sorry but moving just isn't an option. Neither is streaming for 18+ hours from somewhere else.
But thank you for your suggestion. Unfortunately I do not see it being usable by myself.
Stu

make your stream from somewhere else, you want viewer for a charity stream and with 360p you won't get any
 

DEDRICK

Member
No need to be mathematical about it, or even use a chart:

Output Resolution - 360p
Video - 700Kbps
Audio - 64Kbps (This made me puke in my mouth a little)
FPS - 30 ( I don't recommend going below 30 FPS, it is not enjoyable to watch)
CPU Preset - Slower.
Test.

Do you Skip frames due to CPU usage? Yes? Preset is too high. No? Perfect.
Do you Drop frames due to bandwidth? Yes? Video Bitrate is too high. No? Speed of light is now faster
Does it sound glitchy, thin or generally not good? Audio bitrate is too low

Start with preset first, get it as high as you can do. A very small percentage of Skipped is fine (<1%)

Looking at that Medium log you had a total output bitrate of 864Kbps + CBR spikes, which amounted to 12% dropped frames. So to Twitch you are probably closer to 700-800 max throughput, you have to split that between Video and Audio. Doesn't matter how good you get the video if the audio sounds bad, so you have to balance it.
 

TexasStu

New Member
Ok! Thanks Dedrick for your help! :-) Here's the new changes and settings!
Webcam (C920) and Noise-canceling MIC/Headphones came in today (GAME ZERO)...
Ran the CAT-7 (shielded) ethernet cable. Started the process to get my own dedicated Uverse connection installed...

Tonight's SAMPLE: https://www.twitch.tv/videos/347528688

(SPOILER is the OBS Settings I used)
OUTPUT: Advanced
x264 Encoder
CBR Rate Control
700 Bitrate
2 Keyframe Interval
slower CPU Usage
high Profile
animation Tune

AUDIO:
44.1 Hz
Stereo Channels
Disabled Desktop Audio Device
Disabled Desktop Audio Device 2
CABLE-A Output (VB-Audio Cable A) Mic/Aux Audio Device
VoiceMeeter Aux Output (VB-Audio VoiceMeeter AUX VAIO)
Fast Audio Meter Decay Rate
Sample Peak Peak Meter Type

VIDEO:
1280x720 Base (canvas) Resolution
640x360 Output (Scaled) Resolution
Lanczos Downscale Filter
30 FPS
 

Attachments

  • 2018-12-10 19-18-43.txt
    13.1 KB · Views: 12

DEDRICK

Member
That actually worked out considerably well given the restrictions, it really comes down to the source you are encoding. It doesn't fall apart into a screen of macroblocks during motion, sure it's not very clear but it is half the resolution of 720p at 700 Kbps. You could try Bicubic instead of Lanczos, Lanczos is a little harsh on the sharpening sometimes.

Couple hitches here and there

Less than 1% Skipped on Slower, Less than 1% for Bandwidth too. I am willing to bet they happened together as well as more difficult frames require more bits.


Code:
19:56:02.972: [x264 encoder: 'streaming_h264'] preset: slower
19:56:02.972: [x264 encoder: 'streaming_h264'] profile: high
19:56:02.972: [x264 encoder: 'streaming_h264'] tune: animation
19:56:02.972: [x264 encoder: 'streaming_h264'] settings:
19:56:02.972:     rate_control: CBR
19:56:02.972:     bitrate:      700
19:56:02.972:     buffer size:  700
19:56:02.972:     crf:          0
19:56:02.972:     fps_num:      30
19:56:02.972:     fps_den:      1
19:56:02.972:     width:        640
19:56:02.972:     height:       360
19:56:02.972:     keyint:       60
19:56:02.972:
19:56:02.993: ---------------------------------
19:56:02.994: [FFmpeg aac encoder: 'Track1'] bitrate: 64, channels: 2, channel_layout: 3
19:56:02.994:
19:56:03.046: [rtmp stream: 'adv_stream'] Connecting to RTMP URL rtmp://live-dfw.twitch.tv/app...
19:56:03.086: [rtmp stream: 'adv_stream'] Interface: Killer E2400 Gigabit Ethernet Controller (ethernet, 1000 mbps)
19:56:03.964: [rtmp stream: 'adv_stream'] Connection to rtmp://live-dfw.twitch.tv/app successful
19:56:03.968: ==== Streaming Start ===============================================
20:00:24.248: User switched to scene 'Slideshow'
20:45:07.511: User switched to scene 'AFK01'
20:45:11.513: User switched to scene 'LIVE STREAM'
20:51:54.873: [rtmp stream: 'adv_stream'] User stopped the stream
20:51:54.873: Output 'adv_stream': stopping
20:51:54.873: Output 'adv_stream': Total frames output: 99594 (100431 attempted)
20:51:54.873: Output 'adv_stream': Total drawn frames: 100549 (100555 attempted)
20:51:54.873: Output 'adv_stream': Number of lagged frames due to rendering lag/stalls: 6 (0.0%)
20:51:54.873: Output 'adv_stream': Number of dropped frames due to insufficient bandwidth/connection stalls: 837 (0.8%)
20:51:54.873: [rtmp stream: 'adv_stream'] Freeing 1 remaining packets
20:51:54.874: Video stopped, number of skipped frames due to encoding lag: 868/100524 (0.9%)
 
Top