mirror of
				https://github.com/scottdraves/flam3.git
				synced 2025-11-03 18:00:41 -05:00 
			
		
		
		
	CMAP_SIZE can be used when creating the dmap - I had erroneously thought that cmap_size was necessary (the apo-corrected number of elements in the palette)
git-svn-id: https://flam3.googlecode.com/svn/trunk@153 77852712-ef1d-11de-8684-7d64432d61a3
This commit is contained in:
		
				
					committed by
					
						
						Scott Draves
					
				
			
			
				
	
			
			
			
						parent
						
							6be5e2e3f2
						
					
				
				
					commit
					6cfbf0cbb1
				
			@ -776,10 +776,10 @@ static int render_rectangle(flam3_frame *spec, void *out,
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
         /* compute the colormap entries.                             */
 | 
					         /* compute the colormap entries.                             */
 | 
				
			||||||
         /* the input colormap is 256 long with entries from 0 to 1.0 */
 | 
					         /* the input colormap is 256 long with entries from 0 to 1.0 */
 | 
				
			||||||
         for (j = 0; j < cmap_size; j++) {
 | 
					         for (j = 0; j < CMAP_SIZE; j++) {
 | 
				
			||||||
            dmap[j].index = cp.palette[(j * 256) / cmap_size].index / 256.0;
 | 
					            dmap[j].index = cp.palette[(j * 256) / CMAP_SIZE].index / 256.0;
 | 
				
			||||||
            for (k = 0; k < 4; k++)
 | 
					            for (k = 0; k < 4; k++)
 | 
				
			||||||
               dmap[j].color[k] = (cp.palette[(j * 256) / cmap_size].color[k] * WHITE_LEVEL) * color_scalar;
 | 
					               dmap[j].color[k] = (cp.palette[(j * 256) / CMAP_SIZE].color[k] * WHITE_LEVEL) * color_scalar;
 | 
				
			||||||
         }
 | 
					         }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
         /* compute camera */
 | 
					         /* compute camera */
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user