Add InitializeMagick to native image code
This commit is contained in:
		
							parent
							
								
									c0dbb2f733
								
							
						
					
					
						commit
						1e1a24b003
					
				
					 1 changed files with 7 additions and 0 deletions
				
			
		| 
						 | 
					@ -40,8 +40,15 @@
 | 
				
			||||||
#include "whisper.h"
 | 
					#include "whisper.h"
 | 
				
			||||||
#include "zamn.h"
 | 
					#include "zamn.h"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#ifdef _WIN32
 | 
				
			||||||
 | 
					#include <Magick++.h>
 | 
				
			||||||
 | 
					#endif
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Napi::Object Init(Napi::Env env, Napi::Object exports)
 | 
					Napi::Object Init(Napi::Env env, Napi::Object exports)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
 | 
					#ifdef _WIN32
 | 
				
			||||||
 | 
					  Magick::InitializeMagick("");
 | 
				
			||||||
 | 
					#endif
 | 
				
			||||||
  exports.Set(Napi::String::New(env, "blur"), Napi::Function::New(env, Blur));
 | 
					  exports.Set(Napi::String::New(env, "blur"), Napi::Function::New(env, Blur));
 | 
				
			||||||
  exports.Set(Napi::String::New(env, "colors"), Napi::Function::New(env, Colors));
 | 
					  exports.Set(Napi::String::New(env, "colors"), Napi::Function::New(env, Colors));
 | 
				
			||||||
  exports.Set(Napi::String::New(env, "caption"), Napi::Function::New(env, Caption));
 | 
					  exports.Set(Napi::String::New(env, "caption"), Napi::Function::New(env, Caption));
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue