shut stepmania up about multiple filenames warning
This commit is contained in:
@@ -10,7 +10,7 @@
|
|||||||
#BACKGROUND:;
|
#BACKGROUND:;
|
||||||
#LYRICSPATH:;
|
#LYRICSPATH:;
|
||||||
#CDTITLE:;
|
#CDTITLE:;
|
||||||
#MUSIC:ScreenGameplaySyncMachine music.ogg;
|
#MUSIC:_sync music.ogg;
|
||||||
#OFFSET:-0.012;
|
#OFFSET:-0.012;
|
||||||
#SAMPLESTART:0.000;
|
#SAMPLESTART:0.000;
|
||||||
#SAMPLELENGTH:12.000;
|
#SAMPLELENGTH:12.000;
|
||||||
|
|||||||
@@ -114,17 +114,32 @@ function Actor:FullScreen()
|
|||||||
end
|
end
|
||||||
|
|
||||||
--[[ Typical background sizes:
|
--[[ Typical background sizes:
|
||||||
320x240 - DDR 1st-Extreme, most NVLM_ZK songs
|
320x240 - [4:3]
|
||||||
640x480 - most simfiles in distribution today are this big.
|
640x480 - [4:3] (most simfiles in distribution today use this res.)
|
||||||
768x480 - 16:10 aspect ratio backgrounds
|
768x480 - [16:10]
|
||||||
854x480 - pump it up pro
|
854x480 - [16:9]
|
||||||
]]
|
]]
|
||||||
-- "Most backgrounds are 640x480. Some are 768x480. Stretch the 4:3 ones."
|
|
||||||
function Actor:scale_or_crop_background()
|
function Actor:scale_or_crop_background()
|
||||||
if (self:GetWidth() * 3) / 4 == self:GetHeight() then
|
local gw = self:GetWidth()
|
||||||
|
local gh = self:GetHeight()
|
||||||
|
|
||||||
|
local graphicAspect = gw/gh
|
||||||
|
local displayAspect = DISPLAY:GetDisplayWidth()/DISPLAY:GetDisplayHeight()
|
||||||
|
|
||||||
|
if graphicAspect == displayAspect then
|
||||||
|
-- bga matches the current aspect, we can stretch it.
|
||||||
self:stretchto( 0,0,SCREEN_WIDTH,SCREEN_HEIGHT );
|
self:stretchto( 0,0,SCREEN_WIDTH,SCREEN_HEIGHT );
|
||||||
else
|
else
|
||||||
|
-- temp
|
||||||
self:scaletocover( 0,0,SCREEN_WIDTH,SCREEN_HEIGHT );
|
self:scaletocover( 0,0,SCREEN_WIDTH,SCREEN_HEIGHT );
|
||||||
|
--[[
|
||||||
|
-- bga doesn't match the aspect.
|
||||||
|
if displayAspect > graphicAspect then
|
||||||
|
-- the graphic is smaller than the display aspect ratio
|
||||||
|
else
|
||||||
|
-- the graphic is bigger than the display aspect ratio; crop me
|
||||||
|
end
|
||||||
|
--]]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user