VirtualBox

Ignore:
Timestamp:
Jul 7, 2009 10:49:52 AM (16 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
49651
Message:

crOpenGL: use host side VBO when possible

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/common/crOpenGL/array/arrayspu.c

    r20970 r21308  
    478478    }
    479479#endif
     480    //crDebug("arrayspu_DrawElements mode:0x%x, count:%d, type:0x%x", mode, count, type);
     481   
    480482
    481483    array_spu.self.Begin(mode);
     
    521523static void ARRAYSPU_APIENTRY arrayspu_ColorPointer( GLint size, GLenum type, GLsizei stride, const GLvoid *pointer )
    522524{
    523     crStateColorPointer( size, type, stride, pointer );
     525    crStateColorPointer(size, type, stride, pointer);
     526    array_spu.child.ColorPointer(size, type, stride, pointer);
    524527}
    525528
    526529static void ARRAYSPU_APIENTRY arrayspu_SecondaryColorPointerEXT( GLint size, GLenum type, GLsizei stride, const GLvoid *pointer )
    527530{
    528     crStateSecondaryColorPointerEXT( size, type, stride, pointer );
     531    crStateSecondaryColorPointerEXT(size, type, stride, pointer);
     532    array_spu.child.SecondaryColorPointerEXT(size, type, stride, pointer);
    529533}
    530534
    531535static void ARRAYSPU_APIENTRY arrayspu_VertexPointer( GLint size, GLenum type, GLsizei stride, const GLvoid *pointer )
    532536{
    533     crStateVertexPointer( size, type, stride, pointer );
     537    crStateVertexPointer(size, type, stride, pointer);
     538    array_spu.child.VertexPointer(size, type, stride, pointer);
    534539}
    535540
    536541static void ARRAYSPU_APIENTRY arrayspu_TexCoordPointer( GLint size, GLenum type, GLsizei stride, const GLvoid *pointer )
    537542{
    538     crStateTexCoordPointer( size, type, stride, pointer );
     543    crStateTexCoordPointer(size, type, stride, pointer);
     544    array_spu.child.TexCoordPointer(size, type, stride, pointer);
    539545}
    540546
    541547static void ARRAYSPU_APIENTRY arrayspu_NormalPointer( GLenum type, GLsizei stride, const GLvoid *pointer )
    542548{
    543     crStateNormalPointer( type, stride, pointer );
     549    crStateNormalPointer(type, stride, pointer);
     550    array_spu.child.NormalPointer(type, stride, pointer);
    544551}
    545552
    546553static void ARRAYSPU_APIENTRY arrayspu_IndexPointer( GLenum type, GLsizei stride, const GLvoid *pointer )
    547554{
    548     crStateIndexPointer( type, stride, pointer );
     555    crStateIndexPointer(type, stride, pointer);
     556    array_spu.child.IndexPointer(type, stride, pointer);
    549557}
    550558
    551559static void ARRAYSPU_APIENTRY arrayspu_EdgeFlagPointer( GLsizei stride, const GLvoid *pointer )
    552560{
    553     crStateEdgeFlagPointer( stride, pointer );
     561    crStateEdgeFlagPointer(stride, pointer);
     562    array_spu.child.EdgeFlagPointer(stride, pointer);
    554563}
    555564
    556565static void ARRAYSPU_APIENTRY arrayspu_VertexAttribPointerNV( GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid * pointer )
    557566{
    558     crStateVertexAttribPointerNV( index, size, type, stride, pointer );
     567    crStateVertexAttribPointerNV(index, size, type, stride, pointer);
     568    array_spu.child.VertexAttribPointerNV(index, size, type, stride, pointer);
    559569}
    560570
    561571static void ARRAYSPU_APIENTRY arrayspu_FogCoordPointerEXT( GLenum type, GLsizei stride, const GLvoid *pointer )
    562572{
    563     crStateFogCoordPointerEXT( type, stride, pointer );
     573    crStateFogCoordPointerEXT(type, stride, pointer);
     574    array_spu.child.FogCoordPointerEXT(type, stride, pointer);
    564575}
    565576
    566577static void ARRAYSPU_APIENTRY arrayspu_GetPointerv( GLenum pname, GLvoid **params )
    567578{
    568     crStateGetPointerv( pname, params );
     579    crStateGetPointerv(pname, params);
    569580}
    570581
    571582static void ARRAYSPU_APIENTRY arrayspu_EnableClientState( GLenum array )
    572583{
    573     crStateEnableClientState( array );
     584    crStateEnableClientState(array);
     585    array_spu.child.EnableClientState(array);
    574586}
    575587
    576588static void ARRAYSPU_APIENTRY arrayspu_DisableClientState( GLenum array )
    577589{
    578     crStateDisableClientState( array );
     590    crStateDisableClientState(array);
     591    array_spu.child.DisableClientState(array);
    579592}
    580593
    581594static void ARRAYSPU_APIENTRY arrayspu_ClientActiveTextureARB( GLenum texture )
    582595{
    583     crStateClientActiveTextureARB( texture );
     596    crStateClientActiveTextureARB(texture);
     597    array_spu.child.ClientActiveTextureARB(texture);
    584598}
    585599
     
    662676                                const GLvoid *pointer)
    663677{
    664     crStateVertexAttribPointerARB( index, size, type, normalized, stride, pointer );
     678    crStateVertexAttribPointerARB(index, size, type, normalized, stride, pointer);
     679    array_spu.child.VertexAttribPointerARB(index, size, type, normalized, stride, pointer);
    665680}
    666681
     
    703718arrayspu_GenBuffersARB( GLsizei n, GLuint * buffers )
    704719{
    705     crStateGenBuffersARB(n, buffers);
     720    array_spu.child.GenBuffersARB(n, buffers);
    706721}
    707722
     
    710725{
    711726    crStateDeleteBuffersARB(n, buffers);
     727    array_spu.child.DeleteBuffersARB(n, buffers);
    712728}
    713729
     
    716732{
    717733    crStateBindBufferARB(target, buffer);
     734    array_spu.child.BindBufferARB(target, buffer);
    718735}
    719736
     
    721738arrayspu_IsBufferARB (GLuint buffer)
    722739{
    723     return crStateIsBufferARB(buffer);
     740    return array_spu.child.IsBufferARB(buffer);
    724741}
    725742
     
    728745{
    729746    crStateBufferDataARB(target, size, data, usage);
     747    array_spu.child.BufferDataARB(target, size, data, usage);
    730748}
    731749
     
    735753{
    736754    crStateBufferSubDataARB(target, offset, size, data);
     755    array_spu.child.BufferSubDataARB(target, offset, size, data);
    737756}
    738757
     
    752771arrayspu_UnmapBufferARB(GLenum target)
    753772{
    754     return crStateUnmapBufferARB(target);
     773    crStateUnmapBufferARB(target);
     774    return array_spu.child.UnmapBufferARB(target);
    755775}
    756776
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette