I'm beginning to port my game over to XNA from a C/OpenGL codebase. I'm just now getting to the rendering code, and I'm wondering what the best methods would be for transitioning from a system where you simply bind a texture with one call, then output vertex buffers objects to an XNA equivalent set of methods? I can see how you pass vertex data, but I'm not exactly sure how you bind a texture. Must it all be done in shaders, or is there a simple procedure for this in XNA?
My main rendering code for models is as follows (I apologize for small variable names)
glEnable(GL_TEXTURE_2D);
glEnable(GL_CULL_FACE);
glBindTexture(GL_TEXTURE_2D, obj->tx);
glColor4f(c.r, c.g, c.b, c.a);
glBindBuffer(GL_ARRAY_BUFFER, obj->iVBO);
glVertexPointer(3, GL_FLOAT, (sizeof(float) * 3) + (sizeof(float) * 2), 0);
glTexCoordPointer(2, GL_FLOAT, (sizeof(float) * 3) + (sizeof(float) * 2), (const GLvoid*)(4 * 3));
glDrawArrays(GL_TRIANGLES, 0, obj->iSize);
glBindBuffer(GL_ARRAY_BUFFER, 0);