Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

romulus_ut3

Members
  • Content count

    37
  • Joined

  • Last visited

About romulus_ut3

  • Rank
    Green Marine

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. romulus_ut3

    Oops. Someone sent me an extra Collectors Edition....

    Congratulations to the winner. I guess I have such a bad luck.. argh if only I checked the forums like an hour ago!
  2. romulus_ut3

    Rare unused monster in Doom 3 files.

    This looks hilarious to be honest. Arl is displaying his talents as usual, but for some reason I don't wish to see this as an enemy in game. Just my opinion.
  3. romulus_ut3

    Alpha Shotgun Mod?

    This may come in handy for those who are more technically aware of things? =================================================== Unofficial DoomIII model specs v0.1 Trevor Wilkin - happiestwhenevil@hotmail.com =================================================== The md5mesh and md5anim files are in plain text and so fairly little explanation is needed as to how to load them. The trickiest part is probably the binding of the mesh to the skeleton itself. Here is a quick rundown of the file. THE HEADER ========== MD5Version 6 commandline "mesh maps/fred/bathroom/SCENE1.mb -dest maps/fred/bathroom/scene1fatmesh.md5mesh -game Doom -prefix FATTY_ -range 1 2" Is an example of what you will see at the top of every model file. The version number is useful for a sanity check since I imagine the files wont be in plain text come the release, and the commandline is useless to us, but it looks like the parameters used to convert the maya binaries into md5meshs. THE BONE CHUNK ============== This is the start of the useful data. First you can expect to read "numbones %i" where the integer or dword read is the number of bones of the following format... bone %i { name "%s" bindpos %f %f %f bindmat %f %f %f %f %f %f %f %f %f [parent "%s"] } The first integer read should match with the bone number, this is just another sanity check since the bones should all be in order. The first string is the name of this bone/joint and the last string (which doesn't always exist in the bone) is the parents name. The [ ] brackets are just there to show that line is optional and they don't exist in the file. The bindpos and bindmat are the initial matrix values for the bone. These values are useful for getting the model into the bind pose, but will be pretty much ignored once you move onto animations because the new matrices will be built from that data. I found it best to keep the bindpos and bindmat in separate matrices and vectors rather than building a single matrix. THE MESH CHUNK ============== After reading "nummeshes %i" you can expect to read that many mesh chunks which should be laid out as follows: mesh %i { // Integer should be mesh number and in order shader "%s" // String represents the base texture for this // mesh. numverts %i // The number of vertices to follow vert %i %f %f %i %i // There should be one of these lines for every // vert. The parameters are vert number, // texture U, texture V, blend index, blend // count numtris %i // The number of triangles to follow tri %i %i %i %i // There should be one of these lines for every // triangle. The parameters are triangle number // and then the three vertex offsets forming the // triangle. There are indices into the verts. numweights %i // The number of weights to follow weight %i %i %f %f %f %f // There should be one of these lines for every // weight. The parameters are weight number, the // bone this weight is for, the bias factor and // the X,Y,Z weights. } And that's pretty much it. SKINNING THE MODEL ================== Below is a snip of code you could use to skin DoomIII models, it assumes some basic math classes and so on... but that shouldn't be too hard to pickup. void Bind() { Vector3 pos; for (DWORD i=0; i<m_Header.NumberOfMeshes; i++) { MD5Mesh& mesh = m_Meshes[i]; // Get the current mesh MD5Vert* vertices = mesh.Vertices; // Get the vertices for (DWORD j=0; j<mesh.NumberOfVerts; j++) // For every vert in the mesh { MD5Vert& v = vertices[j]; MD5VertWeight& vw = mesh.VertexWeights[j]; // Find the vert and the weight v.Pos = Vector3::Zero; for (DWORD k=0; k<vw.WeightCount; k++) // For all the weights { MD5Weight& w = mesh.Weights[vw.WeightIndex+k]; MD5Bone& b = m_Bones[w.Bone]; pos = w.Pos * b.BindMatrix; // Transform the position by the matrix v.Pos += (pos + b.BindPos) * w.T; // Combine the weights } } } } TEXTURING THE MODEL =================== The base texture name can be found by reading the shader string in the mesh structure. This can sometimes be the absolute texture name, but more often you need to append certain letters to get all the useful textures. Here is an example... shader "P:/Doom/base/models/monsters/zombie/fatty/fatty.tga" If you check this directory, you'll find there are no textures with that name, however there are 4 textures with very similar names: fatty_d.tga fatty_h.tga fatty_local.tga fatty_s.tga The two most important textures for now are the _d and _local textures that encode the detail and normal information. Just using the detail texture alone will look very ugly because DoomIII uses a very clever technique by which a high polygon count model can be approximated to a low polygon model and a normal map. The simplest way to use this texture is to perform a dot product in your pixel shaders (or set the texture stage states to do so). This is an example pixel shader to do just that... Note that c0 is a light vector set using d3ddevice->SetPixelShaderConstant(F). <snip> ps.1.1 ;Use Two textures tex t0 ; Diffuse map tex t1 ; Normal map ;Dot product of c0 with normal map to get light amount, modulate with diffuse dp3_sat r0.rgb, t1_bx2, c0 mul r0.rgb, t0, r0 </snip> ANIMATING THE MODEL =================== Assuming all has gone well, you should have an ugly looking zombie or fatguy standing with his arms stretched out. Now it's time to animate the model. For every model with animation there should be a .md5anim file. Chances are there are a bunch of them in a directory with the same name as your model. The format of that file is as follows: THE HEADER ========== This is the same as the model header, check for version 6 and ignore the command line. THE CHANNEL CHUNK ================= After reading "numchannels %i" you can expect to read that many of the following chunks: channel %i { joint "%s" // What joint to animate attribute "%s" // What animation this channel encodes starttime %f endtime %f framerate %f // The FPS of this animation. Usually 24 strings 0 // Number of strings, unknown use and always zero range %i %i keys %i // The number of keys (the number of floats to follow) %f ..... // A float for every key } The most important information here is the attribute, key data and joint name. When you read this data in, it is a good idea to search for the joint and store a pointer to it. You will probably find 2 joints that don't exist in the channels, boundsMin and boundsMax... either create these joints or ignore the first 2 channels. Joints and bones are the same. Now for your update and this is the tricky bit. For every channel you have read in, using the start and end time (and your internal animation counter) decide on which key in the range of keys for that channel you should use. For example, if you are half way between the start and end time, you are also half way through the keys. After you have the key, using the attribute, which will be one of the following: x,y,z,yaw,pitch,roll, store the key in the bone. I found it useful to have an array of 6 floats per bone for just this purpose. In the code sample below, you'll see it's called Attrib. The first three parameters are x,y,z and the last are the rotations. After you have been through all channels and set all attributes for all bones, you can loop through the bones and do something similar to this... <snip> Matrix mat,matX,matY,matZ; for (DWORD i=0; i<m_Header.NumberOfBones; i++) { matX.BuildRotationY(m_Bones[i].Attrib[3]); matY.BuildRotationZ(m_Bones[i].Attrib[4]); matZ.BuildRotationX(m_Bones[i].Attrib[5]); mat = matZ * matX * matY; if (m_Bones[i].Parent) { m_Bones[i].BindMatrix = mat * m_Bones[i].Parent->BindMatrix; m_Bones[i].BindPos.TransformBy(*(Vector3*)m_Bones[i].Attrib,m_Bones[i].Parent->BindMatrix); m_Bones[i].BindPos += m_Bones[i].Parent->BindPos; } else { matX.BuildRotationX(-PI/2.0f); mat = mat * matX; mat._33 = -mat._33; m_Bones[i].BindMatrix = mat; m_Bones[i].BindPos.TransformBy(Vector3::Zero,mat); } } </snip> This code basically transforms a bone by it's parent if there is one. If there isn't, it assumes the joint is the origin and does some conversions to get the joint into the D3D coordinate system. ============================================================================== I hope this doc and code proves useful, if so just mention my name somewhere and we'll call it quits k? If not, or you see something wrong... feel free to give me a shout. Laters, Trev.
  4. romulus_ut3

    Alpha Shotgun Mod?

    I had a similar request made at idtechforums as well, let me tell you, no one else is happier than I am! :D
  5. romulus_ut3

    Alpha Shotgun Mod?

    Seems I have reached a dead end. Whatever importers existed for the alpha, were replaced by the MD5 version 10 importer once DOOM 3 came out. der_ton is the only guy who could help us at this point, as he was the one who came up with the importer originally.
  6. romulus_ut3

    Alpha Shotgun Mod?

    I think someone else has a working version of the Alpha shotgun with a working reloading thingy. Edit: Seems like this is one of the earlier versions of Arl's hard work, which had the shell entry port opened or am I seeing things? DOOM3world had a few importers which were compatible with the alpha as far as I remember, I am gonna do some digging to see if I can find them.
  7. romulus_ut3

    Alpha Shotgun Mod?

    Lets take a look at the alpha shotgun reloading animation. And the animation from the ported shotgun, running on RBDOOM3BFG:
  8. romulus_ut3

    Alpha Shotgun Mod?

    I noticed a few imperfections in the reloading animation. (Pardon me if it comes across as nitpickish and this isn't an absolutely necessary fix) but while looking at the alpha's shotgun from the alpha itself, I noticed the following: http://i.imgur.com/cRCQjK8.jpg?1 Notice the shell pushing the cover and entering the shotgun? http://i.imgur.com/XHV8Nlr.jpg?1 http://i.imgur.com/WavBZiT.jpg?1 http://i.imgur.com/WTZMCQC.jpg?1 http://i.imgur.com/bsjGmJV.jpg?1 Whereas in DOOM 3, the sliding door chamber's missing and is static: http://i.imgur.com/NG4q03C.jpg?1 Edit: I think Arl already mentioned this earlier.
  9. romulus_ut3

    Doom 3 Alpha Grey - Screen . Help ?

    Your drivers are either faulty or your copy of the alpha is corrupt. I played the alpha last night on my HD 7950 with 16X anisotropic filtering and 8XEQ Edge Anti Aliasing force from the Crimson Radeon Suite, works just as intended.
  10. romulus_ut3

    Alpha Shotgun Mod?

    Fantastic work, Arl! Your Alpha Shotgun even works on DOOM 3 BFG's RB DOOM BFG source port! The .dds format no longer works with DOOM 3 BFG, sadly. So it's loading assets directly from the .tga textures. Will I be pestering if I ask you to "enhance" the current textures, or will that be greedy of me? :P http://i.imgur.com/SqnPvD0.png?1
  11. romulus_ut3

    What platform will you be playing the new Doom/Doom beta on?

    I'll be getting the game on PC.
  12. romulus_ut3

    [UPDATED] The DOOM System Upgrade Thread

    I think the real reason behind GTX 750 Ti not being supported has likely something to do with OpenGL support. It probably doesn't provide acceptable performance when used with OpenGL 4.3 or something.
  13. romulus_ut3

    [UPDATED] The DOOM System Upgrade Thread

    The CPU plays a crucial part in gaming. The better the CPU, the higher your minimum framerate will be in gaming, and this holds true specially for titles that're CPU intensive. The problem AMD's current wave of processors have is that their single core performance is very poor, resulting in Core i3 taking the lead over an FX 8 core narrowly in some games.
  14. romulus_ut3

    Is Doom 2016 really inspired from Brutal Doom?

    Quoted for the truth.
  15. romulus_ut3

    [UPDATED] The DOOM System Upgrade Thread

    AMD cards seem to have the upper hand in this title, seemingly from the minimum requirements: A GTX 780 as opposed to the R9 280 which is just a rebranded Tahiti Pro. But it's way too early to say anything as the poster above me has mentioned, that there's currently no optimized drivers available. Neither manufacturer has an active profile for the game in their drivers. Driver optimizations can make a huge difference. And also, I'm wondering whether DOOM will have added Vulkan support later.
×