Page 4 of 5 FirstFirst ... 2345 LastLast
Results 31 to 40 of 46

Thread: Multithreaded resource loading

  1. #31
    Quote Originally Posted by Luuk van Venrooij
    You need to switch the context. Otherwise your rendering commands will be send to the wrong threads if you want to handle drawing onscreen.
    Why you so sure? OpenGL has a rule - "one thread - one context", so situation "will be send to the wrong threads" never will happen, and my demo works as you can see(only Windows version has a problem and it will be fixed the same way as MacOS X demo)
    Last edited by Andru; 05-10-2010 at 05:02 PM.

  2. #32
    AthenaOfDelphi
    Can you test this new demo for Windows, please?

  3. #33
    PGDCE Developer de_jean_7777's Avatar
    Join Date
    Nov 2006
    Location
    Bosnia and Herzegovina (Herzegovina)
    Posts
    287
    I've tested it on the following machine. It works if I just run it, albeit a bit slow.

    OS: Windows XP Pro SP3
    CPU: Pentium 4 1.9 (Northwood)
    GPU: Intel i845G (integrated)

    However, when I minimize the demo during loading, and then try to restore it later by clicking on the demo button in taskbar, I eventually hear a few of those asterisk sounds windows makes, and the program no longer responds. While it's minimized it does not use CPU and has about ~3 MB memory use. When I restore it, it takes up ~100% of CPU and suddenly increases it's memory use up to ~20 MB, like it's stuck in some kind of a loop and continues to use more and more memory (slowly increasing). Sometimes it'll crash when I restore it, sometimes I get an access violation error message. Once the program has loaded completely, it can be minimized and restored without problems.
    Existence is pain

  4. #34
    Quote Originally Posted by de_jean_7777
    Once the program has loaded completely, it can be minimized and restored without problems.
    Strange. Seems this old videocard with old drivers wants active DC with own window. Can you put here content of log.txt?

  5. #35
    PGD Community Manager AthenaOfDelphi's Avatar
    Join Date
    Dec 2004
    Location
    South Wales, UK
    Posts
    1,246
    Blog Entries
    2
    Quote Originally Posted by Andru View Post
    AthenaOfDelphi
    Can you test this new demo for Windows, please?
    I'll give it a whirl later when I'm back home (probably be something like 7-8pm UK time).
    :: AthenaOfDelphi :: My Blog :: My Software ::

  6. #36
    PGD Community Manager AthenaOfDelphi's Avatar
    Join Date
    Dec 2004
    Location
    South Wales, UK
    Posts
    1,246
    Blog Entries
    2
    Hi Andru,

    I'm afraid, the first time it ran, this was all that was displayed where the speaker should be:-

    Corruption.png

    I've run it again, and it works perfectly. Here's the log from the first run.

    Code:
    =====================
    === ZenGL 0.2 RC4 ===
    =====================
    [00000000ms] Begin
    [00000001ms] Current mode: 1680 x 1050
    [00000628ms] wglChoosePixelFormatARB: zDepth = 24; stencil = 0; fsaa = 0
    [00000678ms] Create OpenGL Context
    [00000699ms] Making current OpenGL context
    [00000699ms] GL_VERSION: 2.1.2
    [00000699ms] GL_RENDERER: GeForce 7600 GT/PCI/SSE2/3DNOW!
    [00000699ms] GL_MAX_TEXTURE_SIZE: 4096
    [00000699ms] GL_ARB_TEXTURE_COMPRESSION: TRUE
    [00000699ms] GL_EXT_TEXTURE_COMPRESSION_S3TC: TRUE
    [00000699ms] GL_MAX_TEXTURE_UNITS_ARB: 4
    [00000700ms] GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT: 16
    [00000700ms] GL_EXT_BLEND_FUNC_SEPARATE: TRUE
    [00000700ms] GL_ARB_VERTEX_BUFFER_OBJECT: TRUE
    [00000700ms] GL_EXT_FRAMEBUFFER_OBJECT: TRUE
    [00000700ms] WGL_PBUFFER: TRUE
    [00000700ms] Support WaitVSync: TRUE
    [00000702ms] DirectSound: loading DSound.dll
    [00001107ms] DirectSound: sound system initialized
    [00001505ms] Texture loaded: "data/font-page0.png"
    [00001602ms] Texture loaded: "data/halloween/Alien.png"
    [00001679ms] Texture loaded: "data/halloween/Bat.png"
    [00001752ms] Texture loaded: "data/halloween/Casper.png"
    [00001820ms] Texture loaded: "data/halloween/Chucky.png"
    [00001894ms] Texture loaded: "data/halloween/Devil.png"
    [00001959ms] Texture loaded: "data/halloween/Dracula.png"
    [00002022ms] Texture loaded: "data/halloween/Frankenstein.png"
    [00002090ms] Texture loaded: "data/halloween/Freddie.png"
    [00002145ms] Texture loaded: "data/halloween/Ghost.png"
    [00002204ms] Texture loaded: "data/halloween/Gomez.png"
    [00002254ms] Texture loaded: "data/halloween/Jack Skellington.png"
    [00002305ms] Texture loaded: "data/halloween/Jason.png"
    [00002367ms] Texture loaded: "data/halloween/Kokey.png"
    [00002426ms] Texture loaded: "data/halloween/Mike.png"
    [00002490ms] Texture loaded: "data/halloween/Mummy.png"
    [00002542ms] Texture loaded: "data/halloween/Pumpkin.png"
    [00002601ms] Texture loaded: "data/halloween/Scream.png"
    [00002657ms] Texture loaded: "data/halloween/Skull.png"
    [00002715ms] Texture loaded: "data/halloween/Slimer.png"
    [00002767ms] Texture loaded: "data/halloween/Squash.png"
    [00002773ms] Sound loaded: "data/click.wav"
    [00002786ms] Texture loaded: "data/audio-stop.png"
    [00002800ms] Texture loaded: "data/audio-play.png"
    [00002925ms] Texture loaded: "data/zengl.png"
    [00057600ms] Ogg: Initialized
    [00084432ms] Average FPS: 747
    [00084460ms] Timers to free: 2
    [00084461ms] Render Targets to free: 0
    [00084460ms] Atlases to free: 0
    [00084460ms] Textures to free: 26
    [00084460ms] Fonts to free: 1
    [00084461ms] Sounds to free: 1
    [00084624ms] DirectSound: sound system finalized
    [00084707ms] End
    Really, this is exactly the same as the first time I tried it. The first run, it failed with a corrupted image... after that, all seemed OK.
    :: AthenaOfDelphi :: My Blog :: My Software ::

  7. #37
    Here's my run:

    Code:
    =====================
    === ZenGL 0.2 RC4 ===
    =====================
    [00000000ms] Begin
    [00000000ms] Current mode: 1680 x 1050
    [00000180ms] wglChoosePixelFormatARB: zDepth = 24; stencil = 0; fsaa = 0
    [00000197ms] Create OpenGL Context
    [00000199ms] Making current OpenGL context
    [00000200ms] GL_VERSION: 3.3.0
    [00000200ms] GL_RENDERER: GeForce 8800 GT/PCI/SSE2
    [00000200ms] GL_MAX_TEXTURE_SIZE: 8192
    [00000200ms] GL_ARB_TEXTURE_COMPRESSION: TRUE
    [00000200ms] GL_EXT_TEXTURE_COMPRESSION_S3TC: TRUE
    [00000200ms] GL_MAX_TEXTURE_UNITS_ARB: 4
    [00000200ms] GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT: 16
    [00000200ms] GL_EXT_BLEND_FUNC_SEPARATE: TRUE
    [00000200ms] GL_ARB_VERTEX_BUFFER_OBJECT: TRUE
    [00000200ms] GL_EXT_FRAMEBUFFER_OBJECT: TRUE
    [00000200ms] WGL_PBUFFER: TRUE
    [00000201ms] Support WaitVSync: TRUE
    [00000201ms] DirectSound: loading DSound.dll
    [00000223ms] DirectSound: sound system initialized
    [00000465ms] Texture loaded: "data/font-page0.png"
    [00001069ms] Texture loaded: "data/halloween/Alien.png"
    [00001123ms] Texture loaded: "data/halloween/Bat.png"
    [00001174ms] Texture loaded: "data/halloween/Casper.png"
    [00001224ms] Texture loaded: "data/halloween/Chucky.png"
    [00001278ms] Texture loaded: "data/halloween/Devil.png"
    [00001327ms] Texture loaded: "data/halloween/Dracula.png"
    [00001377ms] Texture loaded: "data/halloween/Frankenstein.png"
    [00001432ms] Texture loaded: "data/halloween/Freddie.png"
    [00001484ms] Texture loaded: "data/halloween/Ghost.png"
    [00001534ms] Texture loaded: "data/halloween/Gomez.png"
    [00001582ms] Texture loaded: "data/halloween/Jack Skellington.png"
    [00001632ms] Texture loaded: "data/halloween/Jason.png"
    [00001684ms] Texture loaded: "data/halloween/Kokey.png"
    [00001737ms] Texture loaded: "data/halloween/Mike.png"
    [00001792ms] Texture loaded: "data/halloween/Mummy.png"
    [00001841ms] Texture loaded: "data/halloween/Pumpkin.png"
    [00001888ms] Texture loaded: "data/halloween/Scream.png"
    [00001941ms] Texture loaded: "data/halloween/Skull.png"
    [00001995ms] Texture loaded: "data/halloween/Slimer.png"
    [00002046ms] Texture loaded: "data/halloween/Squash.png"
    [00002049ms] Sound loaded: "data/click.wav"
    [00002061ms] Texture loaded: "data/audio-stop.png"
    [00002070ms] Texture loaded: "data/audio-play.png"
    [00002144ms] Texture loaded: "data/zengl.png"
    [00005586ms] Average FPS: 1901
    [00005608ms] Timers to free: 2
    [00005608ms] Render Targets to free: 0
    [00005608ms] Atlases to free: 0
    [00005608ms] Textures to free: 26
    [00005608ms] Fonts to free: 1
    [00005608ms] Sounds to free: 1
    [00005709ms] DirectSound: sound system finalized
    [00005728ms] End
    My pc is a
    Intel Core 2 Duo E6850 - 2gb ram
    8800gt - Nvidia driver 258.96


    The first time it ran, it didnt show the speaker graphic at all, just a black space.
    The next time it did show the speaker, then after that it didnt come back.

    It seemed to run okay (apart from the missing speaker) when I minimised it or dragged the window around while it was loading.
    My site: DelphiTuts.com (coming soon)...

    Download Font Studio 4.21 here.

  8. #38
    PGDCE Developer de_jean_7777's Avatar
    Join Date
    Nov 2006
    Location
    Bosnia and Herzegovina (Herzegovina)
    Posts
    287
    Here is the log file.

    Code:
    =====================
    === ZenGL 0.2 RC4 ===
    =====================
    [00000000ms] Begin
    [00000001ms] Current mode: 1152 x 864
    [00000067ms] wglChoosePixelFormatARB: zDepth = 24; stencil = 0; fsaa = 0
    [00000129ms] Create OpenGL Context
    [00000130ms] Making current OpenGL context
    [00000130ms] GL_VERSION: 1.3.0 - Build 4.14.10.4342
    [00000130ms] GL_RENDERER: Intel 845G
    [00000130ms] GL_MAX_TEXTURE_SIZE: 2048
    [00000130ms] GL_ARB_TEXTURE_COMPRESSION: TRUE
    [00000130ms] GL_EXT_TEXTURE_COMPRESSION_S3TC: TRUE
    [00000130ms] GL_MAX_TEXTURE_UNITS_ARB: 4
    [00000130ms] GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT: 2
    [00000130ms] GL_EXT_BLEND_FUNC_SEPARATE: FALSE
    [00000130ms] GL_ARB_VERTEX_BUFFER_OBJECT: TRUE
    [00000130ms] GL_EXT_FRAMEBUFFER_OBJECT: FALSE
    [00000130ms] WGL_PBUFFER: TRUE
    [00000130ms] Support WaitVSync: TRUE
    [00000132ms] DirectSound: loading DSound.dll
    [00000261ms] DirectSound: sound system initialized
    [00000883ms] Texture loaded: "data/font-page0.png"
    [00001153ms] Texture loaded: "data/halloween/Alien.png"
    [00001284ms] Texture loaded: "data/halloween/Bat.png"
    [00001400ms] Texture loaded: "data/halloween/Casper.png"
    [00001525ms] Texture loaded: "data/halloween/Chucky.png"
    [00001661ms] Texture loaded: "data/halloween/Devil.png"
    [00001796ms] Texture loaded: "data/halloween/Dracula.png"
    [00001927ms] Texture loaded: "data/halloween/Frankenstein.png"
    [00002062ms] Texture loaded: "data/halloween/Freddie.png"
    [00002256ms] Texture loaded: "data/halloween/Ghost.png"
    [00002421ms] Texture loaded: "data/halloween/Gomez.png"
    [00002540ms] Texture loaded: "data/halloween/Jack Skellington.png"
    [00002660ms] Texture loaded: "data/halloween/Jason.png"
    [00002784ms] Texture loaded: "data/halloween/Kokey.png"
    [00002914ms] Texture loaded: "data/halloween/Mike.png"
    [00003046ms] Texture loaded: "data/halloween/Mummy.png"
    [00003160ms] Texture loaded: "data/halloween/Pumpkin.png"
    [00003271ms] Texture loaded: "data/halloween/Scream.png"
    [00003390ms] Texture loaded: "data/halloween/Skull.png"
    [00003524ms] Texture loaded: "data/halloween/Slimer.png"
    [00003650ms] Texture loaded: "data/halloween/Squash.png"
    [00003653ms] Sound loaded: "data/click.wav"
    [00003676ms] Texture loaded: "data/audio-stop.png"
    [00003699ms] Texture loaded: "data/audio-play.png"
    [00003893ms] Texture loaded: "data/zengl.png"
    Existence is pain

  9. #39
    Thanks for tests and logs. This weekend I will try to make a demo with second thread that will have own window and DC(maybe problem in one Device Context for two threads under Windows). Till that I will be waiting an answer from service centre, because today power supply from my PC died...

  10. #40
    my pc is P4 3 GHz
    Nvidia 8400 512Ram

    Runs great
    Code:
    =====================
    === ZenGL 0.2 RC4 ===
    =====================
    [00000001ms] Begin
    [00000001ms] Current mode: 1024 x 768
    [00001111ms] wglChoosePixelFormatARB: zDepth = 24; stencil = 0; fsaa = 0
    [00001195ms] Create OpenGL Context
    [00001211ms] Making current OpenGL context
    [00001212ms] GL_VERSION: 3.3.0
    [00001212ms] GL_RENDERER: GeForce 8400 GS/PCI/SSE2
    [00001212ms] GL_MAX_TEXTURE_SIZE: 8192
    [00001212ms] GL_ARB_TEXTURE_COMPRESSION: TRUE
    [00001212ms] GL_EXT_TEXTURE_COMPRESSION_S3TC: TRUE
    [00001213ms] GL_MAX_TEXTURE_UNITS_ARB: 4
    [00001220ms] GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT: 16
    [00001220ms] GL_EXT_BLEND_FUNC_SEPARATE: TRUE
    [00001220ms] GL_ARB_VERTEX_BUFFER_OBJECT: TRUE
    [00001220ms] GL_EXT_FRAMEBUFFER_OBJECT: TRUE
    [00001220ms] WGL_PBUFFER: TRUE
    [00001220ms] Support WaitVSync: TRUE
    [00001276ms] DirectSound: loading DSound.dll
    [00001386ms] DirectSound: sound system initialized
    [00001756ms] Texture loaded: "data/font-page0.png"
    [00001891ms] Texture loaded: "data/halloween/Alien.png"
    [00001997ms] Texture loaded: "data/halloween/Bat.png"
    [00002098ms] Texture loaded: "data/halloween/Casper.png"
    [00002197ms] Texture loaded: "data/halloween/Chucky.png"
    [00002304ms] Texture loaded: "data/halloween/Devil.png"
    [00002403ms] Texture loaded: "data/halloween/Dracula.png"
    [00002500ms] Texture loaded: "data/halloween/Frankenstein.png"
    [00002607ms] Texture loaded: "data/halloween/Freddie.png"
    [00002711ms] Texture loaded: "data/halloween/Ghost.png"
    [00002810ms] Texture loaded: "data/halloween/Gomez.png"
    [00002903ms] Texture loaded: "data/halloween/Jack Skellington.png"
    [00003000ms] Texture loaded: "data/halloween/Jason.png"
    [00003102ms] Texture loaded: "data/halloween/Kokey.png"
    [00003205ms] Texture loaded: "data/halloween/Mike.png"
    [00003313ms] Texture loaded: "data/halloween/Mummy.png"
    [00003408ms] Texture loaded: "data/halloween/Pumpkin.png"
    [00003500ms] Texture loaded: "data/halloween/Scream.png"
    [00003597ms] Texture loaded: "data/halloween/Skull.png"
    [00003705ms] Texture loaded: "data/halloween/Slimer.png"
    [00003803ms] Texture loaded: "data/halloween/Squash.png"
    [00003824ms] Sound loaded: "data/click.wav"
    [00003844ms] Texture loaded: "data/audio-stop.png"
    [00003862ms] Texture loaded: "data/audio-play.png"
    [00004009ms] Texture loaded: "data/zengl.png"
    [00017844ms] Ogg: Initialized
    [00040080ms] Average FPS: 197
    [00040091ms] Timers to free: 2
    [00040091ms] Render Targets to free: 0
    [00040091ms] Atlases to free: 0
    [00040091ms] Textures to free: 26
    [00040126ms] Fonts to free: 1
    [00040126ms] Sounds to free: 1
    [00040132ms] DirectSound: sound system finalized
    [00040197ms] End

Page 4 of 5 FirstFirst ... 2345 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •