mirror of
https://github.com/Palakis/obs-websocket.git
synced 2024-08-30 18:12:16 +00:00
requesthandler: Fix resolution of screenshots of cropped sources
This applies the same fix found in obsproject/obs-studio#10077 to get the target source's real width and height, not the width and height values from the pre-filter stage. Closes #1213
This commit is contained in:
parent
8c80e0745a
commit
5c3c4c76c8
@ -28,8 +28,8 @@ with this program. If not, see <https://www.gnu.org/licenses/>
|
||||
QImage TakeSourceScreenshot(obs_source_t *source, bool &success, uint32_t requestedWidth = 0, uint32_t requestedHeight = 0)
|
||||
{
|
||||
// Get info about the requested source
|
||||
const uint32_t sourceWidth = obs_source_get_base_width(source);
|
||||
const uint32_t sourceHeight = obs_source_get_base_height(source);
|
||||
const uint32_t sourceWidth = obs_source_get_width(source);
|
||||
const uint32_t sourceHeight = obs_source_get_height(source);
|
||||
const double sourceAspectRatio = ((double)sourceWidth / (double)sourceHeight);
|
||||
|
||||
uint32_t imgWidth = sourceWidth;
|
||||
|
Loading…
Reference in New Issue
Block a user