obsproject / obsproject/obs-studio
image_source: failed to load texture
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 76.4k
- Forks
- 10.2k
- Avg merge
- 4d 23h
- Merged PRs (30d)
- 12
Description
Operating System Info
Windows 10
Other OS
No response
OBS Studio Version
30.0.2
OBS Studio Version (Other)
No response
OBS Studio Log URL
https://obsproject.com/logs/5sZ0XMq0qwdzsgF6
OBS Studio Crash Log URL
No response
Expected Behavior
OBS recognize that the resource has ben modified.
If the resource is delated clear it.
Try to load the new image. Can be fail if it is currently writed.
If ok update the resource, if it fails leave the previous image.
Current Behavior
OBS recognize that the resource has ben modified.
Clear the image.
Try to load the new image.
If it fails, you don't show the image.
Steps to Reproduce
- Add Image Source (like a png file)
- Fast update the image (like 2-3 times per second)
- You will notice that sometime the resource disappear (because it fail to load it)
- You have to refresh the image so OBS can notice it and try to reload else it stay cleared
Anything else we should know?
I have fix it on my computer, but I'm not familiar with GitHub and I prefer someone revised it.
I have reduce the check time from 1 sec to 0.5 sec (image_source_tick).
I have created a function only for update modified content image_source_modified.
Load the resource in memory and if it loaded ok copy in the current resource else destroy it.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the image_source_tick and image_source_modified functions, then reproduce the issue by updating a PNG two or three times per second on Windows 10. Use the linked OBS log for context. Done means a failed reload keeps the previous image visible, while a successful reload updates it and a deleted resource is cleared.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100