x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

[Bug] SetRes doesn't update Canvas Clip size

Hello,

It looks like the console command "SetRes" doesn't update properly the Canvas Clip size variables. I have the following functions in my game code :

Character.cpp :

 void AExilCharacter::gameFullscreen()
 {
     if(EPC != NULL)
     {
         EPC->ConsoleCommand("SETRES 1920x1080 f", true);
         
         EPC->GetHud()->RefreshCanvas();
     }
 }
 
 
 
 void AExilCharacter::gameWindowed()
 {
     if(EPC != NULL)
     {
         EPC->ConsoleCommand("SETRES 1280x720 w", true);
 
         EPC->GetHud()->RefreshCanvas();
     }
 }

HUD.cpp :

 void AExilHud::RefreshCanvas()
 {
     if(Canvas)
     {
         //Doesn't work, need to find a way to update the ClipX/Y Size properly
         Canvas->Update();
         Canvas->UpdateAllCanvasSafeZoneData();
     }
 }


If my game is launched in windowed mode (1280x720 w) and then I switch to fullscreen (1920x1080 f), my Canvas size is not updated (Im referring to Canvas->ClipX and Canvas->ClipY ). Therefore my HUD is not properly drawn. However if I launch my game in fullscreen mode first, then switch to windowed mode, the Canvas size is properly updated.

Product Version: Not Selected
Tags:
more ▼

asked Apr 15 '14 at 08:47 AM in C++ Programming

avatar image

Froyok
260 21 26 37

avatar image Froyok May 08 '14 at 05:07 PM

Bumping this for visibility.

(comments are locked)
10|2000 characters needed characters left

2 answers: sort voted first

This bug doesn't occur anymore with the 4.2.1 version of the engine.

more ▼

answered Jul 06 '14 at 11:24 AM

avatar image

Froyok
260 21 26 37

(comments are locked)
10|2000 characters needed characters left

Console command should be: "r.setres"

more ▼

answered Jun 01 '14 at 11:13 AM

avatar image

order66
98 4 15 18

avatar image Froyok Jun 01 '14 at 01:28 PM

It's the same thing. The clip size variables don't update properly anyway.

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question