13ff0fe77fdba8ad4a920dc27157d8c1786bb3661Jason Sams#ifndef __LP64__ 23ff0fe77fdba8ad4a920dc27157d8c1786bb3661Jason Sams 35a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines#include "rs_core.rsh" 45a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines#include "rs_graphics.rsh" 55a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines#include "rs_structs.h" 65a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 75a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines/** 85a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines* Program Store 95a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines*/ 105a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern rs_depth_func __attribute__((overloadable)) 115a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreGetDepthFunc(rs_program_store ps) { 125a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 135a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 145a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return RS_DEPTH_FUNC_INVALID; 155a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 165a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.depthFunc; 175a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 185a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 195a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern bool __attribute__((overloadable)) 205a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreIsDepthMaskEnabled(rs_program_store ps) { 215a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 225a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 235a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return false; 245a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 255a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.depthWriteEnable; 265a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 275a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 285a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern bool __attribute__((overloadable)) 295a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreIsColorMaskRedEnabled(rs_program_store ps) { 305a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 315a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 325a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return false; 335a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 345a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.colorRWriteEnable; 355a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 365a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 375a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern bool __attribute__((overloadable)) 385a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreIsColorMaskGreenEnabled(rs_program_store ps) { 395a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 405a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 415a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return false; 425a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 435a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.colorGWriteEnable; 445a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 455a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 465a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern bool __attribute__((overloadable)) 475a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreIsColorMaskBlueEnabled(rs_program_store ps) { 485a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 495a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 505a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return false; 515a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 525a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.colorBWriteEnable; 535a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 545a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 555a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern bool __attribute__((overloadable)) 565a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreIsColorMaskAlphaEnabled(rs_program_store ps) { 575a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 585a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 595a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return false; 605a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 615a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.colorAWriteEnable; 625a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 635a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 645a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern rs_blend_src_func __attribute__((overloadable)) 655a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreGetBlendSrcFunc(rs_program_store ps) { 665a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 675a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 685a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return RS_BLEND_SRC_INVALID; 695a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 705a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.blendSrc; 715a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 725a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 735a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern rs_blend_dst_func __attribute__((overloadable)) 745a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreGetBlendDstFunc(rs_program_store ps) { 755a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 765a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 775a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return RS_BLEND_DST_INVALID; 785a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 795a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.blendDst; 805a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 815a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 825a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern bool __attribute__((overloadable)) 835a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramStoreIsDitherEnabled(rs_program_store ps) { 845a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramStore_t *prog = (ProgramStore_t *)ps.p; 855a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 865a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return false; 875a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 885a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.ditherEnable; 895a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 905a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 915a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines/** 925a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines* Program Raster 935a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines*/ 945a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern bool __attribute__((overloadable)) 955a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramRasterIsPointSpriteEnabled(rs_program_raster pr) { 965a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramRaster_t *prog = (ProgramRaster_t *)pr.p; 975a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 985a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return false; 995a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 1005a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.pointSprite; 1015a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 1025a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines 1035a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hinesextern rs_cull_mode __attribute__((overloadable)) 1045a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines rsgProgramRasterGetCullMode(rs_program_raster pr) { 1055a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines ProgramRaster_t *prog = (ProgramRaster_t *)pr.p; 1065a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines if (prog == NULL) { 1075a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return RS_CULL_INVALID; 1085a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines } 1095a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines return prog->mHal.state.cull; 1105a47020542c52af3e879c1cd67674ca979ff0a18Stephen Hines} 1113ff0fe77fdba8ad4a920dc27157d8c1786bb3661Jason Sams 1123ff0fe77fdba8ad4a920dc27157d8c1786bb3661Jason Sams#endif 113