MCPcopy Create free account
hub / github.com/RenderKit/embree / renderTileStandard

Function renderTileStandard

tutorials/user_geometry/user_geometry_device.cpp:830–851  ·  view source on GitHub ↗

renders a single screen tile */

Source from the content-addressed store, hash-verified

828
829/* renders a single screen tile */
830void renderTileStandard(int taskIndex,
831 int threadIndex,
832 int* pixels,
833 const unsigned int width,
834 const unsigned int height,
835 const float time,
836 const ISPCCamera& camera,
837 const int numTilesX,
838 const int numTilesY)
839{
840 const unsigned int tileY = taskIndex / numTilesX;
841 const unsigned int tileX = taskIndex - tileY * numTilesX;
842 const unsigned int x0 = tileX * TILE_SIZE_X;
843 const unsigned int x1 = min(x0+TILE_SIZE_X,width);
844 const unsigned int y0 = tileY * TILE_SIZE_Y;
845 const unsigned int y1 = min(y0+TILE_SIZE_Y,height);
846
847 for (unsigned int y=y0; y<y1; y++) for (unsigned int x=x0; x<x1; x++)
848 {
849 renderPixelStandard(data,x,y,pixels,width,height,time,camera,g_stats[threadIndex]);
850 }
851}
852
853/* task that renders a single screen tile */
854void renderTileTask (int taskIndex, int threadIndex, int* pixels,

Callers 1

renderTileTaskFunction · 0.70

Calls 2

renderPixelStandardFunction · 0.70
minFunction · 0.50

Tested by

no test coverage detected