| 
									
										
										
										
											2023-11-10 14:48:23 +10:00
										 |  |  | [require] | 
					
						
							|  |  |  | shader model >= 5.0 | 
					
						
							| 
									
										
										
										
											2023-12-13 00:27:41 +10:00
										 |  |  | float64 | 
					
						
							| 
									
										
										
										
											2023-11-10 14:48:23 +10:00
										 |  |  | 
 | 
					
						
							|  |  |  | [pixel shader todo] | 
					
						
							|  |  |  | uniform double2 d; | 
					
						
							|  |  |  | uniform float2 f; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | float4 main() : sv_target | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     double2 n = d / f; | 
					
						
							|  |  |  |     return float4(d.x, d.y, n.x, n.y); | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [test] | 
					
						
							|  |  |  | uniform 0 double2 -4.5 8.5 | 
					
						
							|  |  |  | uniform 4 float4 -2.25 4.25 0.0 0.0 | 
					
						
							|  |  |  | todo(sm<6) draw quad | 
					
						
							|  |  |  | probe all rgba (-4.5, 8.5, 2.0, 2.0) | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-01-23 13:47:01 +10:00
										 |  |  | [pixel shader todo] | 
					
						
							|  |  |  | uniform double2 d; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | uint4 main() : sv_target | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     uint4 result; | 
					
						
							|  |  |  |     asuint(d.x, result.x, result.y); | 
					
						
							|  |  |  |     asuint(d.y, result.z, result.w); | 
					
						
							|  |  |  |     return result; | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [test] | 
					
						
							|  |  |  | uniform 0 double2 -4.5 8.500003814697266 | 
					
						
							| 
									
										
										
										
											2024-01-24 14:03:30 +10:00
										 |  |  | todo(sm<6) draw quad | 
					
						
							| 
									
										
										
										
											2024-01-23 13:47:01 +10:00
										 |  |  | probe all rgbaui (0, 0xc0120000, 0x80000000, 0x40210000) | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-03-19 00:21:27 +10:00
										 |  |  | [pixel shader todo] | 
					
						
							|  |  |  | uniform uint4 u; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | float4 main() : sv_target | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     // Low bits, high bits | 
					
						
							|  |  |  |     double2 d = asdouble(u.xz, u.yw); | 
					
						
							|  |  |  |     return float4(d, 0, 0); | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [test] | 
					
						
							|  |  |  | uniform 0 uint4 0xc000000 0x40020000 0x80000000 0xc04be000 | 
					
						
							| 
									
										
										
										
											2024-03-19 00:22:51 +10:00
										 |  |  | todo(sm<6) draw quad | 
					
						
							| 
									
										
										
										
											2024-03-19 00:21:27 +10:00
										 |  |  | probe all rgba (2.25, -55.75001526, 0.0, 0.0) 1 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [pixel shader todo] | 
					
						
							|  |  |  | uniform uint2 u; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | float4 main() : sv_target | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     double d = asdouble(u.x, u.y); | 
					
						
							|  |  |  |     return float4(d, 0, 0, 0); | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [test] | 
					
						
							|  |  |  | uniform 0 uint4 0x80000000 0xc04be000 0 0 | 
					
						
							| 
									
										
										
										
											2024-03-19 00:22:51 +10:00
										 |  |  | todo(sm<6) draw quad | 
					
						
							| 
									
										
										
										
											2024-03-19 00:21:27 +10:00
										 |  |  | probe all rgba (-55.75001526, 0.0, 0.0, 0.0) 1 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-11-10 14:48:23 +10:00
										 |  |  | [require] | 
					
						
							|  |  |  | shader model >= 6.0 | 
					
						
							| 
									
										
										
										
											2023-11-23 13:17:54 +10:00
										 |  |  | int64 | 
					
						
							| 
									
										
										
										
											2023-11-10 14:48:23 +10:00
										 |  |  | 
 | 
					
						
							|  |  |  | [pixel shader] | 
					
						
							|  |  |  | uniform uint64_t2 l; | 
					
						
							|  |  |  | uniform uint2 u; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | float4 main() : sv_target | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     uint64_t2 n = l / u; | 
					
						
							|  |  |  |     uint4 result = uint4(l.x, l.y, n.x, n.y); | 
					
						
							|  |  |  |     return result; | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [test] | 
					
						
							|  |  |  | uniform 0 uint64_t2 0x500000001 0x100000002 | 
					
						
							|  |  |  | uniform 4 uint4 10 4 0 0 | 
					
						
							| 
									
										
										
										
											2023-11-22 00:38:19 +10:00
										 |  |  | draw quad | 
					
						
							|  |  |  | probe all rgba (1.0, 2.0, 2147483648.0, 1073741824.0) | 
					
						
							| 
									
										
										
										
											2023-11-10 14:48:23 +10:00
										 |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [pixel shader] | 
					
						
							|  |  |  | uniform int64_t2 l; | 
					
						
							|  |  |  | uniform int2 i; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | float4 main() : sv_target | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     int64_t2 n = l / i; | 
					
						
							|  |  |  |     int4 result = int4(l.x, l.y, n.x, n.y); | 
					
						
							|  |  |  |     return result; | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | [test] | 
					
						
							|  |  |  | uniform 0 int64_t2 -21474836481 0x100000002 | 
					
						
							|  |  |  | uniform 4 int4 -20 8 0 0 | 
					
						
							| 
									
										
										
										
											2023-11-22 00:38:19 +10:00
										 |  |  | draw quad | 
					
						
							|  |  |  | probe all rgba (-1.0, 2.0, 1073741824.0, 536870912.0) |