Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Different width/height for canvas and canvas style #3198

Open
shunia opened this issue Dec 31, 2024 · 1 comment
Open

[Feature] Different width/height for canvas and canvas style #3198

shunia opened this issue Dec 31, 2024 · 1 comment
Labels
module: rendering General rendering issues type: feature request 💡 Desired capabilities / enhancements

Comments

@shunia
Copy link

shunia commented Dec 31, 2024

Motivation

The canvas logical size, which is different than it's dom size(computed css style size).

I want to have them seperated so that I could set the logical size to the original size of the rendering texture, so that I could get the image data in the original resolution, but still be able to change the canvas dom size to fit the design.

Detailed Description

For now when calling setSize on a view, the logical size and the dom size are changed altogether, for example if I want to maintain the original resolution to 512512, I would want to call setSize(512, 512), but then the canvas dom size changed to 512512 too, which is not expected.

@shunia shunia added the type: feature request 💡 Desired capabilities / enhancements label Dec 31, 2024
@finetjul
Copy link
Member

I guess that's a fine request. Feel free to create a PR.
It would however have to come with a good interactive example because it is a tricky subjects that many face and got wrong.

@finetjul finetjul added the module: rendering General rendering issues label Dec 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module: rendering General rendering issues type: feature request 💡 Desired capabilities / enhancements
Projects
None yet
Development

No branches or pull requests

2 participants