src/video/quartz/SDL_QuartzVideo.m
branchSDL-1.2
changeset 8040 22a7f096bb9d
parent 7069 f7fd5c3951b9
equal deleted inserted replaced
7991:cfec3f86fba7 8040:22a7f096bb9d
  1633         return -1;
  1633         return -1;
  1634 }
  1634 }
  1635 
  1635 
  1636 int QZ_SetGammaRamp (_THIS, Uint16 *ramp)
  1636 int QZ_SetGammaRamp (_THIS, Uint16 *ramp)
  1637 {
  1637 {
       
  1638     /* These no longer work on Mac OS X, and crash on some drivers (Intel HD
       
  1639         4000 on Mac OS X 10.9, for example). */
       
  1640     return -1;
       
  1641 #if 0
  1638     const uint32_t tableSize = 256;
  1642     const uint32_t tableSize = 256;
  1639     CGGammaValue redTable[tableSize];
  1643     CGGammaValue redTable[tableSize];
  1640     CGGammaValue greenTable[tableSize];
  1644     CGGammaValue greenTable[tableSize];
  1641     CGGammaValue blueTable[tableSize];
  1645     CGGammaValue blueTable[tableSize];
  1642 
  1646 
  1655     if ( CGDisplayNoErr == CGSetDisplayTransferByTable
  1659     if ( CGDisplayNoErr == CGSetDisplayTransferByTable
  1656          (display_id, tableSize, redTable, greenTable, blueTable) )
  1660          (display_id, tableSize, redTable, greenTable, blueTable) )
  1657         return 0;
  1661         return 0;
  1658     else
  1662     else
  1659         return -1;
  1663         return -1;
       
  1664 #endif
  1660 }
  1665 }
  1661 
  1666 
  1662 int QZ_GetGammaRamp (_THIS, Uint16 *ramp)
  1667 int QZ_GetGammaRamp (_THIS, Uint16 *ramp)
  1663 {
  1668 {
       
  1669     /* These no longer work on Mac OS X, and crash on some drivers (Intel HD
       
  1670         4000 on Mac OS X 10.9, for example). */
       
  1671     return -1;
       
  1672 #if 0
  1664     const uint32_t tableSize = 256;
  1673     const uint32_t tableSize = 256;
  1665     CGGammaValue redTable[tableSize];
  1674     CGGammaValue redTable[tableSize];
  1666     CGGammaValue greenTable[tableSize];
  1675     CGGammaValue greenTable[tableSize];
  1667     CGGammaValue blueTable[tableSize];
  1676     CGGammaValue blueTable[tableSize];
  1668     uint32_t actual;
  1677     uint32_t actual;
  1683 
  1692 
  1684     for (i=512; i < 768; i++)
  1693     for (i=512; i < 768; i++)
  1685         ramp[i] = blueTable[i % tableSize] * 65535.0;
  1694         ramp[i] = blueTable[i % tableSize] * 65535.0;
  1686 
  1695 
  1687     return 0;
  1696     return 0;
  1688 }
  1697 #endif
  1689 
  1698 }
       
  1699