Main Menu
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - Danetta

#1
Help requests / Texture Class
21 January 2017, 07:56:32
Hello.

I spent some time writing resource manager, but then I noticed that tgui::Picture, unlike sf::Sprite, doesn't need it Texture to be alive after setTexture has been called. Is it true? If so, I can get rid of all the ptrs I used because it will work just fine like this:

1. Create/Load sf::texture.
2. Bind texture to tgui::Picture.
3. Don't care about sf::Texture anymore, tgui::Picture has stored the object itself and not a pointer.

How is it implemented? Is there any unneeded work transfering the texture? Or it just pointer transformed into something like shared_ptr so it will be saved without any additional memory management?

Also, what's the purpose for tgui::Texture class? I saw some widgets require it, but they also fine with sf::Texture.
#2
Help requests / CPU-Heavy Scrolling
03 January 2017, 15:18:04
Hello.

I used this example of how to create a scrollable panel, but adjusted it to work with TGUI 0.7 (connectEx instead of bindCallbackEx). I created panel with a size of 1080*620 and placed 6 widgets on it (all of them are labels with 5-10 symbols of text). I also set maximum for scrollbar to 1240 (double of panel size). It seems that scrolling is very cpu-heavy even in this case, but I intended to add more than just 6 label on panel. Lag is not very noticeable, but is still is compared to empty scrolling. Is it the constant moving of widgets causing this?
#3
Help requests / Possible bug with button (or more)
07 December 2016, 17:49:50
Hello.
I used a code which sends data to server.
The code executed when I press button.
I decided to disable button while user waiting for an answer from server to prevent packet-spamming.
When data arrives, button re-enabled.
However, if you keep your mouse cursor hovering the button while it's disabled, button graphically wont recognize a hovering from mouse after re-enabling even if you click on it. You need to move the mouse for any visible effect.
Button still will work when you click on it, you just wont see hover-difference.
#4
Help requests / Cyrillic Symbols
03 December 2016, 16:36:31
Hello.
I tried to use cyrillic symbols in EditBox->setDefaultText property, but obviously there are some code page issues.
Is there any way to use cyrillic symbols?

https://puu.sh/sCQmm/534a405c30.png
#5
Help requests / Editbox Lag
24 November 2016, 15:31:46
Hello.
Just started to use TGUI today and created one EditBox.
Tested it for a 10 seconds and encountered a problem.

Steps to reproduce:
1. Type enough letters inside EditBox so they won't fit anymore (text started to scroll).
2. Try to select the text with mouse and move mouse left/right to select/deselect parts of text.

Massive FPS drop appears to me (like, from 60 stable (framelimit) to 20-30).
If there are not many letters than I don't see any lag. Not sure if it's because of amount of characters or just because of scrolling.