Results 1 to 12 of 12

Thread: exception at 0x65100c40 (QtGuid4.dll)

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jul 2007
    Posts
    166
    Thanks
    25
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default exception at 0x65100c40 (QtGuid4.dll)

    Hi,
    I create a test program in Qt4.3 and compile it using Visual Studio 2005.
    At the time of compiling, there has no errors. But when I run that program
    , the program start running and after some 2 sec it display an error and crash. The error is like this. Any one know why this error?

    First-chance exception at 0x65100c40 (QtGuid4.dll) in Test.exe: 0xC0000005: Access violation reading location 0x00000000


    Please help me to find the reason of this error?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    It looks like you have a null pointer somewhere. Post the backtrace and we will try to find where it is.

  3. #3
    Join Date
    Jul 2007
    Posts
    166
    Thanks
    25
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    Hi,
    When I run that program, V.S print these values at the output window


    'Test.exe'': Loaded 'D:\svnserver\ccmanager\windows\debug\Test.exe'', Symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\ntdll.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\kernel32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\bin\Qt3Supportd4.dll', Symbols loaded.
    'Test.exe': Loaded 'C:\WINDOWS\system32\advapi32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\rpcrt4.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\shell32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\gdi32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\user32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\msvcrt.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\shlwapi.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\comdlg32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\comctl32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\ws2_32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\ws2help.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\bin\QtSqld4.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\bin\QtCored4.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\ole32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.VC80.DebugCRT_1fc 8b3b9a1e18e3b_8.0.50727.42_x-ww_f75eb16c\msvcp80d.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.VC80.DebugCRT_1fc 8b3b9a1e18e3b_8.0.50727.42_x-ww_f75eb16c\msvcr80d.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\bin\QtXmld4.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\bin\QtGuid4.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\oleaut32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\imm32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\winmm.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\winspool.drv', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\bin\QtNetworkd4.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\sqlite3.dll', Binary was not built with debug information.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\avicap32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\version.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\msvfw32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.2982_x-ww_ac3f9c03\comctl32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\Syncor11.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\Program Files\Common Files\Logitech\LVMVFM\LVPrcInj.dll', No symbols loaded.
    The thread 'Win32 Thread' (0xddc) has exited with code 12058624 (0xb80000).
    'Test.exe'': Loaded 'C:\WINDOWS\system32\MSCTF.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\MSCTFIME.IME', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\uxtheme.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\usp10.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\plugins\imageformats\qgifd4.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\plugins\imageformats\qjpegd4.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\plugins\imageformats\qmngd4.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\plugins\imageformats\qsvgd4.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\bin\QtSvgd4.dll', Symbols loaded.
    'Test.exe'': Loaded 'C:\Qt\4.3.0\plugins\imageformats\qtiffd4.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\secur32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\userenv.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\xpsp2res.dll', Binary was not built with debug information.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\dciman32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\wdmaud.drv', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\setupapi.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\wintrust.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\crypt32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\msasn1.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\imagehlp.dll', No symbols loaded.
    'Test.exe'': Unloaded 'C:\WINDOWS\system32\setupapi.dll'
    'Test.exe'': Unloaded 'C:\WINDOWS\system32\wdmaud.drv'
    'Test.exe'': Loaded 'C:\WINDOWS\system32\wdmaud.drv', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\setupapi.dll', No symbols loaded.
    'Test.exe'': Unloaded 'C:\WINDOWS\system32\setupapi.dll'
    'Test.exe'': Loaded 'C:\WINDOWS\system32\msacm32.drv', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\msacm32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\midimap.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\P1100bVf.dll', Binary was not built with debug information.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\cfgmgr32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\setupapi.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\vfwwdm32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\ksuser.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\clbcatq.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\comres.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\devenum.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\msdmo.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\ksproxy.ax', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\kswdmcap.ax', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\mfc42.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\P1100bDx.ax', Binary was not built with debug information.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\qcap.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\quartz.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\Program Files\Common Files\Logitech\LVMVFM\UMVPL.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\msvcr71.dll', Symbols loaded.
    The thread 'Win32 Thread' (0x710) has exited with code 0 (0x0).
    The thread 'Win32 Thread' (0x898) has exited with code -2147024637 (0x80070103).
    The thread 'Win32 Thread' (0x830) has exited with code 0 (0x0).
    'Test.exe'': Unloaded 'C:\WINDOWS\system32\vfwwdm32.dll'
    'Test.exe'': Unloaded 'C:\WINDOWS\system32\P1100bVf.dll'
    'Test.exe'': Unloaded 'C:\WINDOWS\system32\cfgmgr32.dll'
    'Test.exe'': Unloaded 'C:\WINDOWS\system32\dciman32.dll'
    'Test.exe'': Loaded 'C:\WINDOWS\system32\dciman32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\P1100bVf.dll', Binary was not built with debug information.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\cfgmgr32.dll', No symbols loaded.
    'Test.exe'': Loaded 'C:\WINDOWS\system32\vfwwdm32.dll', No symbols loaded.
    CallbackStatus(500, "text")
    CVideoDeviceWin32:umpCaptureStatus(00000000)
    Image width : 176
    Image height : 144
    Live window? : T
    Overlay window? : F
    Scaled? : F
    Scroll : (0,0)
    Using def. palette? : T
    Audio hardware? : T
    Capture file exists?: T
    Current video frame : 0
    Video frames dropped: 0
    Current wave samples: 0
    Time elapsed (ms) : 0
    Capturing now : F
    # video buffers : 0
    # audio buffers : 0
    Setting video mode
    m_ImageSize.width() 176
    m_ImageSize.height() 144
    Call TryPalette
    CallbackStatus: Reset
    CVideoDeviceWin32:umpCaptureStatus(00000000)
    Image width : 176
    Image height : 144
    Live window? : T
    Overlay window? : F
    Scaled? : F
    Scroll : (0,0)
    Using def. palette? : T
    Audio hardware? : T
    Capture file exists?: T
    Current video frame : 0
    Video frames dropped: 0
    Current wave samples: 0
    Time elapsed (ms) : 0
    Capturing now : F
    # video buffers : 0
    # audio buffers : 0
    The thread 'Win32 Thread' (0x954) has exited with code 0 (0x0).
    CallbackError(418, "text")
    TryPalette(32) return F
    CallbackError(0, "text")
    TryPalette(24) return T
    CVideoDeviceWin32:umpCaptureParms()
    uSeconds per frame : 66667
    User must hit OK? : F
    Percent drop error : 10%
    Yield? : F
    Index size : 34952
    Chunk Granularity : 0
    Using DOS memory? : F
    Buffers requested : 5
    Capture Audio? : T
    Audio buffers : 4
    Abort key :x1b
    Abort left mouse? : T
    Abort right mouse? : T
    Limit enabled? : F
    Time limit : 0
    MCI Controlled? : F
    Step MCI device? : F
    MCI start time : 0
    MCI stop time : 0
    Double resolution? : F
    Average capture step: 0
    Audio buffer size : 0
    Disable write cache?: F
    Stream Master : 0
    First-chance exception at 0x65100c40 (QtGuid4.dll) in Test.exe': 0xC0000005: Access violation reading location 0x00000000.
    Unhandled exception at 0x65100c40 (QtGuid4.dll) in Test.exe': 0xC0000005: Access violation reading location 0x00000000.
    The program '[904] Test.exe': Native' has exited with code 0 (0x0).
    Please help me...
    Last edited by jpn; 19th December 2007 at 13:31. Reason: missing [quote] tags

  4. #4
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    What's the content of Debug->Windows->Call Stack?
    J-P Nurmi

  5. #5
    Join Date
    Jul 2007
    Posts
    166
    Thanks
    25
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    Hi,
    Please see the attachmenet file
    Attached Files Attached Files

  6. #6
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    In CCamPanel::paintEvent(), how is the image constructed you're attempting to paint?
    J-P Nurmi

  7. #7
    Join Date
    Jul 2007
    Posts
    166
    Thanks
    25
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    Hi,
    Yes, I create that image in another location and paste it in that location

  8. #8
    Join Date
    Jul 2007
    Posts
    166
    Thanks
    25
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    Hi,
    This is my code for capture the image from Web camera

    Qt Code:
    1. m_Palette = 0;
    2. // Open handle in an invisible window
    3. m_CapHandle = capCreateCaptureWindow((LPTSTR)"Capture Window",
    4. #if 1
    5. 0,
    6. 0, 0, 160, 120,
    7. #else
    8. WS_BORDER | WS_VISIBLE,
    9. 0, 0, 320, 240,
    10. #endif
    11. (HWND) 0, 0);
    12.  
    13.  
    14.  
    15. if (!m_CapHandle) {
    16. qWarning("Could not create capwindow handle.");
    17. }
    18. else {
    19. // Connect to capture device
    20. if (capDriverConnect(m_CapHandle, m_CapIndex)) {
    21.  
    22. // Register; this will make sure we are being callbacked (if you will excuse the grammar...)
    23. CVideoCollector::Instance((QWidget *) m_CapHandle)->RegisterDevice(m_CapHandle, this);
    24.  
    25. ret = true;
    26.  
    27. // Get the size of the video format structure & allocate memory
    28. m_BMISize = capGetVideoFormatSize(m_CapHandle);
    29. assert(m_BMISize > 0);
    30. m_pBMIBuf = new uchar[m_BMISize];
    31. m_pVideoInfo = (BITMAPINFO *)m_pBMIBuf;
    32.  
    33. // Get the actual format structure; It contains width, height, and
    34. // 'compression' info
    35. if (capGetVideoFormat(m_CapHandle, m_pBMIBuf, m_BMISize)) {
    36. qDebug("Got VideoFormat, struct size = %d", m_BMISize);
    37. DumpVideoFormat(m_pVideoInfo);
    38. }
    39. else
    40. qDebug("capGetVideoFormat failed.");
    41.  
    42. // Get initial capture status
    43. capGetStatus(m_CapHandle, &m_CaptureStatus, sizeof(m_CaptureStatus));
    44. m_ImageSize.setWidth(m_CaptureStatus.uiImageWidth);
    45. m_ImageSize.setHeight(m_CaptureStatus.uiImageHeight);
    46. }
    47. else {
    48. qWarning("Failed to connect to capDriver %d", m_CapIndex);
    49. DestroyWindow(m_CapHandle);
    50. m_CapHandle = 0;
    51. }
    52. }
    To copy to clipboard, switch view to plain text mode 

    With these date I need to create an image. How can I do it ?
    Please help me...
    Last edited by jpn; 21st December 2007 at 07:48. Reason: missing [code] tags

  9. #9
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    I don't see a single reference to QImage. How is the QImage constructed?

    PS. Use [code]-tags around code blocks, please.
    J-P Nurmi

  10. #10
    Join Date
    Jul 2007
    Posts
    166
    Thanks
    25
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    Hi,
    I need to create a QImage from that code. I can do it in Linux and the code in like is like this

    Qt Code:
    1. struct video_window vwin;
    2. struct video_audio Audio;
    3. QSize RequestedSize;
    4. uint i;
    5. const char * TEMP_NODENAME;
    6. TEMP_NODENAME = m_NodeName.toStdString( ).c_str( );
    7. m_CamFD = ::open((const char *) TEMP_NODENAME, O_RDWR);
    8.  
    9. if (m_CamFD < 0)
    10. return false;
    11.  
    12. /* Check for Philips cams */
    13. m_HasFramerate = false;
    14.  
    15. if (m_IntfName.contains ("Philips", Qt::CaseInsensitive )) {
    16. m_HasFramerate = true;
    17. }
    18. else {
    19. struct pwc_probe Probe;
    20.  
    21. if (ioctl(m_CamFD, VIDIOCPWCPROBE, &Probe) == 0) {
    22. if (m_IntfName == Probe.name) {
    23. m_HasFramerate = true;
    24. } }
    25. }
    26.  
    27. /* Probe audio functionality */
    28. if (ioctl(m_CamFD, VIDIOCGAUDIO, &Audio) == 0) {
    29. m_Mutable = (Audio.flags & VIDEO_AUDIO_MUTABLE);
    30. if (m_Mutable)
    31. qDebug("Device can be muted (usually TV card).");
    32. }
    33. else
    34. qWarning("Cannot query audio capabilities of video device.");
    35. /* See if device has mmap(); */
    36. m_VMBuf.size = 0;
    37. m_VMBuf.frames = 0;
    38. vid_io_buffer_size = 0;
    39.  
    40. if (ioctl(m_CamFD, VIDIOCGMBUF, &m_VMBuf) == 0) {
    41. vid_io_buffer_size = m_VMBuf.size;
    42. if (m_RequestedBuffers > 0) {
    43. // User specified a number of buffers; see if we can match that.
    44. if (m_VMBuf.frames < m_RequestedBuffers) {
    45. qWarning("There are more buffers requested than device can provide. Limiting to %d buffers.", m_Buffers);
    46. } else
    47. m_Buffers = m_RequestedBuffers;
    48. }
    49. else // We grab everything we can.
    50. m_Buffers = m_VMBuf.frames;
    51. }
    52. else {
    53. m_VMBuf.size = 0; // Just to be sure....
    54. m_VMBuf.frames = 0;
    55. }
    56.  
    57. /* See if we can actually mmap() the memory */
    58. if (m_VMBuf.size > 0) {
    59. vid_io_buffer = (uchar *)mmap(NULL, vid_io_buffer_size, PROT_READ | PROT_WRITE, MAP_SHARED, m_CamFD, 0);
    60. if (vid_io_buffer == (uchar *)-1) {
    61. qWarning("mmap() failed (%d). Falling back to non-mmap()ed mode.", errno);
    62. m_VMBuf.size = 0;
    63. vid_io_buffer = NULL;
    64. }
    65. else {
    66. vid_io_offsets.resize(m_Buffers);
    67. for (i = 0; i < m_Buffers; i++)
    68. vid_io_offsets[i] = m_VMBuf.offsets[i];
    69. } }
    70.  
    71. if (m_VMBuf.size == 0) { // No mmap or failed: allocate a buffer
    72. m_Buffers = m_RequestedBuffers;
    73. if (m_Buffers < 0)
    74. m_Buffers = 4; // In case the user didn't specify a buffer size, we make one.
    75. vid_io_buffer_size = m_Buffers * m_MaxSize.width() * m_MaxSize.height() * 4;
    76. vid_io_buffer = new uchar[vid_io_buffer_size];
    77. vid_io_offsets.resize(m_Buffers);
    78. for (i = 0; i < m_Buffers; i++)
    79. vid_io_offsets[i] = i * m_MaxSize.width() * m_MaxSize.height() * 4;
    80. }
    81.  
    82. if (vid_io_buffer == NULL) {
    83. qWarning("Failed to mmap/malloc memory!");
    84. return false;
    85. }
    86. // Try to set default image size (from config)
    87. memset(&vwin, 0, sizeof(vwin));
    88. RequestedSize = m_pSettings->GetSize();
    89.  
    90. if (!RequestedSize.isNull()) {
    91. vwin.width = RequestedSize.width();
    92. vwin.height = RequestedSize.height();
    93. if (m_HasFramerate) {
    94. vwin.flags |= (m_pSettings->GetFramerate() << PWC_FPS_SHIFT) & PWC_FPS_FRMASK;
    95. }
    96.  
    97. if (ioctl(m_CamFD, VIDIOCSWIN, &vwin) < 0) {
    98. qWarning("Failed to restore image size (%d, %d)", vwin.width, vwin.height);
    99. }
    100. }
    101.  
    102. // Query current image size
    103. if (ioctl(m_CamFD, VIDIOCGWIN, &vwin) < 0) {
    104. qWarning("Failed to query current image size.");
    105. }
    106. else {
    107. m_ImageSize.setWidth(vwin.width);
    108. m_ImageSize.setHeight(vwin.height);
    109. if (m_HasFramerate)
    110. {
    111. m_Framerate = (vwin.flags & PWC_FPS_FRMASK) >> PWC_FPS_SHIFT;
    112. qDebug("Initial image size = (%d, %d), framerate = %d", vwin.width, vwin.height, m_Framerate);
    113. }
    114. }
    115.  
    116. // Restore brightness, contrast, etc.
    117. m_VPic.brightness = m_pSettings->GetBrightness();
    118. m_VPic.contrast = m_pSettings->GetContrast();
    119. m_VPic.colour = m_pSettings->GetSaturation();
    120. m_VPic.hue = m_pSettings->GetHue();
    121. m_VPic.whiteness = m_pSettings->GetGamma();
    122.  
    123. if (ioctl(m_CamFD, VIDIOCSPICT, &m_VPic) < 0)
    124. qWarning("Failed to restore video controls.");
    125.  
    126. // Restore input/tuner
    127. SetInput(m_CurrentVideoInput);
    128. SetTuner(m_CurrentTuner);
    129. return true;
    130. ]
    131.  
    132. and from another function I create the QImage like this
    133.  
    134. [
    135. CreateImagesRGB()
    136. {
    137. int w, h;
    138. uint u;
    139. QImage *CImage;
    140. m_RGB.resize(m_Buffers);
    141. w = m_ImageSize.width();
    142. h = m_ImageSize.height();
    143.  
    144. if (m_Palette == VIDEO_PALETTE_RGB32) {
    145. // This is easy... map directly onto images
    146. for (u = 0; u < m_Buffers; u++) {
    147. m_RGB.insert(u, *(new QImage(vid_io_buffer + vid_io_offsets[u], w, h, QImage::Format_RGB32)));
    148. } }
    149. else {
    150. for (u = 0; u < m_Buffers; u++) {
    151. CImage = new QImage(w, h, QImage::Format_RGB32);
    152. m_RGB.insert(u, *CImage);
    153. }
    154. } }
    To copy to clipboard, switch view to plain text mode 

    and it is working.
    I need to create the same in Windows.
    Please help me..
    Last edited by marcel; 21st December 2007 at 09:29. Reason: missing [code] tags

  11. #11
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    the conversation code to QImage should stay the same.
    The only difference between windows and linux is in the sections that deal with the hardware/driver (the ioctl() calls).
    But that is something you need to look up with the respective hardware drivers under windows, it has nothing to do with Qt.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  12. #12
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: exception at 0x65100c40 (QtGuid4.dll)

    Excuse me, but perhaps you should divide the problem into a bit smaller pieces or something? Honestly, it's kind of rude to expect anyone to start interpreting that.

    PS. A proper indentation alone would make the code much more readable.

    Quote Originally Posted by sabeesh View Post
    Qt Code:
    1. [...]
    2. for (u = 0; u < m_Buffers; u++) {
    3. m_RGB.insert(u, *(new QImage(vid_io_buffer + vid_io_offsets[u], w, h, QImage::Format_RGB32)));
    4. }
    5. [...]
    6. for (u = 0; u < m_Buffers; u++) {
    7. CImage = new QImage(w, h, QImage::Format_RGB32);
    8. m_RGB.insert(u, *CImage);
    9. }
    10. [...]
    To copy to clipboard, switch view to plain text mode 
    Notice that QImage is an implicitly shared class...
    J-P Nurmi

Similar Threads

  1. Exceptions and qApp->processEvents()
    By mcostalba in forum Qt Programming
    Replies: 3
    Last Post: 8th January 2006, 18:06

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.