支持宽高与负面提示词
This commit is contained in:
		@@ -142,6 +142,8 @@ func ImagesPost(w http.ResponseWriter, r *http.Request) {
 | 
			
		||||
				Seed           int    `json:"seed"`            // 随机种子(单张图生成时使用)
 | 
			
		||||
				NIter          int    `json:"n_iter"`          // 生成数量
 | 
			
		||||
				ModelID        int    `json:"model_id"`        // 模型ID
 | 
			
		||||
				Width          int    `json:"width"`           // 图片宽度
 | 
			
		||||
				Height         int    `json:"height"`          // 图片高度
 | 
			
		||||
			}{}
 | 
			
		||||
			body, err := ioutil.ReadAll(r.Body)
 | 
			
		||||
			if err != nil {
 | 
			
		||||
@@ -196,6 +198,9 @@ func ImagesPost(w http.ResponseWriter, r *http.Request) {
 | 
			
		||||
				image.CfgScale = template.CfgScale
 | 
			
		||||
				image.SamplerName = template.SamplerName
 | 
			
		||||
				image.Seed = template.Seed
 | 
			
		||||
				image.ModelID = template.ModelID
 | 
			
		||||
				image.Width = template.Width
 | 
			
		||||
				image.Height = template.Height
 | 
			
		||||
				image_list = append(image_list, image)
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user