SDXFrameWork  0.04
SDXFrameWork
 全て クラス ネームスペース 関数 変数 ページ
Blend.h
1 #pragma once
2 #include<Multimedia/Image.h>
3 
4 namespace SDX
5 {
7 class Blend
11 {
12 public:
14  bool Add( Image* 合成イメージ , const Image *入力イメージ ,double 合成率 = 1.0)
16  {
17  #ifdef DXLIB
18  return !DxLib::GraphBlend(合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_ADD);
19  #elif defined(SDL)
20  return false;
21  #endif
22  }
23 
25  bool Burn( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
30  {
31  #ifdef DXLIB
32  return !DxLib::GraphBlend(合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_BURN);
33  #elif defined(SDL)
34  return false;
35  #endif
36  }
37 
39  bool Darken( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
41  {
42  #ifdef DXLIB
43  return !DxLib::GraphBlend(合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_DARKEN);
44  #elif defined(SDL)
45  return false;
46  #endif
47  }
48 
50  bool Difference( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
52  {
53  #ifdef DXLIB
54  return !DxLib::GraphBlend(合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_DIFFERENCE);
55  #elif defined(SDL)
56  return false;
57  #endif
58  }
59 
61  bool Dodge( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
66  {
67  #ifdef DXLIB
68  return !DxLib::GraphBlend(合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_DODGE);
69  #elif defined(SDL)
70  return false;
71  #endif
72  }
73 
75  bool Exclusion( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
79  {
80  #ifdef DXLIB
81  return !DxLib::GraphBlend(合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_EXCLUSION);
82  #elif defined(SDL)
83  return false;
84  #endif
85  }
86 
88  bool HardLight( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
90  {
91  #ifdef DXLIB
92  return !DxLib::GraphBlend(合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_HARDLIGHT);
93  #elif defined(SDL)
94  return false;
95  #endif
96  }
97 
99  bool Lighten( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
101  {
102  #ifdef DXLIB
103  return !DxLib::GraphBlend( 合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_LIGHTEN);
104  #elif defined(SDL)
105  return false;
106  #endif
107  }
108 
110  bool Multiple( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
114  {
115  #ifdef DXLIB
116  return !DxLib::GraphBlend( 合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_MULTIPLE);
117  #elif defined(SDL)
118  return false;
119  #endif
120  }
121 
123  bool Normal( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
126  {
127  #ifdef DXLIB
128  return !DxLib::GraphBlend( 合成イメージ->GetHandle() , 入力イメージ->GetHandle() , (int)(合成率*255) ,DX_GRAPH_BLEND_NORMAL);
129  #elif defined(SDL)
130  return false;
131  #endif
132  }
133 
135  bool OverLay( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
142  {
143  #ifdef DXLIB
144  return !DxLib::GraphBlend( 合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_OVERLAY);
145  #elif defined(SDL)
146  return false;
147  #endif
148  }
149 
151  bool RgbaSelectMix( Image* 合成イメージ , const Image *入力イメージ, RGBA 赤要素 , RGBA 緑要素 , RGBA 青要素 , RGBA 透明要素 ,double 合成率 = 1.0)
154  {
155  #ifdef DXLIB
156  return !DxLib::GraphBlend( 合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_RGBA_SELECT_MIX, 赤要素 , 緑要素 , 青要素 , 透明要素 );
157  #elif defined(SDL)
158  return false;
159  #endif
160  }
161 
163  bool Screen( Image* 合成イメージ , const Image *入力イメージ,double 合成率 = 1.0)
167  {
168  #ifdef DXLIB
169  return !DxLib::GraphBlend( 合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_SCREEN);
170  #elif defined(SDL)
171  return false;
172  #endif
173  }
174 
176  bool SoftLight( Image* 合成イメージ , const Image *入力イメージ,double 合成率)
183  {
184  #ifdef DXLIB
185  return !DxLib::GraphBlend( 合成イメージ->GetHandle() , 入力イメージ->GetHandle(),int(合成率*255),DX_GRAPH_BLEND_SOFTLIGHT);
186  #elif defined(SDL)
187  return false;
188  #endif
189  }
190 };
191 
193 class BlendBlt
197 {
198 public:
200  static Image Add(const Image *imgA,const Image *imgB,double 合成率)
201  {
202  const int width = std::max( imgA->GetWidth() , imgB->GetWidth() );
203  const int height = std::max( imgA->GetHeight() , imgB->GetHeight() );
204  Image outPut( width , height , true , true , true );
205  #ifdef DXLIB
206  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_ADD);
207  #elif defined(SDL)
208  #endif
209  return outPut;
210  }
211  static Image Add(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
212  {
213  const int width = std::max( imgA->GetWidth() , imgB->GetWidth() );
214  const int height = std::max( imgA->GetHeight() , imgB->GetHeight() );
215  Image outPut( width , height , true , true , true );
216  #ifdef DXLIB
217  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_ADD);
218  #elif defined(SDL)
219  #endif
220  return outPut;
221  }
222 
224  static Image Burn(const Image *imgA,const Image *imgB,double 合成率)
225  {
226  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
227  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
228  Image outPut(width, height, true, true, true);
229  #ifdef DXLIB
230  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_BURN);
231  #elif defined(SDL)
232  #endif
233  return outPut;
234  }
235  static Image Burn(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
236  {
237  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
238  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
239  Image outPut(width, height, true, true, true);
240  #ifdef DXLIB
241  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_BURN);
242  #elif defined(SDL)
243  #endif
244  return outPut;
245  }
246 
248  static Image Darken(const Image *imgA,const Image *imgB,double 合成率)
249  {
250  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
251  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
252  Image outPut(width, height, true, true, true);
253  #ifdef DXLIB
254  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_DARKEN);
255  #elif defined(SDL)
256  #endif
257  return outPut;
258  }
259  static Image Darken(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
260  {
261  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
262  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
263  Image outPut(width, height, true, true, true);
264  #ifdef DXLIB
265  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_DARKEN);
266  #elif defined(SDL)
267  #endif
268  return outPut;
269  }
270 
272  static Image Diference(const Image *imgA,const Image *imgB,double 合成率)
273  {
274  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
275  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
276  Image outPut(width, height, true, true, true);
277  #ifdef DXLIB
278  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_DIFFERENCE);
279  #elif defined(SDL)
280  #endif
281  return outPut;
282  }
283  static Image Difference(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
284  {
285  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
286  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
287  Image outPut(width, height, true, true, true);
288  #ifdef DXLIB
289  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_DIFFERENCE);
290  #elif defined(SDL)
291  #endif
292  return outPut;
293  }
294 
296  static Image Dodge(const Image *imgA,const Image *imgB,double 合成率)
297  {
298  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
299  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
300  Image outPut(width, height, true, true, true);
301  #ifdef DXLIB
302  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_DODGE);
303  #elif defined(SDL)
304  #endif
305  return outPut;
306  }
307  static Image Dodge(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
308  {
309  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
310  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
311  Image outPut(width, height, true, true, true);
312  #ifdef DXLIB
313  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_DODGE);
314  #elif defined(SDL)
315  #endif
316  return outPut;
317  }
318 
320  static Image Exclusion(const Image *imgA,const Image *imgB,double 合成率)
321  {
322  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
323  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
324  Image outPut(width, height, true, true, true);
325  #ifdef DXLIB
326  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_EXCLUSION);
327  #elif defined(SDL)
328  #endif
329  return outPut;
330  }
331  static Image Exclusion(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
332  {
333  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
334  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
335  Image outPut(width, height, true, true, true);
336  #ifdef DXLIB
337  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_EXCLUSION);
338  #elif defined(SDL)
339  #endif
340  return outPut;
341  }
342 
344  static Image HardLight(const Image *imgA,const Image *imgB,double 合成率)
345  {
346  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
347  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
348  Image outPut(width, height, true, true, true);
349  #ifdef DXLIB
350  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_HARDLIGHT);
351  #elif defined(SDL)
352  #endif
353  return outPut;
354  }
355  static Image HardLight(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
356  {
357  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
358  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
359  Image outPut(width, height, true, true, true);
360  #ifdef DXLIB
361  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_HARDLIGHT);
362  #elif defined(SDL)
363  #endif
364  return outPut;
365  }
366 
368  static Image Lighten(const Image *imgA,const Image *imgB,double 合成率)
369  {
370  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
371  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
372  Image outPut(width, height, true, true, true);
373  #ifdef DXLIB
374  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_LIGHTEN);
375  #elif defined(SDL)
376  #endif
377  return outPut;
378  }
379  static Image Lighten(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
380  {
381  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
382  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
383  Image outPut(width, height, true, true, true);
384  #ifdef DXLIB
385  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_LIGHTEN);
386  #elif defined(SDL)
387  #endif
388  return outPut;
389  }
390 
392  static Image Multiple(const Image *imgA,const Image *imgB,double 合成率)
393  {
394  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
395  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
396  Image outPut(width, height, true, true, true);
397  #ifdef DXLIB
398  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_MULTIPLE);
399  #elif defined(SDL)
400  #endif
401  return outPut;
402  }
403  static Image Multiple(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
404  {
405  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
406  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
407  Image outPut(width, height, true, true, true);
408  #ifdef DXLIB
409  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_MULTIPLE);
410  #elif defined(SDL)
411  #endif
412  return outPut;
413  }
414 
416  static Image Normal(const Image *imgA,const Image *imgB,double 合成率)
417  {
418  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
419  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
420  Image outPut(width, height, true, true, true);
421  #ifdef DXLIB
422  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_NORMAL);
423  #elif defined(SDL)
424  #endif
425  return outPut;
426  }
427  static Image Normal(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
428  {
429  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
430  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
431  Image outPut(width, height, true, true, true);
432  #ifdef DXLIB
433  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_NORMAL);
434  #elif defined(SDL)
435  #endif
436  return outPut;
437  }
438 
440  static Image OverLay(const Image *imgA,const Image *imgB,double 合成率)
441  {
442  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
443  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
444  Image outPut(width, height, true, true, true);
445  #ifdef DXLIB
446  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_OVERLAY);
447  #elif defined(SDL)
448  #endif
449  return outPut;
450  }
451  static Image OverLay(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
452  {
453  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
454  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
455  Image outPut(width, height, true, true, true);
456  #ifdef DXLIB
457  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_OVERLAY);
458  #elif defined(SDL)
459  #endif
460  return outPut;
461  }
462 
464  static Image RgbaSelectMix(const Image *imgA,const Image *imgB,double 合成率, RGBA selectR , RGBA selectG , RGBA selectB , RGBA selectA)
465  {
466  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
467  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
468  Image outPut(width, height, true, true, true);
469  #ifdef DXLIB
470  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_RGBA_SELECT_MIX, selectR , selectG , selectB , selectA );
471  #elif defined(SDL)
472  #endif
473  return outPut;
474  }
475  static Image RgbaSelect(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率, RGBA selectR , RGBA selectG , RGBA selectB , RGBA selectA)
476  {
477  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
478  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
479  Image outPut(width, height, true, true, true);
480  #ifdef DXLIB
481  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_RGBA_SELECT_MIX, selectR , selectG , selectB , selectA );
482  #elif defined(SDL)
483  #endif
484  return outPut;
485  }
486 
488  static Image Screen(const Image *imgA,const Image *imgB,double 合成率)
489  {
490  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
491  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
492  Image outPut(width, height, true, true, true);
493  #ifdef DXLIB
494  DxLib::GraphBlendBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_SCREEN);
495  #elif defined(SDL)
496  #endif
497  return outPut;
498  }
499  static Image Screen(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
500  {
501  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
502  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
503  Image outPut(width, height, true, true, true);
504  #ifdef DXLIB
505  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_SCREEN);
506  #elif defined(SDL)
507  #endif
508  return outPut;
509  }
510 
512  static Image SoftLight(const Image *imgA,const Image *imgB,double 合成率)
513  {
514  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
515  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
516  Image outPut(width, height, true, true, true);
517  #ifdef DXLIB
518  DxLib::GraphBlend(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle(),int(合成率*255),DX_GRAPH_BLEND_SOFTLIGHT);
519  #elif defined(SDL)
520  #endif
521  return outPut;
522  }
523  static Image SoftLight(const Image *imgA,const Image *imgB, int srcX1, int srcY1, int srcX2, int srcY2, int blendX, int blendY, int destX, int destY,double 合成率)
524  {
525  const int width = std::max(imgA->GetWidth(), imgB->GetWidth());
526  const int height = std::max(imgA->GetHeight(), imgB->GetHeight());
527  Image outPut(width, height, true, true, true);
528  #ifdef DXLIB
529  DxLib::GraphBlendRectBlt(imgA->GetHandle() , imgB->GetHandle() , outPut.GetHandle() , srcX1, srcY1, srcX2, srcY2, blendX, blendY, destX, destY,int(合成率*255),DX_GRAPH_BLEND_SOFTLIGHT);
530  #elif defined(SDL)
531  #endif
532  return outPut;
533  }
534 };
535 
536 
537 
538 }
static Image Screen(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:488
bool Add(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
加算合成.
Definition: Blend.h:15
static Image Burn(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:224
static Image Darken(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:248
bool OverLay(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
オーバーレイ合成.
Definition: Blend.h:141
bool Normal(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
通常合成.
Definition: Blend.h:125
bool RgbaSelectMix(Image *合成イメージ, const Image *入力イメージ, RGBA 赤要素, RGBA 緑要素, RGBA 青要素, RGBA 透明要素, double 合成率=1.0)
RGBAの要素を選択して合成.
Definition: Blend.h:153
ImageHandle GetHandle() const
ハンドルを取得.
Definition: Image.h:189
static Image Exclusion(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:320
bool Difference(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
減算合成.
Definition: Blend.h:51
static Image Normal(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:416
static Image SoftLight(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:512
bool Screen(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
スクリーン合成.
Definition: Blend.h:166
static Image OverLay(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:440
bool SoftLight(Image *合成イメージ, const Image *入力イメージ, double 合成率)
ソフトライト合成.
Definition: Blend.h:182
static Image Add(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:200
画像データを表すクラス.
Definition: Image.h:37
bool Burn(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
焼き込み合成.
Definition: Blend.h:29
bool Lighten(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
比較合成(明).
Definition: Blend.h:100
int GetHeight() const
高さを取得.
Definition: Image.h:385
int GetWidth() const
幅を取得.
Definition: Image.h:375
bool Multiple(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
乗算合成.
Definition: Blend.h:113
static Image Dodge(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:296
bool Dodge(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
覆い焼き合成.
Definition: Blend.h:65
bool Darken(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
比較合成(暗).
Definition: Blend.h:40
bool HardLight(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
ハードライト合成.
Definition: Blend.h:89
static Image RgbaSelectMix(const Image *imgA, const Image *imgB, double 合成率, RGBA selectR, RGBA selectG, RGBA selectB, RGBA selectA)
説明.
Definition: Blend.h:464
static Image Lighten(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:368
static Image Diference(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:272
static Image HardLight(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:344
static Image Multiple(const Image *imgA, const Image *imgB, double 合成率)
説明.
Definition: Blend.h:392
bool Exclusion(Image *合成イメージ, const Image *入力イメージ, double 合成率=1.0)
除外合成.
Definition: Blend.h:78