You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Error: SDL failed to get a vertex buffer for this Direct3D 9 rendering batch #1441
Whenever I started the scrcpy.exe, the following error shows on the console. The scrcpy itself works as usual, although a little slow. I'm not sure if the slowness is related to this error.
[server] INFO: Device: Xiaomi MI 8 (Android 10)
INFO: Created renderer: direct3d
INFO: Renderer: direct3d
INFO: Initial texture: 1080x2248
ERROR: SDL failed to get a vertex buffer for this Direct3D 9 rendering batch!
ERROR: Dropping back to a slower method.
ERROR: This might be a brief hiccup, but if performance is bad, this is probably why.
ERROR: This error will not be logged again for this renderer.
<...>\scrcpy\scrcpy-server: 1 file pushed, 0 skipped. 45.5 MB/s (33142 bytes in 0.001s)
[server] INFO: Device: LGE Nexus 5X (Android 8.1.0)
INFO: Created renderer: direct3d
INFO: Renderer: direct3d
INFO: Initial texture: 1080x1920
ERROR: SDL failed to get a vertex buffer for this Direct3D 9 rendering batch!
ERROR: Dropping back to a slower method.
ERROR: This might be a brief hiccup, but if performance is bad, this is probably why.
ERROR: This error will not be logged again for this renderer.
As per @rom1v recommendation replaced SDL2.dll from v1.14 package with the one from v1.12 package, but get still get the same error.
I have still encountered the same error with v1.13,
C:\scrcpy\scrcpy-server: 1 file pushed, 0 skipped. 31.1 MB/s (33142 bytes in 0.001s)
[server] INFO: Device: motorola moto g(6) (Android 8.0.0)
INFO: Created renderer: direct3d
INFO: Renderer: direct3d
INFO: Initial texture: 2160x1080
ERROR: SDL failed to get a vertex buffer for this Direct3D 9 rendering batch!
ERROR: Dropping back to a slower method.
ERROR: This might be a brief hiccup, but if performance is bad, this is probably why.
ERROR: This error will not be logged again for this renderer.
INFO: New texture: 1080x2160
@rom1v, When I switched to the former v1.12, I encountered much less keyboard and screen lag on the device. I was running minecraft on the phone and controlling the phone with the keyboard.
Is the lag due to the vertex buffer? Also, on v1.12, I still encounter some lag. Is there any way to improve responsiveness?
When I switched to the former v1.12, I encountered much less keyboard and screen lag on the device. I was running minecraft on the phone and controlling the phone with the keyboard.
If you switch back and forth between v1.12 and v1.14, do you actually always see a difference?
Also, on v1.12, I still encounter some lag.
Is the lag on the device or on the computer?
If you record with scrcpy --record file.mkv, and play the file, is the lag recorded/visible? (if yes, it's on the device, if no, it's on the computer when rendering).
@rom1v Copying the SDL2.dll file from v1.12 into the v1.14 did not alleviate the problem. Rather, I had to run the older v1.12 version entirely by itself.
The lag is on both the phone and the computer. I haven't tried usingscrcpy --record file.mkv yet, but I may try later. The lag often occurs from pressing a key on the keyboard, where once I let go of the key, the movement on both the phone and the computer screen will continue to occur.
If I use the phone screen instead, the movement on the phone does not lag. Instead, the lag is only on the computer screen. If I were to let go of the key on the phone, all movement immediately comes to a stop.
its the problem with the Android home screen just open an application and run scrcpy.exe
D:#downloads\scrcpy\scrcpy-server: 1 file pushed, 0 skipped. 40.0 MB/s (33142 bytes in 0.001s)
[server] INFO: Device: OnePlus ONEPLUS A6000 (Android 10)
INFO: Created renderer: direct3d
INFO: Renderer: direct3d
INFO: Initial texture: 2280x1080
In my case, i face the error only when i connect my device to ADB via WIFI.
When I tried plugging my device via USB, everything seems to work fine. (My wifi router, desktop and mobile all are in the same table).
Thank you for the reply 😍.. I have a dedicated GPU.. RTX 2060. But I am not sure which GPU is being used for rendering. Does it matter? If so could you help me make sure i use the right one?
Reporting back as promised. The error disappeared if if used --render-driver=opengl so maybe direct3d is the issue.
The performance looked a bit sluggish anyway and the FPS didn't improve much, but maybe it's just how it is :)
On Windows, performance should be better with direct3d (but you may want opengl for mipmapping #40).
If you press Ctrl+i in the scrcpy window, it will print framerate in the console. What do you get? (copy-paste the output)
Note that a frame is produced by the device only when the device content change (so for example if you play a video at 25fps on your Android device, mirroring framerate will not be higher than 25fps).
If you don't get any +n frames dropped, then there is globally no lag on the computer side (there might be jitter, but over USB it should be very small).
So if it feels laggy, it's probably from the device.
Try with a lower definition, the device might be faster (scrcmy -m800).
Activity
rom1v commentedon May 28, 2020
Might be related to SDL 2.0.12.
Try to replace
SDL2.dllin your v1.14 release by the one released in v1.12 (SDL 2.0.10).StephenW789 commentedon May 28, 2020
I have encountered the same problem. How do we obtain the SDL2.dll file in the v1.12?
rom1v commentedon May 28, 2020
https://github.com/Genymobile/scrcpy/releases/download/v1.12.1/scrcpy-win64-v1.12.1.zip
mrplumber commentedon May 28, 2020
I have the same issue:
As per @rom1v recommendation replaced
SDL2.dllfrom v1.14 package with the one from v1.12 package, but get still get the same error.StephenW789 commentedon May 28, 2020
Yes, same as @mrplumber, I have replaced the file, but still encounters the same error.
rom1v commentedon May 28, 2020
OK. Do you encounter this error on scrcpy v1.13?
If not, i'll have to bisect to find the culprit. Maybe something in #1408.
mrplumber commentedon May 28, 2020
@rom1v this the console output when I start v1.13:
StephenW789 commentedon May 28, 2020
Using the link: https://github.com/Genymobile/scrcpy/releases/download/v1.13/scrcpy-win64-v1.13.zip,
I have still encountered the same error with v1.13,
rom1v commentedon May 28, 2020
OK, I bisected,
bisect/badis a3ef461.Therefore, this is just due to a change in internal SDL logs that have been enabled.
I will investigate and do not enable them all, but there is no change in behavior.
StephenW789 commentedon May 28, 2020
@rom1v, When I switched to the former v1.12, I encountered much less keyboard and screen lag on the device. I was running minecraft on the phone and controlling the phone with the keyboard.
Is the lag due to the vertex buffer? Also, on v1.12, I still encounter some lag. Is there any way to improve responsiveness?
rom1v commentedon May 28, 2020
If you switch back and forth between v1.12 and v1.14, do you actually always see a difference?
Is the lag on the device or on the computer?
If you record with
scrcpy --record file.mkv, and play the file, is the lag recorded/visible? (if yes, it's on the device, if no, it's on the computer when rendering).Reduce definition:
StephenW789 commentedon May 28, 2020
@rom1v Copying the SDL2.dll file from v1.12 into the v1.14 did not alleviate the problem. Rather, I had to run the older v1.12 version entirely by itself.
The lag is on both the phone and the computer. I haven't tried using
scrcpy --record file.mkvyet, but I may try later. The lag often occurs from pressing a key on the keyboard, where once I let go of the key, the movement on both the phone and the computer screen will continue to occur.If I use the phone screen instead, the movement on the phone does not lag. Instead, the lag is only on the computer screen. If I were to let go of the key on the phone, all movement immediately comes to a stop.
rom1v commentedon May 28, 2020
Try reducing the definition:
Does the lag still happen?
StephenW789 commentedon May 28, 2020
Unfortunately, the lag still occurs on v1.14 even with the reduced definition.
StephenW789 commentedon May 28, 2020
On v1.12, with the reduced definition, there also is still lag. But it is noticably less than v1.14
31 remaining items
tamkmutnb commentedon Jul 23, 2020
I did solver my issue by unplug the cable and re-plug it and do the whole command again.
tamkmutnb commentedon Jul 23, 2020
how to update my scrcpy.
Artanisx commentedon Jul 26, 2020
Hello!
Loving your program :-)
I wanted to report I have the same issue.
OS: Windows 10
scrcpy version: 1.14
installation method: scoop install
device model: Samsung Galaxy S9 (Android 10)
Android version: 10
adb version: 30.0.3
Performance is a bit sluggish, probably because of this issue. Thanks for the help :)
rom1v commentedon Jul 26, 2020
Does it work better in scrcpy v1.9 or v1.10?
If so, just take the SDL2.dll from these versions, and replace them in your v1.14 folder.
Artanisx commentedon Jul 26, 2020
1.14 is the first version I tried. I'll try some older versions and I'll report back :)
daniedev commentedon Jul 27, 2020
I tried your way but the issue still exists!!
daniedev commentedon Jul 27, 2020
In my case, i face the error only when i connect my device to ADB via WIFI.
When I tried plugging my device via USB, everything seems to work fine. (My wifi router, desktop and mobile all are in the same table).
Could this be fixed?
rom1v commentedon Jul 27, 2020
Oh, the lag is expected then, on wifi you typically need to decrease the definition/bitrate:
daniedev commentedon Jul 27, 2020
Thank you for the reply 😍.. I have a dedicated GPU.. RTX 2060. But I am not sure which GPU is being used for rendering. Does it matter? If so could you help me make sure i use the right one?
Thank you in advance☺️
Artanisx commentedon Jul 27, 2020
Reporting back as promised. The error disappeared if if used --render-driver=opengl so maybe direct3d is the issue.
The performance looked a bit sluggish anyway and the FPS didn't improve much, but maybe it's just how it is :)
daniedev commentedon Jul 27, 2020
oh, Lets hope there will be a way to improve this. Thank you @Artanisx @rom1v for the support. 😃
rom1v commentedon Jul 27, 2020
On Windows, performance should be better with direct3d (but you may want opengl for mipmapping #40).
If you press Ctrl+i in the scrcpy window, it will print framerate in the console. What do you get? (copy-paste the output)
Note that a frame is produced by the device only when the device content change (so for example if you play a video at 25fps on your Android device, mirroring framerate will not be higher than 25fps).
Artanisx commentedon Jul 27, 2020
I get around 30 fps (sometime less). The numbers were similar with Direct3D though, I don't think there was much difference all in all. :)
rom1v commentedon Jul 27, 2020
If you don't get any
+n frames dropped, then there is globally no lag on the computer side (there might be jitter, but over USB it should be very small).So if it feels laggy, it's probably from the device.
Try with a lower definition, the device might be faster (
scrcmy -m800).Artanisx commentedon Jul 27, 2020
I get some +n frames dropped but indeed it's not that frequent.
I'll try with a lower definition and report back :)
EDIT:
Using -m800 the framerate improved indeed (between 25-40), but it's too low res (text can't be read).
Without -m800 I get:
INFO: 25 fps
INFO: 29 fps
INFO: 29 fps
INFO: 30 fps
INFO: 29 fps
INFO: 29 fps
INFO: 29 fps
INFO: 30 fps
INFO: 20 fps
INFO: 27 fps
INFO: 20 fps
INFO: 30 fps
INFO: 29 fps
INFO: 29 fps
INFO: 29 fps
INFO: 22 fps (+8 frames skipped)
Last was before closing so probably it was a micro stutter.
It's possible it's just my device (Samsung Galaxy S9) which is not powerful enough (or the game is too demanding: Legends of Runeterra)!