Direct x * error while making cinimatics.

Talk about anything Legend of Grimrock 1 related here.
trancelistic
Posts: 275
Joined: Sat Jun 16, 2012 5:32 am

Direct x * error while making cinimatics.

Post by trancelistic »

Hey all,

I know I've been a pain to some, me being a noob and silly.... But my heart is in the right place.

I've tried to finished my dungeon with my cinematics. I've tried my best to finish my dungeon for you guys.
- Today. I think my dungeon is ready. It has over 30 hours of gameplay. It is nothing fancy, no advanced scripting like the pro's. NO real special effects because I don't know those.
I do know you will love this adventure.

However I keep getting the error that

Code: Select all

[string "CinematicMode.lua"]:0: D3DError - CreateTexture failed: D3DERR_INVALIDCALL
is failing.

I"ve tried tons of options. Like resize the resolution to pure 4:3 or 16:9 or even 16:10. Resolutions like 1024x 786, 1440x900, 1920x1080 and even 1650x1080 (16:10) doesn't work.
i still get this direct x error.

Could some 1 direct me or help me wich program to use to help me finish my lore, refearing to the intro.lua and the ending lua ..... The cinematics works. just the "pictures" don't.
minmay
Posts: 2790
Joined: Mon Sep 23, 2013 2:24 am

Re: Direct x * error while making cinimatics.

Post by minmay »

What format are you saving the images in? Cinematics in Grimrock 1 use uncompressed DDS images in RGBA8 format with full mipmaps. They should not require a specific size but 1920x1080 is recommended.
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
trancelistic
Posts: 275
Joined: Sat Jun 16, 2012 5:32 am

Re: Direct x * error while making cinimatics.

Post by trancelistic »

Thanks for the reply minmay<3

I'm not so sure any pic should be in full HD anyhows.

I've tried using pictures from 1998 * a game that resolution is 800x600 Grimrock accepts it.
Ofcourse I do'nt want that picture...
Now today's screenshots on any ress makes LoG1 crash..:/

Why isn't log 1 ( latest version ofcourse) accepting any .DDS or .TGA screen shot. so to speak:(


Minmway, what do you use to make a picture?
It would help me. ( and prolly others too)

I sound like a whining bitch, but this "noob"dungeon I want to share to all. I cant atm. I need to fix this dds./tga support.

That is all.
User avatar
Isaac
Posts: 3192
Joined: Fri Mar 02, 2012 10:02 pm

Re: Direct x * error while making cinimatics.

Post by Isaac »

trancelistic wrote:...
On Windows, you should be able to use Paint.Net just fine for this.

http://www.getpaint.net/index.html

(Of course Photoshop and GIMP would work also; with the correct plugins.)

Save your images as DDS files, using the AR8B8G8 format; (and powers of 2).

Image

Code: Select all

-- simple one image cinematic
enableUserInput()
startMusic("assets/samples/music/intro.ogg")

-- show the image
showImage("mod_assets/textures/castle.tga")
fadeIn(2)
sleep(4)
fadeOut(4)
Image
minmay
Posts: 2790
Joined: Mon Sep 23, 2013 2:24 am

Re: Direct x * error while making cinimatics.

Post by minmay »

Cinematic images do not have to be powers of 2 in size. The ones in the original game are 1920x1080 and neither of those numbers is a power of 2! You should definitely use powers of 2 for any textures that are drawn in the 3D world, for compatibility reasons, but for GUI stuff, any dimensions are fine. Also, width and height needn't be the same (1024x512 is fine for example).

Grimrock supports DXT1, DXT3, and DXT5 texture compression as well as uncompressed RGBA8. The "1-bit transparency" that some programs hack into DXT1 is not supported. Typically you use DXT1 for textures without any transparency, DXT3 or DXT5 for textures with transparency (DXT3 gives sharper transparency, DXT5 gives smoother transparency), and uncompressed RGBA8 for textures like normal maps and GUI elements where S3 compression artifacts are unacceptable.
trancelistic wrote:Minmway, what do you use to make a picture?
I use GIMP with the gimp-dds plugin. However, gimp-dds lacks a proper mipmap filter for normal maps, so you have to normalize the mipmap layers yourself if you want to edit those. Of course, this is not a concern for these images.
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
User avatar
Isaac
Posts: 3192
Joined: Fri Mar 02, 2012 10:02 pm

Re: Direct x * error while making cinimatics.

Post by Isaac »

minmay wrote:Cinematic images do not have to be powers of 2 in size. The ones in the original game are 1920x1080 and neither of those numbers is a power of 2!
Okay... you're going to have to explain that one in a bit more detail.
minmay
Posts: 2790
Joined: Mon Sep 23, 2013 2:24 am

Re: Direct x * error while making cinimatics.

Post by minmay »

Isaac wrote:
minmay wrote:Cinematic images do not have to be powers of 2 in size. The ones in the original game are 1920x1080 and neither of those numbers is a power of 2!
Okay... you're going to have to explain that one in a bit more detail.
The cinematic images in Legend of Grimrock are 1920 pixels wide and 1080 pixels high. "Power of 2" means that the number is 2, multiplied by 2 some number of times.
2*2 = 4
2*2*2 = 8
2*2*2*2 = 16
2*2*2*2*2 = 32
2*2*2*2*2*2 = 64
2*2*2*2*2*2*2 = 128
2*2*2*2*2*2*2*2 = 256
2*2*2*2*2*2*2*2*2 = 512
2*2*2*2*2*2*2*2*2*2 = 1024
2*2*2*2*2*2*2*2*2*2*2 = 2048

Notice that neither the number 1920, nor the number 1080, appears in this list. You could add more 2s, but it wouldn't help; the numbers would just get bigger, and they're already bigger than 1920 and 2048.
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
User avatar
Isaac
Posts: 3192
Joined: Fri Mar 02, 2012 10:02 pm

Re: Direct x * error while making cinimatics.

Post by Isaac »

http://www.grimrock.net/modding_log1/cr ... om-assets/
Graphics in Legend of Grimrock come in a few different flavors. There’s 2D graphics, such as images for cinematics or item icons and then there’s 3D graphics that are used for item meshes, environment objects and monsters. 2D graphics are the more simple case by a wide margin so let’s start off with them.

2D graphics in Legend of Grimrock use DDS (DirectDraw Surface) format which can be saved from Photoshop and GIMP by using 3rd party plug-ins. Standalone converters are available as well. DDS supports compression which is recommended for textures that will be used on 3D models (use D3DFMT_DXT1 for textures without alpha and D3DFMT_DXT5 for textures with alpha) but user interface graphics, such as item icons, should be left uncompressed (use D3DFMT_A8R8G8B8). Mipmaps should be used with all textures and the dimensions of the textures should be to the power of two (16, 32, 64 …) to ensure compatibility.
minmay
Posts: 2790
Joined: Mon Sep 23, 2013 2:24 am

Re: Direct x * error while making cinimatics.

Post by minmay »

Many of the GUI images in the base game are not powers of 2 in size. If the HUD works on your computer (and it will), other 2D-drawn images that aren't powers of 2 will work, too. 2D images that aren't powers of 2 in size are literally the first thing you see when you start the game: on the loading screen, on the main menu, in character creation, in the opening cinematic, and on the HUD once the game starts. In the context of Grimrock you only need to worry about texture dimensions if they will be drawn in 3D, though in that case you definitely should worry about them.
Don't believe me?
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
User avatar
Isaac
Posts: 3192
Joined: Fri Mar 02, 2012 10:02 pm

Re: Direct x * error while making cinimatics.

Post by Isaac »

It's not a matter of belief (I know they display), it's the matter of AH's official advice that mod textures be a power of two, for compatibility sake between platforms.
Post Reply