how to change panel height and width values ​​while the program is running

Panel width and height values ​​are set to const. Therefore, I cannot change the panel values ​​again while the program is running. When I delete the const statement, the program gives an error. How can I set the panel values ​​while the program is running, or what other files should I change after deleting the const expression?

You can’t change them, the library wasn’t designed for dynamic display configuration. For ESP32 only, I have some test code that can configure the display before calling start, but needs a reboot to apply a new config

I would like to see these test codes. I would be very happy if you share

I am wondering why do you need to change panel dimensions during program run?

Because the end user should be able to increase the panel size whenever he wants. Developed software should offer this option to the user

The code is already in the SmartMatrix Library repo, inside the _NT (no templates) class. Here’s a complicated sketch that uses the _NT class, the most important parts are here:

There’s a good reason why this is not offered, compiling the width/height/etc in to the refresh class increases the efficiency by about 25%, and there are very few reasons why people need to change the parameters at runtime.

Thank you very much Louis.