Bake-API: throws error if highpoly object(s) doesn't have uniform scale (fix T40156)
The real fix would be to support non-uniform scaled highpoly objects.
For more information see 8d29739
			
			
This commit is contained in:
		@@ -508,13 +508,19 @@ static int bake(
 | 
			
		||||
			if (ob_iter == ob_low)
 | 
			
		||||
				continue;
 | 
			
		||||
 | 
			
		||||
			if (ob_iter->size[0] != ob_iter->size[1] || ob_iter->size[1] != ob_iter->size[2]) {
 | 
			
		||||
				BKE_reportf(reports, RPT_ERROR,
 | 
			
		||||
				            "Selected objects need to have uniform scale. Apply Scale to object \"%s\"",
 | 
			
		||||
				            ob_iter->id.name + 2);
 | 
			
		||||
				goto cleanup;
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
			tot_highpoly ++;
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		if (tot_highpoly == 0) {
 | 
			
		||||
			BKE_report(reports, RPT_ERROR, "No valid selected objects");
 | 
			
		||||
			op_result = OPERATOR_CANCELLED;
 | 
			
		||||
 | 
			
		||||
			goto cleanup;
 | 
			
		||||
		}
 | 
			
		||||
		else {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user