Matrox Imaging Library (MIL) 9.0 Mildisplay.Txt October 6, 2009 © Copyright Matrox Electronic Systems Ltd., 1992-2009
Total Page:16
File Type:pdf, Size:1020Kb
file:///C|/Work/mildisplay.txt -------------------------------------------------------------------------------- Matrox Imaging Library (MIL) 9.0 mildisplay.txt October 6, 2009 © Copyright Matrox Electronic Systems Ltd., 1992-2009. All rights reserved. -------------------------------------------------------------------------------- This document outlines what is new with MIL display module. It also presents last minute information that did not make it into the manual or on-line help. Note that this text file serves to complement your manual. The information found in this file overrides your formally documented material. -------------------------------------------------------------------------------- Main Table of Contents Section 1: What's new in MIL 9.0 Update 16 Section 2: What's new in MIL 9.0 -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- Section 1: What's new in MIL 9.0 Update 16 Table of Contents for Section 1 1. Exclusive Displays 1.1 Overview 1.2 Allocation of an exclusive display 1.2.1 Requirements 1.2.2 InitFlag 1.2.3 DispNum 1.2.4 DispFormat 1.3 Available MdispControl types -------------------------------------------------------------------------------- 1. Exclusive Displays file:///C|/Work/mildisplay.txt (1 of 7)10/30/2009 1:06:36 PM file:///C|/Work/mildisplay.txt 1.1 Overview ------------ Exclusive display is a new full-screen display type, designed to replace legacy auxiliary displays. One of Windows® extended desktop monitors is exclusively dedicated to display and MIL restricts mouse-cursor outside of the display limits. 1.2 Allocation of an exclusive display -------------------------------------- MIL_ID MdispAlloc(MIL_ID SystemId, MIL_INT DispNum, MIL_CONST_TEXT_PTR DispFormat, MIL_INT InitFlag, MIL_ID *DisplayIdPtr) 1.2.1 Requirements ------------------ It works on any graphic adapter and is compatible with all Video Hardware Acceleration Modes. We suggest having two or more outputs currently used on the desktop. Trying to allocate an exclusive display on the main monitor may cause some disadvantages. Most third-party applications (which are designed to start on the main monitor) would be hidden by the MIL exclusive display. Note that Windows® taskbar would also be hidden since it is commonly located on the main monitor. 1.2.2 InitFlag -------------- To allocate an exclusive display, use M_EXCLUSIVE as InitFlag. 1.2.3 DispNum ------------- The monitor to use can be specified with the DispNum Parameter. - DispNum can be specified with M_DEV0, M_DEV1, etc. - In all cases, M_DEFAULT will select the best available monitor. - For monitor arrangements up to 3x3 monitors, DispNum can be set to any combination of the following: - M_LEFT - M_RIGHT - M_TOP - M_BOTTOM - M_CENTER file:///C|/Work/mildisplay.txt (2 of 7)10/30/2009 1:06:36 PM file:///C|/Work/mildisplay.txt Anything greater will need to be set by device numbers. 1.2.3 DispFormat ---------------- This parameter specifies the screen resolution. MIL_TEXT("M_DEFAULT") will get the default screen resolution from MILConfig utility, in the "Default Values" page. In the "Default Values" page, when Exclusive display type is chosen, a few formats will be available. If M_DEFAULT is selected, the MIL Display Module will use the current display resolution. User can also specify his own screen resolution according to the following pattern "WidthxHeightxBitsperPixels@RefreshRate" Ex.: 1280x1024x32@60 1.3 Available MdispControl types -------------------------------- List of controls to modify the behavior of a M_EXCLUSIVE display - M_KEYBOARD_USE (M_ENABLE/M_DISABLE): Activates or not the use of keyboard in the exclusive display. Enabled by default. Replaces M_WINDOW_KEYBOARD_USE - M_RESTRICT_CURSOR (M_ENABLE/M_DISABLE): Restrict mouse cursor outside the exclusive display. Enabled by default. -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- Section 2: What's new in MIL 9.0 Table of Contents for Section 2 1. Video Hardware Acceleration Modes 1.1 DDraw7 1.2 Direct3D 9 1.3 Standard 1.4 Default 2. New display features in MILConfig. file:///C|/Work/mildisplay.txt (3 of 7)10/30/2009 1:06:36 PM file:///C|/Work/mildisplay.txt 3. Change to MappAlloc 4. Lock/Unlock 5. Changes to No-Tearing displays. 6. Changes to Auxiliary displays. 7. Compatibility with Windows Vista Aero Glass mode. 8. Window annotations 9. Changes concerning buffer attributes 10. Matrox P-Series Display Drivers 11. Matrox G-Series Display Drivers. 12. Limitations --------------------------------------------------------------------------------- 1. Video Hardware Acceleration Modes =============== MIL 9 Displays can run into different Video Hardware Acceleration Modes, all having pros and cons. 1.1 DDraw7 ------------ - This is the implementation which was used in MIL 8. - Required if the application uses native DDraw calls. - If using a G-Series, especially for continuous grab. - Not compatible with Vista Aero Glass mode. - Not compatible with GPU system. 1.2 Direct3D 9 ---------------- - Compatible with GPU System. - Compatible with Vista Aero Glass mode. - Required if the application uses native Direct3D calls. - Not compatible with drawings in window’ DC (see M_WINDOW_ANNOTATIONS control for details) 1.3 Standard -------------- - Does not use any DirectX implementation. - Compatible with Vista Aero Glass mode. - Not compatible with GPU systems. - Not compatible with auxiliary displays (except on Vio or Corona-II) - Cannot allocate M_DIRECTX or M_VIDEO_MEMORY buffers. - Cannot use native DDraw or Direct3D calls on MIL buffers. - No risk for display-drivers bugs - Compatible with drawings in window’ DC file:///C|/Work/mildisplay.txt (4 of 7)10/30/2009 1:06:36 PM file:///C|/Work/mildisplay.txt - Strongly recommended when using VNC or Remote Desktop, if frequently using CTRL-ALT-DEL or using other applications using DirectX exclusive mode. 1.4 Default ------------- - MIL decides which implementation is the best. 2. New display features in MILConfig. ======================================= - Video Hardware Acceleration page now allow user to choose which Video Hardware Acceleration Mode to use. - With DDraw 7 and Direct3D 9, a slider will appear, allowing the user to change the Hardware Acceleration Level. - Note that, when choosing Default, MIL will automatically choose which implementation is the best. If MIL chooses a level where acceleration level could be modified (7 or 9), it will consider the position if the corresponding slider, even if it is not currently visible in MILConfig. 3. Change to MappAlloc ======================== - User can specify on which implementation he wants to run in MappAlloc : InitFlag + M_DX_VERSION(0/7/9) - If not specified, it corresponds to Default in MILConfig 4. Lock/Unlock ================ - In DirectX it is not possible to allocate a buffer with a constant valid logical or physical address. - The address is valid while the buffer is locked and invalid after unlock. - When lock/unlock mechanism is enabled, M_HOST_ADDRESS inquire will always return NULL if user forgot to call MbufControl(.., M_LOCK,…) before and M_UNLOCK when he’s finished with the address. 5. Changes to No-Tearing displays. ==================================== - No-tearing mechanism is supported with DDraw 7 and with DirectX 9. It is not supported with Standard mode. - In DDraw 7, no-tearing is only available if Lock/Unlocks (see Item 4 above) are not active and if underlay surface is available. For those two reasons, this would not work by default for non-Matrox adapters. An error would advise the customer, explaining which changes are required in MILConfig. file:///C|/Work/mildisplay.txt (5 of 7)10/30/2009 1:06:36 PM file:///C|/Work/mildisplay.txt - In DirectX9 W, no-tearing is theorically available with all graphic adapters but with certain restrictions, due to graphic hardware limitations. MIL accesses video hardware through DirectX and is subject to DirectX, display driver and hardware limitations. In some situations no-tearing cannot be done, without any warning. Smaller images tend produce better result. Also note that no-tearing with DirectX 9 works most of the time when MIL is running under Vista with Aero Glass Mode. Note that enabling no-tearing on one DirectX9 MIL display will enable it for all displays. 6. Changes to auxiliary displays. =================================== - Auxiliary displays (except for Vio and Corona-II) is only supported in DDraw7. - Also note that, by default, hardware detection is disabled. It has to be reenabled in MILConfig to be able to use auxiliary displays. 7. Compatibility with Windows Vista Aero Glass mode. ====================================================== - DDraw7 is not compatible with Vista Aero Glass mode. Windows will automatically switch the basic mode for the life of the MIL process. - Standard mode and DirectX 9 are fully compatible with Aero. 8. Window annotations ======================== - We call window annotations all the drawings (and text) done directly in window device-context using GDI functions (Shown in MdispMFC Example) - [Non-MIL specific] Windows Vista Aero mode uses Desktop Window Manager to update the desktop. Composition of all windows and images is done in an offscreen surface, then blit to the display. - It is not possible to use Direct3D 9 for rendering and do window-annotations with GDI in the same window. For