• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Solved] How to display images without stretching?

Status
Not open for further replies.
Level 20
Joined
Nov 17, 2019
Messages
220
Hi everyone! I'm trying to show a 1024x1024 picture in my custom map to the player, but when I do it with the "Cinematic - Apply a filter" trigger, the picture gets stretched to fill the screen. My question is: Is there any way to show pictures to the player, without stretching it to fill the screen?
 
Level 14
Joined
Jan 10, 2023
Messages
254
There might be a better way, but you could locally check the resolution and then make the image have an appropriately sized alpha (transparent) border.

You would need several pictures, maybe not necessarily one for each display resolution, and then you would need to locally determine the size of each display and them locally change the image file's address (imported file's address) in a string variable, then show that image using the localized string as a directory and each display will have the appropriate file path for their image.

Not sure the best way to implement it, but I think that's an option.
 
Level 29
Joined
Sep 26, 2009
Messages
2,596
You could just create the image with a 4:3 ratio, where the 1024x1024 part will be centered and the remaining part of the image will be transparent.
That's how Blizz did it in the blood elf campaign's secret map, where you see Pandarens upon win
  • Cinematic - Apply a filter over 1.00 seconds using Normal blending on texture Panda-n-Cub, starting with color (100.00%, 100.00%, 100.00%) and 0.00% transparency and ending with color (0.00%, 0.00%, 0.00%) and 0.00% transparency
 
Status
Not open for further replies.
Top