Lines Matching refs:to
550 crStateError(__LINE__, __FILE__, GL_INVALID_ENUM, "Invalid Enum passed to Enable/Disable Client State: SECONDARY_COLOR_ARRAY_EXT - EXT_secondary_color is not enabled." );
556 crStateError(__LINE__, __FILE__, GL_INVALID_ENUM, "Invalid Enum passed to Enable/Disable Client State: 0x%x", array );
739 /*Note: According to opengl spec, only size==3 should be accepted here.
742 *Having a strict check here, leads to difference between guest and host gpu states, which
743 *in turn could lead to crashes when using server side VBOs.
744 *@todo: add error reporting to state's VBO related functions and abort dispatching to
745 *real gpu on any failure to prevent other possible issues.
1364 crStateError(__LINE__, __FILE__, GL_INVALID_ENUM, "Invalid Enum passed to glGetPointerv: SECONDARY_COLOR_ARRAY_EXT - EXT_secondary_color is not enabled." );
1680 * Called by glDrawElements() in packing SPUs to determine if glDrawElements
1682 * packed and sent to the server.
1706 const CRClientState *to = &(toCtx->client);
1724 if (from->array.v.size != to->array.v.size ||
1725 from->array.v.type != to->array.v.type ||
1726 from->array.v.stride != to->array.v.stride ||
1727 from->array.v.p != to->array.v.p ||
1728 from->array.v.buffer != to->array.v.buffer) {
1729 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.v.buffer);
1735 diff_api.VertexPointer(to->array.v.size, to->array.v.type,
1736 to->array.v.stride, to->array.v.p);
1737 from->array.v.size = to->array.v.size;
1738 from->array.v.type = to->array.v.type;
1739 from->array.v.stride = to->array.v.stride;
1740 from->array.v.p = to->array.v.p;
1741 from->array.v.buffer = to->array.v.buffer;
1747 if (from->array.n.type != to->array.n.type ||
1748 from->array.n.stride != to->array.n.stride ||
1749 from->array.n.p != to->array.n.p ||
1750 from->array.n.buffer != to->array.n.buffer) {
1751 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.n.buffer);
1757 diff_api.NormalPointer(to->array.n.type,
1758 to->array.n.stride, to->array.n.p);
1759 from->array.n.type = to->array.n.type;
1760 from->array.n.stride = to->array.n.stride;
1761 from->array.n.p = to->array.n.p;
1762 from->array.n.buffer = to->array.n.buffer;
1768 if (from->array.c.size != to->array.c.size ||
1769 from->array.c.type != to->array.c.type ||
1770 from->array.c.stride != to->array.c.stride ||
1771 from->array.c.p != to->array.c.p ||
1772 from->array.c.buffer != to->array.c.buffer) {
1773 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.c.buffer);
1779 diff_api.ColorPointer(to->array.c.size, to->array.c.type,
1780 to->array.c.stride, to->array.c.p);
1781 from->array.c.size = to->array.c.size;
1782 from->array.c.type = to->array.c.type;
1783 from->array.c.stride = to->array.c.stride;
1784 from->array.c.p = to->array.c.p;
1785 from->array.c.buffer = to->array.c.buffer;
1791 if (from->array.i.type != to->array.i.type ||
1792 from->array.i.stride != to->array.i.stride ||
1793 from->array.i.p != to->array.i.p ||
1794 from->array.i.buffer != to->array.i.buffer) {
1795 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.i.buffer);
1801 diff_api.IndexPointer(to->array.i.type,
1802 to->array.i.stride, to->array.i.p);
1803 from->array.i.type = to->array.i.type;
1804 from->array.i.stride = to->array.i.stride;
1805 from->array.i.p = to->array.i.p;
1806 from->array.i.buffer = to->array.i.buffer;
1813 if (from->array.t[i].size != to->array.t[i].size ||
1814 from->array.t[i].type != to->array.t[i].type ||
1815 from->array.t[i].stride != to->array.t[i].stride ||
1816 from->array.t[i].p != to->array.t[i].p ||
1817 from->array.t[i].buffer != to->array.t[i].buffer) {
1818 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.t[i].buffer);
1826 diff_api.TexCoordPointer(to->array.t[i].size, to->array.t[i].type,
1827 to->array.t[i].stride, to->array.t[i].p);
1828 from->array.t[i].size = to->array.t[i].size;
1829 from->array.t[i].type = to->array.t[i].type;
1830 from->array.t[i].stride = to->array.t[i].stride;
1831 from->array.t[i].p = to->array.t[i].p;
1832 from->array.t[i].buffer = to->array.t[i].buffer;
1839 if (from->array.e.stride != to->array.e.stride ||
1840 from->array.e.p != to->array.e.p ||
1841 from->array.e.buffer != to->array.e.buffer) {
1842 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.e.buffer);
1848 diff_api.EdgeFlagPointer(to->array.e.stride, to->array.e.p);
1849 from->array.e.stride = to->array.e.stride;
1850 from->array.e.p = to->array.e.p;
1851 from->array.e.buffer = to->array.e.buffer;
1857 if (from->array.s.size != to->array.s.size ||
1858 from->array.s.type != to->array.s.type ||
1859 from->array.s.stride != to->array.s.stride ||
1860 from->array.s.p != to->array.s.p ||
1861 from->array.s.buffer != to->array.s.buffer) {
1862 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.s.buffer);
1868 diff_api.SecondaryColorPointerEXT(to->array.s.size, to->array.s.type,
1869 to->array.s.stride, to->array.s.p);
1870 from->array.s.size = to->array.s.size;
1871 from->array.s.type = to->array.s.type;
1872 from->array.s.stride = to->array.s.stride;
1873 from->array.s.p = to->array.s.p;
1874 from->array.s.buffer = to->array.s.buffer;
1880 if (from->array.f.type != to->array.f.type ||
1881 from->array.f.stride != to->array.f.stride ||
1882 from->array.f.p != to->array.f.p ||
1883 from->array.f.buffer != to->array.f.buffer) {
1884 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.f.buffer);
1890 diff_api.FogCoordPointerEXT(to->array.f.type,
1891 to->array.f.stride, to->array.f.p);
1892 from->array.f.type = to->array.f.type;
1893 from->array.f.stride = to->array.f.stride;
1894 from->array.f.p = to->array.f.p;
1895 from->array.f.buffer = to->array.f.buffer;
1903 if (from->array.a[i].size != to->array.a[i].size ||
1904 from->array.a[i].type != to->array.a[i].type ||
1905 from->array.a[i].stride != to->array.a[i].stride ||
1906 from->array.a[i].normalized != to->array.a[i].normalized ||
1907 from->array.a[i].p != to->array.a[i].p ||
1908 from->array.a[i].buffer != to->array.a[i].buffer) {
1909 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.a[i].buffer);
1915 diff_api.VertexAttribPointerARB(i, to->array.a[i].size,
1916 to->array.a[i].type,
1917 to->array.a[i].normalized,
1918 to->array.a[i].stride,
1919 to->array.a[i].p);
1920 from->array.a[i].size = to->array.a[i].size;
1921 from->array.a[i].type = to->array.a[i].type;
1922 from->array.a[i].stride = to->array.a[i].stride;
1923 from->array.a[i].normalized = to->array.a[i].normalized;
1924 from->array.a[i].p = to->array.a[i].p;
1925 from->array.a[i].buffer = to->array.a[i].buffer;
1943 if (from->array.v.enabled != to->array.v.enabled) {
1944 able[to->array.v.enabled](GL_VERTEX_ARRAY);
1945 from->array.v.enabled = to->array.v.enabled;
1947 if (from->array.n.enabled != to->array.n.enabled) {
1948 able[to->array.n.enabled](GL_NORMAL_ARRAY);
1949 from->array.n.enabled = to->array.n.enabled;
1951 if (from->array.c.enabled != to->array.c.enabled) {
1952 able[to->array.c.enabled](GL_COLOR_ARRAY);
1953 from->array.c.enabled = to->array.c.enabled;
1955 if (from->array.i.enabled != to->array.i.enabled) {
1956 able[to->array.i.enabled](GL_INDEX_ARRAY);
1957 from->array.i.enabled = to->array.i.enabled;
1960 if (from->array.t[i].enabled != to->array.t[i].enabled) {
1963 able[to->array.t[i].enabled](GL_TEXTURE_COORD_ARRAY);
1964 from->array.t[i].enabled = to->array.t[i].enabled;
1967 if (from->array.e.enabled != to->array.e.enabled) {
1968 able[to->array.e.enabled](GL_EDGE_FLAG_ARRAY);
1969 from->array.e.enabled = to->array.e.enabled;
1971 if (from->array.s.enabled != to->array.s.enabled) {
1972 able[to->array.s.enabled](GL_SECONDARY_COLOR_ARRAY_EXT);
1973 from->array.s.enabled = to->array.s.enabled;
1975 if (from->array.f.enabled != to->array.f.enabled) {
1976 able[to->array.f.enabled](GL_FOG_COORDINATE_ARRAY_EXT);
1977 from->array.f.enabled = to->array.f.enabled;
1980 if (from->array.a[i].enabled != to->array.a[i].enabled) {
1981 if (to->array.a[i].enabled)
1985 from->array.a[i].enabled = to->array.a[i].enabled;
1991 if (to->curClientTextureUnit != curClientTextureUnit)
1993 diff_api.ClientActiveTextureARB(GL_TEXTURE0_ARB + to->curClientTextureUnit);
2003 const CRClientState *to = &(toCtx->client);
2020 if (from->array.v.size != to->array.v.size ||
2021 from->array.v.type != to->array.v.type ||
2022 from->array.v.stride != to->array.v.stride ||
2023 from->array.v.p != to->array.v.p ||
2024 from->array.v.buffer != to->array.v.buffer) {
2025 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.v.buffer);
2031 diff_api.VertexPointer(to->array.v.size, to->array.v.type,
2032 to->array.v.stride, to->array.v.p);
2041 if (from->array.n.type != to->array.n.type ||
2042 from->array.n.stride != to->array.n.stride ||
2043 from->array.n.p != to->array.n.p ||
2044 from->array.n.buffer != to->array.n.buffer) {
2045 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.n.buffer);
2051 diff_api.NormalPointer(to->array.n.type,
2052 to->array.n.stride, to->array.n.p);
2061 if (from->array.c.size != to->array.c.size ||
2062 from->array.c.type != to->array.c.type ||
2063 from->array.c.stride != to->array.c.stride ||
2064 from->array.c.p != to->array.c.p ||
2065 from->array.c.buffer != to->array.c.buffer) {
2066 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.c.buffer);
2072 diff_api.ColorPointer(to->array.c.size, to->array.c.type,
2073 to->array.c.stride, to->array.c.p);
2082 if (from->array.i.type != to->array.i.type ||
2083 from->array.i.stride != to->array.i.stride ||
2084 from->array.i.p != to->array.i.p ||
2085 from->array.i.buffer != to->array.i.buffer) {
2086 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.i.buffer);
2092 diff_api.IndexPointer(to->array.i.type,
2093 to->array.i.stride, to->array.i.p);
2103 if (from->array.t[i].size != to->array.t[i].size ||
2104 from->array.t[i].type != to->array.t[i].type ||
2105 from->array.t[i].stride != to->array.t[i].stride ||
2106 from->array.t[i].p != to->array.t[i].p ||
2107 from->array.t[i].buffer != to->array.t[i].buffer) {
2108 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.t[i].buffer);
2116 diff_api.TexCoordPointer(to->array.t[i].size, to->array.t[i].type,
2117 to->array.t[i].stride, to->array.t[i].p);
2127 if (from->array.e.stride != to->array.e.stride ||
2128 from->array.e.p != to->array.e.p ||
2129 from->array.e.buffer != to->array.e.buffer) {
2130 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.e.buffer);
2136 diff_api.EdgeFlagPointer(to->array.e.stride, to->array.e.p);
2145 if (from->array.s.size != to->array.s.size ||
2146 from->array.s.type != to->array.s.type ||
2147 from->array.s.stride != to->array.s.stride ||
2148 from->array.s.p != to->array.s.p ||
2149 from->array.s.buffer != to->array.s.buffer) {
2150 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.s.buffer);
2156 diff_api.SecondaryColorPointerEXT(to->array.s.size, to->array.s.type,
2157 to->array.s.stride, to->array.s.p);
2166 if (from->array.f.type != to->array.f.type ||
2167 from->array.f.stride != to->array.f.stride ||
2168 from->array.f.p != to->array.f.p ||
2169 from->array.f.buffer != to->array.f.buffer) {
2170 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.f.buffer);
2176 diff_api.FogCoordPointerEXT(to->array.f.type,
2177 to->array.f.stride, to->array.f.p);
2188 if (from->array.a[i].size != to->array.a[i].size ||
2189 from->array.a[i].type != to->array.a[i].type ||
2190 from->array.a[i].stride != to->array.a[i].stride ||
2191 from->array.a[i].normalized != to->array.a[i].normalized ||
2192 from->array.a[i].p != to->array.a[i].p ||
2193 from->array.a[i].buffer != to->array.a[i].buffer) {
2194 GLint idHwArrayBufferUsed = CR_BUFFER_HWID(to->array.a[i].buffer);
2200 diff_api.VertexAttribPointerARB(i, to->array.a[i].size,
2201 to->array.a[i].type,
2202 to->array.a[i].normalized,
2203 to->array.a[i].stride,
2204 to->array.a[i].p);
2225 if (from->array.v.enabled != to->array.v.enabled) {
2226 able[to->array.v.enabled](GL_VERTEX_ARRAY);
2230 if (from->array.n.enabled != to->array.n.enabled) {
2231 able[to->array.n.enabled](GL_NORMAL_ARRAY);
2235 if (from->array.c.enabled != to->array.c.enabled) {
2236 able[to->array.c.enabled](GL_COLOR_ARRAY);
2240 if (from->array.i.enabled != to->array.i.enabled) {
2241 able[to->array.i.enabled](GL_INDEX_ARRAY);
2246 if (from->array.t[i].enabled != to->array.t[i].enabled) {
2249 able[to->array.t[i].enabled](GL_TEXTURE_COORD_ARRAY);
2254 if (from->array.e.enabled != to->array.e.enabled) {
2255 able[to->array.e.enabled](GL_EDGE_FLAG_ARRAY);
2259 if (from->array.s.enabled != to->array.s.enabled) {
2260 able[to->array.s.enabled](GL_SECONDARY_COLOR_ARRAY_EXT);
2264 if (from->array.f.enabled != to->array.f.enabled) {
2265 able[to->array.f.enabled](GL_FOG_COORDINATE_ARRAY_EXT);
2270 if (from->array.a[i].enabled != to->array.a[i].enabled) {
2271 if (to->array.a[i].enabled)
2282 if (to->curClientTextureUnit != curClientTextureUnit)
2284 diff_api.ClientActiveTextureARB(GL_TEXTURE0_ARB + to->curClientTextureUnit);
2289 if (from->unpack.rowLength != to->unpack.rowLength)
2291 diff_api.PixelStorei(GL_UNPACK_ROW_LENGTH, to->unpack.rowLength);
2295 if (from->unpack.skipRows != to->unpack.skipRows)
2297 diff_api.PixelStorei(GL_UNPACK_SKIP_ROWS, to->unpack.skipRows);
2301 if (from->unpack.skipPixels != to->unpack.skipPixels)
2303 diff_api.PixelStorei(GL_UNPACK_SKIP_PIXELS, to->unpack.skipPixels);
2307 if (from->unpack.alignment != to->unpack.alignment)
2309 diff_api.PixelStorei(GL_UNPACK_ALIGNMENT, to->unpack.alignment);
2313 if (from->unpack.imageHeight != to->unpack.imageHeight)
2315 diff_api.PixelStorei(GL_UNPACK_IMAGE_HEIGHT, to->unpack.imageHeight);
2319 if (from->unpack.skipImages != to->unpack.skipImages)
2321 diff_api.PixelStorei(GL_UNPACK_SKIP_IMAGES, to->unpack.skipImages);
2325 if (from->unpack.swapBytes != to->unpack.swapBytes)
2327 diff_api.PixelStorei(GL_UNPACK_SWAP_BYTES, to->unpack.swapBytes);
2331 if (from->unpack.psLSBFirst != to->unpack.psLSBFirst)
2333 diff_api.PixelStorei(GL_UNPACK_LSB_FIRST, to->unpack.psLSBFirst);
2342 if (from->pack.rowLength != to->pack.rowLength)
2344 diff_api.PixelStorei(GL_PACK_ROW_LENGTH, to->pack.rowLength);
2348 if (from->pack.skipRows != to->pack.skipRows)
2350 diff_api.PixelStorei(GL_PACK_SKIP_ROWS, to->pack.skipRows);
2354 if (from->pack.skipPixels != to->pack.skipPixels)
2356 diff_api.PixelStorei(GL_PACK_SKIP_PIXELS, to->pack.skipPixels);
2360 if (from->pack.alignment != to->pack.alignment)
2362 diff_api.PixelStorei(GL_PACK_ALIGNMENT, to->pack.alignment);
2366 if (from->pack.imageHeight != to->pack.imageHeight)
2368 diff_api.PixelStorei(GL_PACK_IMAGE_HEIGHT, to->pack.imageHeight);
2372 if (from->pack.skipImages != to->pack.skipImages)
2374 diff_api.PixelStorei(GL_PACK_SKIP_IMAGES, to->pack.skipImages);
2378 if (from->pack.swapBytes != to->pack.swapBytes)
2380 diff_api.PixelStorei(GL_PACK_SWAP_BYTES, to->pack.swapBytes);
2384 if (from->pack.psLSBFirst != to->pack.psLSBFirst)
2386 diff_api.PixelStorei(GL_PACK_LSB_FIRST, to->pack.psLSBFirst);