Скачать презентацию How WCS in Windows Vista works with Drivers Скачать презентацию How WCS in Windows Vista works with Drivers

6b45c850b9fa888703b679f5adb60d11.ppt

  • Количество слайдов: 49

How WCS in Windows Vista works with Drivers and Applications Michael Stokes Microsoft Color How WCS in Windows Vista works with Drivers and Applications Michael Stokes Microsoft Color Architect © 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

Introduction Introduction

WCS in Windows Vista™ is A new color management paradigm and infrastructure A transparent, WCS in Windows Vista™ is A new color management paradigm and infrastructure A transparent, modular, color processing pipeline that allows for easy color troubleshooting A new development platform for advanced color devices and applications A platform for innovation in color management The first step in a staged implementation process that will span several Windows releases NOT MANDATORY If it doesn’t make business sense in your workflow, if it’s not better, don’t use it.

WCS Features Continued, improved support for ICC-based workflows New explicitly staged color processing pipeline WCS Features Continued, improved support for ICC-based workflows New explicitly staged color processing pipeline New, Simple XML Profile Formats Easy to edit, verify, understand extend by third parties New Visual Model CIECAM 02 instead of reflection-print-like PCS Built-in baseline device models for common device classes Extensible by third party plug-in device models Selectable gamut mapping models Support for third party plug-in gamut mapping models for proprietary algorithms or improvements on baseline gamut mapping models Transforms can support black preservation Support for high dynamic range, wide gamut, high precision color data (up to 32 bpc float) sc. RGB with a realistically defined gamut boundary (“wsc. RGB”) Enables color managed proprietary and open RAW workflows New centralized color control panel Per-user as well as system-wide profile/device associations, defaults, and settings Non-Admin users can now install/uninstall profiles

Linear ROI Model Legacy compatible WCS XML data as private tags of ICC profiles Linear ROI Model Legacy compatible WCS XML data as private tags of ICC profiles WCS processing accessible via legacy ICM 2 APIs New functionality WCS XML data directly associated with devices New WCS APIs sharing legacy syntax

Windows Color System and ICC workflows WCS still supports and defaults to the same Windows Color System and ICC workflows WCS still supports and defaults to the same s. RGB ICC profile as previous Windows versions Seamless interoperability with ICC profile-based workflows ICC-only transforms run through improved ICM 3 CMM Mixed ICC & WCS transforms run through WCS CITE Any existing code that uses ICM 2 APIs will continue to work without any change required ICC Version 4 support is added to ICM Addressing key recorded ICM bugs Implement new functionality via current ICM 2 APIs Old applications work with new profiles New profile format is processed by current ICM 2 APIs

Compatibility Demonstrations Compatibility Demonstrations

WCS Components WCS Components

The Parts of the Windows Color System New WCS XML-based color profile formats Color The Parts of the Windows Color System New WCS XML-based color profile formats Color Infrastructure & Translation Engine (CITE) The Color Appearance Model (CAM) Based on CIECAM 02 Gamut Boundary and Gamut Shell Functions The Baseline Device Model Set Extensible via Device Model Plug-ins The Baseline Gamut Map Model Set Extensible via Gamut Map Model Plug-ins And of course the improved ICM CMM, with ICC version 4 profile support added

WCS Pipeline WCS Pipeline

WCS Profile Formats Each type has its own schema Device Model Profile (DMP), file WCS Profile Formats Each type has its own schema Device Model Profile (DMP), file extension “. cdmp” A DMP targets a particular device model, either one of the built-in “baseline” device models, or a plug-in device model DMPs targeting plug-in device models must also specify a baseline device model as a fallback Color Appearance Model Profile (CAMP), “. camp” A CAMP provides the parameters to the CIECAM 02 equations for a specific viewing condition. Gamut Map Model Profile (GMMP), “. gmmp” A GMMP targets a particular gamut mapping model, either one of the built-in baseline gamut mapping models, or a plug-in gamut mapping model. As with DMPs, a GMMP that targets a plug-in GMM must also specify a baseline gamut mapping model as a fallback. WCS profiles are embedded in image formats as a private tag in a WCS-created approximating ICC profile Necessary for interoperability off of Windows Vista™

A WCS s. RGB profile A WCS s. RGB profile

WCS Device Models WCS device models use the measurement data from a DMP to WCS Device Models WCS device models use the measurement data from a DMP to instantiate a model that relates device color space coordinates to CIEXYZ Baseline device models implement different algorithms and processing models for different device classes Third parties can extend the set of device models by writing plug-in device models

WCS Baseline Device Models CRT Device Model LCD Device Model RGB Capture Device Model WCS Baseline Device Models CRT Device Model LCD Device Model RGB Capture Device Model RGB Projector Device Model RGB Printer Device Model CMYK Printer Device Model RGB Virtual Device Model Used for wcs. RGB ICC Virtual Device Model Enables use of ICC profiles in WCS transforms

WCS Gamut Mapping Models (GMMs) All gamut mapping is performed between explicit source and WCS Gamut Mapping Models (GMMs) All gamut mapping is performed between explicit source and destination GBD Shells in CIECAM 02 JCh WCS Baseline Gamut Mapping Models correspond roughly to ICC rendering intents Third parties can extend the set of available GMMs by writing gamut mapping plug-ins

WCS Baseline GMMs Sigmoidal Gaussian Knee Clipping (SGKC) Equivalent to ICC’s preferred, pictorial, or WCS Baseline GMMs Sigmoidal Gaussian Knee Clipping (SGKC) Equivalent to ICC’s preferred, pictorial, or perceptual intent. Selected by Photo. gmmp Minimum Color Difference (Min. CD) Equivalent to ICC colorimetric intents: Relative if neutral axis mapping is done Selected by Proofing. gmmp Absolute without neutral axis mapping Selected by Media. Sim. gmmp Hue. Map Equivalent to ICC saturation or business graphics intent Selected by Graphics. gmmp

Programming WCS Programming WCS

Open a Color Profile ICC or DMP filename DMP CAMP GMMP filename Open. Color. Open a Color Profile ICC or DMP filename DMP CAMP GMMP filename Open. Color. Profile() Wcs. Open. Color. Profile() Default Profiles in Registry HPROFILE

Create. Multi. Profile. Transform HTRANSFORM WINAPI Create. Multi. Profile. Transform( PHPROFILE pah. Profiles, // Create. Multi. Profile. Transform HTRANSFORM WINAPI Create. Multi. Profile. Transform( PHPROFILE pah. Profiles, // ptr to array of HPROFILEs DWORD n. Profiles, // number of HPROFILEs (max 10) PDWORD padw. Intent, // ptr to array of intents DWORD n. Intents, // number of intents (max 10) DWORD dw. Flags, // DWORD index. Preferred. CMM // ignored if any WCS profiles ); pah. Profiles - profile array can contain a mix of ICC and WCS profile handles If only ICC profiles are used, processing will be via the improved ICM CMM “WCS_ALWAYS” in dw. Flags will force WCS CITE processing in all-ICC-profile case n. Intents must equal 1, n. Profiles -1, or n. Profiles Intents corresponding to WCS HPROFILEs will result in the use of the corresponding default GMMP mapped to that intent. Intents specified in the padw. Intent array trump GMMPs in WCS HPROFILEs, unless… For WCS profiles, setting the corresponding intent in padw. Intent to DWORD_MAX will force use of GMMPs contained in WCS HPROFILEs (constructed with Wcs. Open. Color. Profile). ICC Device. Link, Abstract, and Named. Color profiles are not supported in combination with WCS profiles.

Transform Profile Sequence Example padw. Intent INTENT_PECEPTUAL DWORD_MAX HPROFILE A HPROFILE B HPROFILE C Transform Profile Sequence Example padw. Intent INTENT_PECEPTUAL DWORD_MAX HPROFILE A HPROFILE B HPROFILE C DMPA DMPB DMPC CAMPA CAMPB CAMPC GMMPA GMMPB GMMPC DMPA +CAMPA GBDA Default Profiles in Registry DMPC +CAMPC DMPB +CAMPB GMMPPercep. GBDB GMMPB GBDC

Color Control Panel Demonstration Color Control Panel Demonstration

Demonstrations Demonstrations

Win. HEC Demo Station #1 Win. HEC Demo Station #1

Win. HEC Demo Station #1 Transparency Currently, all the WCS internal design documents are Win. HEC Demo Station #1 Transparency Currently, all the WCS internal design documents are available under NDA All algorithms are published for WCS in Windows Vista™ in MSDN Legacy compatible APIs and Data formats Office 12 compatibility Adobe CS 2 compatibility Vista Picture Gallery compatibility 10 bpc content to hardware EIZO NANAO R 31 c medical imaging display

Win. HEC Demo Station #2 Win. HEC Demo Station #2

Win. HEC Demo Station #2 WCS advantages in 8 bpc workflows Wide Gamut Supports Win. HEC Demo Station #2 WCS advantages in 8 bpc workflows Wide Gamut Supports very wide DSC and working space gamuts such as Pro. Photo without clipping High Dynamic Range Supports RGB virtual device space for values above diffuse white (and below reference black) WCS advantages in >8 bpc workflows Visual difference in currently shipping hardware NEC wide gamut 10 bpc display, ATI x 1300 and Nikon D 1 x WCS eliminate contour artifacts due to ICC HDR limitations

Win. HEC Demo Station #3 Win. HEC Demo Station #3

Win. HEC Demo Station #3 WCS software utility demonstration Monotype Imaging Integrated support for Win. HEC Demo Station #3 WCS software utility demonstration Monotype Imaging Integrated support for WCS profiles Developed CMYK printer plugin with parameterized controls …in five working days Seiko Epson 2400 CMYK printer Mitsubishi display demonstration Automatic synchronization of associated profile with display hardware Change white point with display remote, profile is automatically updated to match Mitsubishi/NEDO very wide gamut, bright display prototype

XPS and WCS Demonstration CMYK and n-channel support in IE XPS and WCS Demonstration CMYK and n-channel support in IE

Application/Driver Color Communication Conversations to avoid “double color management” “What profile do you think Application/Driver Color Communication Conversations to avoid “double color management” “What profile do you think best matches your current state? ” “I’ve already done the color conversion with this profile: Do no further color management (CM)” “You do the CM using this destination profile” “You do the CM using your idea of the best profile for your current state” “You apply your propriety color magic” “I’ve created a color managed print DC, you do no further CM”

In Summary WSC supports existing color workflows WCS provides continuing, enhanced ICC support WCS In Summary WSC supports existing color workflows WCS provides continuing, enhanced ICC support WCS supports “high, wide, & deep” color WCS implement state-of-the art color science WCS represents a commitment by Microsoft to provide an extensible platform for color innovation that will be viable for years to come

Color Best Practices Populate, persist, and promote accurate metadata Associate and embed accurate color Color Best Practices Populate, persist, and promote accurate metadata Associate and embed accurate color profiles Use and preserve embedded profiles If you change color space, update the metadata If you don’t understand the metadata, preserve it Have your installers associate profiles with your devices If it’s not actually an s. RGB device, it should have associated profile(s) Minimize number of color conversions in your workflows Your driver should be aware of your device state and the correct profile for that state WCS provides choices – choose what makes sense for your business

Opportunities And Advantages Your ICC-based workflows continue to work and can now take advantage Opportunities And Advantages Your ICC-based workflows continue to work and can now take advantage of version 4 ICC profiles The new WCS XML-based color profiles are easily programmatically updated, enabling self-characterizing devices Third parties can add value via new plug-in device models and gamut mapping models Vendors can write DM and GMM plug-ins that communicate with one another during processing Support for high dynamic range, wide gamut, high precision color data (HWD) in WCS enables integration of such innovative devices into color managed workflows

Community Email questions/feedback to mscolor @microsoft. com WCS “Color at Microsoft” blog at http: Community Email questions/feedback to mscolor @microsoft. com WCS “Color at Microsoft” blog at http: //blogs. msdn. com/color_blog

Questions Questions

© 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. © 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

Backup Slides Backup Slides

Extensibility Scenario Overview Extensibility Scenario Overview

Scenario: Advanced Color Windows Photo Gallery prints Windows Media Photo image to XPSDrv print Scenario: Advanced Color Windows Photo Gallery prints Windows Media Photo image to XPSDrv print driver for 8 -color inkjet photo printer

Scenario: Advanced Color XPS Documents support high dynamic range, wide gamut vector and image Scenario: Advanced Color XPS Documents support high dynamic range, wide gamut vector and image content Using system services, filters can process rich color data to best match printed output to user intent and device capabilities Windows Color System (WCS) – Enables extensive color conversion Windows Imaging Components (WIC) – Image format support for Windows Media Photo and other XPS image formats Print. Ticket – Supports an array of color processing keywords to enable consistent and unambiguous color control between app and device

Scenario: Advanced Color Data Flow Windows Photo Gallery allows user selection of print settings Scenario: Advanced Color Data Flow Windows Photo Gallery allows user selection of print settings MXDW driver encapsulates Windows Media Photo image and print settings (as Print. Ticket) in XPS Document Filter process XPS file, decoding/transforming image, saving image to JPG format

Advanced Color Filter Advanced Color Filter

Color Filter: Main Method HRESULT CColor. Filter: : Start. Operation(void) { HRESULT hr = Color Filter: Main Method HRESULT CColor. Filter: : Start. Operation(void) { HRESULT hr = Setup. Color. Transform(L“ws. RGB. cdmp"); ") CCom. Ptr p. Unk; while (SUCCEEDED(hr = m_p. Provider->Get. Xps. Part(&p. Unk))) Get. Xps. Part(&p. Unk) { CCom. Ptr p. XD; CCom. Ptr p. FP; if (SUCCEEDED(p. Unk. Query. Interface(&p. XD))) { hr = m_p. Consumer->Send. Xps. Document(p. XD); } else if. . . else if (SUCCEEDED(p. Unk. Query. Interface(&p. FP))) { Query. Interface(&p. FP) hr = Process. Fixed. Page(p. FP); Process. Fixed. Page(p. FP) hr = m_p. Consumer->Send. Fixed. Page(p. FP); Send. Fixed. Page(p. FP) } } m_p. Consumer->Close. Sender(); m_p. Print. Pipe. Manager->Filter. Finished(); Delete. Color. Transform(m_h. Color. Trans) return hr; }

Color Filter: Setup Transformation HPROFILE Open. Color. Profile(const WCHAR * psz. Profile. Name) { Color Filter: Setup Transformation HPROFILE Open. Color. Profile(const WCHAR * psz. Profile. Name) { PROFILE profile = { PROFILE_FILENAME, (PVOID) psz. Profile. Name, (DWORD) (wcslen(psz. Profile. Name) * sizeof(WCHAR)) }; return Wcs. Open. Color. Profile(&profile, NULL, PROFILE_READ, FILE_SHARE_READ, OPEN_EXISTING, 0); } HRESULT Setup. Color. Transform(const WCHAR * psz. Dest. Profile. Name) { HRESULT hr = S_OK; HPROFILE h. Profile[2]; h. Profile[0] = Open. Color. Profile(L"wsc. RGB. cdmp"); h. Profile[1] = Open. Color. Profile(psz. Dest. Profile. Name); DWORD intents = INTENT_ABSOLUTE_COLORIMETRIC; m_h. Color. Trans = Create. Multi. Profile. Transform(h. Profile, 2, &intents, 1, WCS_ALWAYS | BEST_MODE, INDEX_DONT_CARE); INDEX_DONT_CARE) Close. Color. Profile(h. Profile[0]); Close. Color. Profile(h. Profile[1]); return hr; }

Color Filter: Page Processing HRESULT CColor. Filter: : Process. Fixed. Page(IFixed. Page* p. FP) Color Filter: Page Processing HRESULT CColor. Filter: : Process. Fixed. Page(IFixed. Page* p. FP) { HRESULT hr = S_OK; CCom. Ptr p. Writer; if (SUCCEEDED(hr = p. FP->Get. Write. Stream(&p. Writer))) { Get. Write. Stream(&p. Writer) CCom. Ptr p. Reader; if (SUCCEEDED(hr = p. FP->Get. Stream(&p. Reader))) { Get. Stream(&p. Reader) CXml. Filter filter(p. Writer, p. Reader); // XML filter p. Reader) while (filter. Get. Token()) filter. Get. Token() if (wcscmp(filter. m_token, L"Image. Source") == 0) { 0 filter. Get. Token(); // = filter. Get. Token(); // URI for Image. Source Convert. Image(filter. m_token, filter. m_tokenlen, COUNTOF(filter. m_token), p. FP); } } } p. Writer->Close(); } return hr; }

Color Filter: Transform Image HRESULT Convert. Write. Image(p. Stream, image. Uri, p. Fixed. Page) Color Filter: Transform Image HRESULT Convert. Write. Image(p. Stream, image. Uri, p. Fixed. Page) { HRESULT hr = S_OK; CCom. Ptr p. Read; CCom. Ptr p. Image. Part; CCom. Ptr p. Image. Stream; if (SUCCEEDED(hr = p. Fixed. Page->Get. Page. Part(image. Uri, &p. Read)) && &p. Read) SUCCEEDED(hr = p. Read. Query. Interface(&p. Image. Part)) && SUCCEEDED(hr = p. Image. Part->Get. Stream(&p. Image. Stream))) { p. Image. Part->Get. Stream(&p. Image. Stream) CImage src; CImage dst; CPrint. Stream 2 IStream read. Stream(p. Image. Stream, NULL); hr = src. Load(& read. Stream, m_p. Imaging. Factory); m_p. Imaging. Factory) hr = dst. Create(src. m_Width, src. m_Height, BM_BGRTRIPLETS); TRIPLETS) Translate. Bitmap. Bits(m_h. Color. Trans, src. m_p. Buffer, src. m_icm. Format, src. m_Width, src. m_Height, src. m_Stride, dst. m_p. Buffer, dst. m_icm. Format, dst. m_Stride, NULL); NULL) CPrint. Stream 2 IStream write. Stream(NULL, p. Stream); hr = dst. Save(& write. Stream, m_p. Imaging. Factory); m_p. Imaging. Factory) } return hr; }

Central Color Control Panel Central Color Control Panel

Central Color Control Panel Central Color Control Panel

Central Color Control Panel Central Color Control Panel