void ArgumentCoder<WebCore::CustomFilterProgramInfo>::encode(ArgumentEncoder& encoder, const CustomFilterProgramInfo& programInfo)
{
    encoder << programInfo.vertexShaderString();
    encoder << programInfo.fragmentShaderString();
    encoder.encodeEnum(programInfo.programType());
    encoder.encodeEnum(programInfo.meshType());
    const CustomFilterProgramMixSettings& mixSettings = programInfo.mixSettings();
    encoder.encodeEnum(mixSettings.blendMode);
    encoder.encodeEnum(mixSettings.compositeOperator);
}
bool CustomFilterProgramInfo::operator==(const CustomFilterProgramInfo& o) const 
{
    ASSERT(!isHashTableDeletedValue());
    ASSERT(!o.isHashTableDeletedValue());

    return m_programType == o.m_programType
        && (m_programType != PROGRAM_TYPE_BLENDS_ELEMENT_TEXTURE || m_mixSettings == o.m_mixSettings)
        && m_meshType == o.m_meshType
        && m_vertexShaderString == o.m_vertexShaderString
        && m_fragmentShaderString == o.m_fragmentShaderString;
}
void CoordinatedGraphicsScene::createCustomFilterProgram(int id, const CustomFilterProgramInfo& programInfo)
{
    ASSERT(!m_customFilterPrograms.contains(id));
    m_customFilterPrograms.set(id, CoordinatedCustomFilterProgram::create(programInfo.vertexShaderString(), programInfo.fragmentShaderString(), programInfo.programType(), programInfo.mixSettings(), programInfo.meshType()));
}