Venkatesh Ram

Greenhorn
+ Follow
since Mar 08, 2007
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Venkatesh Ram

Hi,

Iam using jmagick for resizing and cropping the image.When iam running from the command prompt its working fine and giving the exact result what i need.But when iam running from the eclipse it is showing as


#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c93426d, pid=3440, tid=3216
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_08-b03 mixed mode, sharing)
# Problematic frame:
# C [ntdll.dll+0x3426d]
#
# An error report file with more information is saved as hs_err_pid3440.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#

[error occurred during error reporting, step 270, id 0xc0000005]



I have included the jmagick.jar file in the build path.Even though it is giving the error.Could anybody solve this.Thanks in advance.

Regards,
Venkatesh.R
16 years ago
Hi,

I have tried to write text on the image using Jmagick.The code i have done is below.It is copiling but while executing it shows the eroor message as

#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c9111de, pid=3160, tid=1360
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_08-b03 mixed mode, sharing)
# Problematic frame:
# C [ntdll.dll+0x111de]
#
# An error report file with more information is saved as hs_err_pid3160.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#

[error occurred during error reporting, step 270, id 0xc0000005]




and the code is:





import java.io.*;
import java.awt.*;
import magick.*;

class InsertText
{
public static void main(String a[]) throws IOException,MagickException
{
ImageInfo info=new ImageInfo("tigerShereKhanOnLog1.jpg");
MagickImage image=new MagickImage(info);
DrawInfo aInfo = new DrawInfo(info);
aInfo.setFill(PixelPacket.queryColorDatabase("yellow"));
aInfo.setUnderColor(PixelPacket.queryColorDatabase("yellow"));

aInfo.setOpacity(0);
aInfo.setPointsize(36);
aInfo.setFont("Arial");

aInfo.setGeometry("+40+40");
aInfo.setText("JMagick Tutorial");

image.annotateImage(aInfo);
image.setFileName("text.jpg");
image.writeImage(info);
}}



Could anybody solve and tell me how to do that.Thanks in advance
17 years ago
Iam new to jmagick and i tried with sample code.the code got compiled and while executing it is giving this error.i have installed ImageMagick-6.3.3-Q8 and using copied jmagic.dll to the Imagemagick directory
This is the error:

ImageMagick: UnableToAcquireString `<?xml version="1.0" encoding="UTF
<!DOCTYPE localemap [
<!ELEMENT localemap (include+)>
<!ELEMENT include (#PCDATA)>
<!ATTLIST include locale CDATA #REQUIRED>
<!ATTLIST include file CDATA #REQUIRED>
]>
<localemap>
<include locale="no_NO.ISO-8859-1" file="bokmal.xml" />
<include locale="ca_ES.ISO-8859-1" file="catalan.xml" />
<include locale="hr_HR.ISO-8859-2" file="croatian.xml" />
<include locale="cs_CZ.ISO-8859-2" file="czech.xml" />
<include locale="da_DK.ISO-8859-1" file="danish.xml" />
<include locale="de_DE.ISO-8859-1" file="deutsch.xml" />
<include locale="nl_NL.ISO-8859-1" file="dutch.xml" />
<include locale="C" file="english.xml" />
<include locale="et_EE.ISO-8859-1" file="estonian.xml" />
<include locale="fi_FI.ISO-8859-1" file="finnish.xml" />
<include locale="fr_FR.ISO-8859-1" file="francais.xml" />
<include locale="fr_FR.ISO-8859-1" file="french.xml" />
<include locale="gl_ES.ISO-8859-1" file="galego.xml" />
<include locale="gl_ES.ISO-8859-1" file="galician.xml" />
<include locale="de_DE.ISO-8859-1" file="german.xml" />
<include locale="el_GR.ISO-8859-7" file="greek.xml" />
<include locale="en_US.UTF-8" file="english.xml" />
<include locale="iw_IL.ISO-8859-8" file="hebrew.xml" />
<include locale="hr_HR.ISO-8859-2" file="hrvatski.xml" />
<include locale="hu_HU.ISO-8859-2" file="hungarian.xml" />
<include locale="is_IS.ISO-8859-1" file="icelandic.xml" />
<include locale="it_IT.ISO-8859-1" file="italian.xml" />
<include locale="ja_JP.eucJP" file="japanese.xml" />
<include locale="ko_KR.eucKR" file="korean.xml" />
<include locale="lt_LT.ISO-8859-13" file="lithuanian.xml" />
<include locale="no_NO.ISO-8859-1" file="norwegian.xml" />
<include locale="nn_NO.ISO-8859-1" file="nynorsk.xml" />
<include locale="pl_PL.ISO-8859-2" file="polish.xml" />
<include locale="pt_PT.ISO-8859-1" file="portuguese.xml" />
<include locale="ro_RO.ISO-8859-2" file="romanian.xml" />
<include locale="ru_RU.ISO-8859-5" file="russian.xml" />
<include locale="sk_SK.ISO-8859-2" file="slovak.xml" />
<include locale="sl_SI.ISO-8859-2" file="slovene.xml" />
<include locale="es_ES.ISO-8859-1" file="spanish.xml" />
<include locale="sv_SE.ISO-8859-1" file="swedish.xml" />
<include locale="th_TH.TIS-620" file="thai.xml" />
<include locale="tr_TR.ISO-8859-9" file="turkish.xml" />
</localemap>
'.


and my code is:

import java.lang.*;
import magick.*;
import java.util.*;
class JmagickTest
{
public static void main(String a[]) throws MagickException
{
ImageInfo info = new ImageInfo("tigerShereKhanOnLog.jpeg");
MagickImage image = new MagickImage(info);
System.out.println("image loaded");
image.setFileName("MyFile.jpeg");
image.writeImage(info);
}}


Thanks in advance.
17 years ago
i have copied under imagemagick directory i.e D:\venkat\tut\ImageMagick-windows\ImageMagick-6.3.3.Could you please help me.
17 years ago
I have installed jmagic and copied jmagic.dll in ImageMagic directory.Then i copied jmagic.jar to lib directory of jdk i.e C:\Program Files\Java\jdk1.5.0_08\lib. itied one program.It compiled but showing run time exception as

Exception in thread "main" java.lang.UnsatisfiedLinkError: no JMagick in java.library.path
at java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.lang.Runtime.loadLibrary0(Unknown Source)
at java.lang.System.loadLibrary(Unknown Source)
at magick.MagickLoader.<clinit>(MagickLoader.java:13)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method

at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown So
rce)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at magick.Magick.<clinit>(Magick.java:21)
at JmagickTest.main(JmagickTest.java:8)


i posted my code for your reference I will be very thankful if anybody could solve my problem

my code

import java.lang.*;
import magick.*;
import java.util.*;
class JmagickTest
{
public static void main(String a[]) throws MagickException
{
ImageInfo info = new ImageInfo("tigerShereKhanOnLog.jpeg");
MagickImage image = new MagickImage(info);
image.setFileName("MyFile.jpeg");
image.writeImage(info);
}}

Thanks in advance
17 years ago
Hi,

Iam new to jmagick.Do anybody know how to install jmagick in windows.What are the packages needed for that.Thanks in advance.
17 years ago
Iam using MySql and while using eclipse and tried to load driver with the statement,

Class.forName("com.mysql.jdbc.Driver").newInstance();
iam getting the exception
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver

i transferred my code to Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
but again iam getting exception as
caughtjava.lang.ClassNotFoundException: com.mysql.jdbc.Driver

When i use the second code in notepad it is working.Could anybody help me.

Thanks in advance