Jump to content
Xtreme .Net Talk

Recommended Posts

Posted
Ok i finnally got my program to accept the fact that purehardware or hardwarevertexprocessing is a valid and desirable flag but somthing is terribly wrong. As soon as i change from SoftwareVertexProcessing to (HardWareVertexProcessing or PureDevice) two things happen, 1 DROP IN FRAMEFRATE 60 fps -> 20, all my meshes disapear (again). Any ideas of why this is / how to fix it? (video card is a nVida GeForce 4 128mb)
Posted
Can you post us your device creation code?

Dim DevType As DeviceType
       Dim CFlags As CreateFlags
       Dim Caps As Caps = D3d.GetCaps()
       Dim PP As New Microsoft.DirectX.Direct3D.PresentParameters
       DevType = DeviceType.Hardware
       CFlags = CreateFlags.SoftwareVertexProcessing
       If Caps.DeviceCaps.SupportsHardwareTransformAndLight Then
            CFlags = CreateFlags.HardwareVertexProcessing
       End If
       If Caps.DeviceCaps.SupportsPureDevice Then
           CFlags = CFlags Or CreateFlags.PureDevice
           Debug.WriteLine("PureDevice")
       End If
       PP.BackBufferCount = 1
       FileOpen(1, Application.StartupPath & "\config.cfg", OpenMode.Input)
       Input(1, PP.BackBufferWidth) '1024
       Input(1, PP.BackBufferHeight) '768
       Input(1, PP.BackBufferFormat)'A8R8G8B8
       FileClose(1)
       PP.Windowed = False
       PP.SwapEffect = Microsoft.DirectX.Direct3D.SwapEffect.Discard
       PP.AutoDepthStencilFormat = DepthFormat.D16
       PP.EnableAutoDepthStencil = True
       PP.PresentFlag = PresentFlag.None
       MainForm.Show()
       If Not D3d.Initialize(DevType, MainForm, CFlags, PP) Then
           End
       End If

Posted

ye from what i know the device back buffer can't be A8R8G8B8.

 

if you need an alpha value on a rendered surface, that surface can be A8R8G8B8 but the device back buffer can't

Menge

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...