Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How to update DirectShow filter properties?

How to update DirectShow filter properties?

Scheduled Pinned Locked Moved C / C++ / MFC
announcementc++comdata-structureshelp
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    Vaclav_
    wrote on last edited by
    #1

    I need some basic COM / DirectShow help.
    I am using the EZrgb24 filter. No problems rendering it.
    I am trying to update filter properties (HRESULT CEZrgb24Properties::OnApplyChanges()).
    I have managed to retrieve them using the attached code.
    I semiunderstand the ISpecifyPropertyPages interface, but have no idea how to access the CEZrgb24Properties::OnApplyChanges()).
    I have been unable to find C++ sample code for updating filter properties.
    Any hit will be greatly appreciated.

    IBaseFilter \*pFilter = 0;
    ISpecifyPropertyPages \*pProp;
    HRESULT hr = pDocument->pC\_Graph->gcap.pTransferFilter->QueryInterface(IID\_ISpecifyPropertyPages,
    	(void \*\*)&pProp);
    if (SUCCEEDED(hr)) 
    {
        // Get the filter's name and IUnknown pointer.
        FILTER\_INFO FilterInfo;
        hr = pDocument->pC\_Graph->gcap.pTransferFilter->QueryFilterInfo(&FilterInfo); 
        IUnknown \*pFilterUnk;
        pDocument->pC\_Graph->gcap.pTransferFilter->QueryInterface(IID\_IUnknown, (void \*\*)&pFilterUnk);
    
        // Show the page. 
        CAUUID caGUID;
        pProp->GetPages(&caGUID);
        pProp->Release();
        OleCreatePropertyFrame(
            0, //hWnd,              // Parent window float above all 
            0, 0,                   // Reserved
            FilterInfo.achName,     // Caption for the dialog box
            1,                      // Number of objects (just the filter)
            &pFilterUnk,            // Array of object pointers. 
            caGUID.cElems,          // Number of property pages
            caGUID.pElems,          // Array of property page CLSIDs
            0,                      // Locale identifier
            0, NULL                 // Reserved
        );
    }
    
    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups