Jump to content

Madjack

Members
  • Posts

    26
  • Joined

  • Last visited

Posts posted by Madjack

  1. I've had this several times down here in New Zealand.

     

    Last time 'Trevor' with the thick indian accent, told me he was from Microsoft and my computer was 'giving errors on the internet'. The scam is that they get you to look at your error log (which naturally will be filled with error reports) and then go to a website where they'll try to convince you to buy security software.

     

    Worst case scenario - they gain access to your machine and credit card details.

  2. So I've finally gotten my ex-Xors + BMX codebase to compile under Leadwerks.

     

    From what I can tell, the way to go is to use Framework in order to have easy access to LE's various special fx. Is that correct? Any issues I should be aware of with Frameworks + BMX?

     

    I've grabbed the copy from the SDK install and incorporated it into my code.

     

    An initial problem is that some commands mentioned in the docs + wiki don't seem to be included in the BlitzMax version. Namely:

     

    GetFrameworkLayer

    GetFrameworkListener

    GetLayerCamera

    GetLayerWorld

     

    What am I missing?

     

    <edit> or could I write my own functions for the above? Something like;

     

    Local LAYER_DEFAULT:TLayer = GetFrameworkLayer(1)
    Local CAMERA:TCamera = GetFrameworkCamera(LAYER_DEFAULT)
    
    Function GetFrameworkLayer:TLayer(LAYER_index:int)
    select LAYER_index
     case -1; Return fw.background
     case 0; Return fw.Main
     case 1; Return fw.transparency
    end select
    End Function
    
    
    Function GetFrameworkCamera:TCamera(LAYER_check:TLayer)
     Return LAYER_check.CAMERA
    End Function
    

  3. One thing about going from Xors to LE - LE's much more strict (see what I did there) about declaring variables where as Xors allows any old integer as a surface/mesh/pivot pointer. So it's painful to convert from a large codebase from Xors to LE (as I'm doing now), but the extra structure is going to pay off with better code.

  4. LE doesn't allow native access to pixel data? Seriously?

     

    <EDIT> This makes no sense to me. So I can create a buffer for a texture and store texture channel data in that buffer but there's no easy way to read a colour at a given x/y?

     

    For example ;

    Local TEX_TEMP:TTexture = LoadTexture("abstract::CHECKERBOARD.JPG")
    Local T_BUFFER:TBuffer = CreateBuffer(256, 256)
    SetBuffer(T_BUFFER)
    SetColorBuffer(T_BUFFER, TEX_TEMP)
    
    GetColorBufferXY(T_BUFFER) ' Something like this does not exist in LE?? 

  5. Ok - time for another dumb newbie question.

     

    I'm looking to load an image and read pixel colours (with which to ultimately deform a mesh)

     

    I would have thought loadimage would be the one, but I'm finding defining a TImage is giving a

    'Identifier TImage not found' error when used with the framework.

     

    Strict
    Framework leadwerks.engine
    Local j_image:TImage

     

    I'm using BMax v1.45, LE is up to date. Remove the framework ref and the code compiles ok.

     

    Is anyone else experiencing this? What am I missing?

  6. Nakof

     

    As an ex-Xors user, keep an eye on the number of surfaces in your scene.

    Xors doesn't seem to do much internal batching of surfaces and so framerates can quickly drop.

    If you can make objects single surface, all the better.

  7. I do suspect simmers may be more likely to overlook basic graphics in favour of systems fidelity.

     

    Perhaps get the game out with systems in place and then release a graphics upgrade module later - perhaps as DLC.

  8. RO

     

    Clocking along. Like you I've finally migrated to LE.

     

    I got Tank Universal out and on Steam back in 2008. After that mission I took a break from game dev but now I'm back developing TU2 and again I've probably bitten off more than I can chew. Have come to LE after a year or two developing with Xors3d.

    • Upvote 1
  9. Hi all

     

    I simply want to scroll a texture on a mesh.

     

    In Blitz3d or Xors I would get the surface brush, brush texture and set the texture's UV in-code via PositionTexture(texture, u,v).

     

    I see I can get a material's texture via GetMaterialTexture but there doesn't appear to be commands to adjust UV?

     

    Is this something that it has to be handled within the material's associated shader?

  10. Really need some help regards this issue (thanks NA for your valiant attempt)

     

    To reiterate, simply want a diffuse texture on level 0 and an additive texture on level 1.

    What am I missing???

     

    I can set up a material that uses mesh_diffuse_glow.frag for the pixel shader

    and I have a diffuse texture on texture 0, and my additive texture on texture 1.

     

    The material editor then correctly shows the additive texture blending with the texture layer.

    Additionally, if I load the mesh into an editor scene, it appears correctly in the scene with the additive texture blended with the diffuse texture.

     

    However if I load the mesh into model viewer, it only shows the diffuse texture.

    Also, if I load the mesh into my BMax prog, it only shows the diffuse texture.

     

    Why? Why is there a difference between what I see in the editor and the model viewer??? What's going on???

     

    <edit> Macklebee has just kindly helped me out on this issue.

     

    Simple matter of making sure buffer creation included BUFFER_COLOR3, as that is the buffer the glow shader outputs to. Got to say, as a newbie, this was not at all clear to me.

     

    gbuffer = CreateBuffer(GraphicsWidth(), GraphicsHeight(), BUFFER_DEPTH | BUFFER_COLOR0 | BUFFER_COLOR1 | BUFFER_COLOR2 | BUFFER_COLOR3)

     

    It seems my error was using code from the wiki which apparently is well out of date in that I copied code from the wiki BMX PDF examples. Had no idea that I was missing a buffer call. Bumpmapping/specular seemed to work as expected.

  11. Ok - looks like I can assemble models in Lightwave 11's layout, export to FBX and use the fbx2gmf convertor. Mesh hierarchy and relative centres appear to be retained. Not quite there yet but looks promising.

     

    <edit> scale needs to be set to 0.01 when exporting for 1:1 fbx mesh size. Mesh layer names are retained in final GMF file, top level object is a model class.

     

    Pivots are not exported. Guess I can get around that - perhaps single vertex meshes or if that may cause problems, find and replace in code.

     

    Loading an LW scene file into UU3d and export to FBX results in mesh hierachy being retained but relative mesh centres are reset to 0,0. Looks like UU3d is not quite as good a conversion tool as I thought it was.

     

    Looks like I can use Lightwave 11 to set up objects and scenes and export through the fbx plugin. Need to do more testing to see if LW's surface system has any follow through with the plugin. Probably too much to ask.

  12. Oh for a single app that understands and converts;

     

    Multiple UV maps

    Multiple texture layers

    Smoothing groups

    Parent/child relationships

    Mesh names

    Off centre mesh positioning

     

    Looks like another evening of testing coming up.

  13. Damn. Was really hoping to have a simple, clear artpath with LW -> UU3d -> GMF.

    It's frustrating that UU3d does pick up child names but then loses that info when exporting to GMF.

    UU3d does pick up other info correctly (UV maps, smoothing groups) and will convert my png files to DDS + mat files.

     

    Using the provided LE convertors with FBX/DAE exported from LW also seems to lose child names.

    LE crashes when trying to load DAE exported directly from LW 11.

     

    My previous workflow (using Xors), was to model in LW, export using Terrabit's LW convertor, import into Giles, add child pivots etc, tweak texture layers as needed, name children, export to B3d, use loadanimmesh to retain child structure. This was about as long an art pipeline as I'd want to get to.

     

    Anyone know who's responsible for the GMF plugin?

  14. I'm using Lightwave as my modelling app.

    Unwrap3d can import LW files and sucessfully export to GMF along with material files and DDS textures.

     

    In LW modeller I can name mesh layers and UU3D picks up these names as group names.

    Problem is the export to GMF seems to replace that info with something much less useful

     

    GetEntityKey(entity, "name") returns U3D_STATIC_MESH for all children

     

    What am I missing here?

  15. NA

     

    Thanks for the hints.

     

    I'm not sure that what you've suggested is exactly what I'm after though. My terminology probably isn't clear.

     

    I essentially want to recreate the effect of having an additive texture on the second or third texture layer.

     

    I would have thought that setting texture01 to the additive texture and then using mesh_diffuse_glow.frag would do the trick.

    When I do this, the material preview seems correct and the editor shows the additive texture coming through the diffuse texture just fine.

     

    However I'm only seeing the diffuse texture in the model viewer and my BMax code also shows a cube with just the diffuse texture.

    I don't understand why I'm seeing different results between the material editor + editor vs model viewer + code.

     

    I've probably missed something I guess.

    I'm using the following to view the cube.

     

    Framework leadwerks.ENGINE
    
    RegisterAbstractPath("C:/Leadwerks Engine SDK")
    
    GCSetMode(2)
    
    Graphics 800, 600
    
    WORLD = CreateWorld() ;If Not WORLD RuntimeError "Failed to create world."
    
    gbuffer = CreateBuffer(GraphicsWidth(), GraphicsHeight(), BUFFER_DEPTH | BUFFER_COLOR0 | BUFFER_COLOR1 | BUFFER_COLOR2)
    
    light = CreateDirectionalLight()
    RotateEntity light,[45.0,45.0,45.0]
    
    cam = CreateCamera()
    MoveEntity cam, Vec3(0, 0, -31) 'Create a visual mesh
    
    OB = LoadMesh("abstract::box_1.gmf")
    
    While Not KeyHit(KEY_ESCAPE)
    
       UpdateAppTime()
       TurnEntity OB, Vec3(.1, .1, .1)
    
       SetBuffer(gbuffer)
       RenderWorld()
       SetBuffer(BackBuffer())
       RenderLights(gbuffer)
       Flip(1)
    
    Wend

×
×
  • Create New...