Delphi 7 Jpg Error 53
Contents |
0; IdHTTP1.Get(Image_Str, JPG_Data); JPG_Data.Position := 0; fcImager1.Picture.Graphic.LoadFromStream(JPG_Data); fcImager1.Visible := true; finally Jack Maso
Delphi Jpeg Error 53
Delphi Developer Fri, 15 Jan 2010 12:01:44 GMT Re:JPEG Error #53 We are using abstract error delphi 7 the following code to display JPEG images from Amazon. Most work fine, but occasionally we find one that causes a jpeg error 53 fix JPEG error #53 from Delphi. Here is the link to one that causes the error: http://ec1.images-amazon.com/images/I/71RS7HFJ5EL.gif Is this something we can control or check for before displaying the image? It does display correctly in the browsers. Rob Kenned Delphi Developer Fri, 15 Jan 2010 12:30:53 GMT Re:JPEG Error #53 QuoteJack Mason wrote: > We are using the following code to display JPEG images from Amazon. Most > work fine, but occasionally we find one that causes a JPEG error #53 > from Delphi. Here is the link to one that causes the error: > http://ec1.images-amazon.com/images/I/71RS7HFJ5EL.gif > Is this something we can control or check for before displaying the > image? It does display correctly in the browsers. That's because browsers know how to display both JPEGs _and_ GIFs. TJpegImage doesn't. -- Rob Eddie Shipma Delphi Developer Fri, 15 Jan 2010 21:33:52 GMT Re:JPEG Error #53 Get the GraphicEx library from Mike Lischke's site: http://www.lischke-online.de It will handle both GIF and JPEG. Jack Maso Delphi Developer Fri, 15 Jan 2010 22:33:03 GMT Re:JPEG Error #53 Eddie, Thank you very much! Jack Maso Delphi Developer Sat, 16 Jan 2010 00:04:01 GMT Re:JPEG Error #53 Quote> That's because browsers know how to display both JPEGs _and_ GIFs. > TJpegImage doesn't. We have not specified TJpegImage anywhere. This is the code, with the items named properly: Image_Data: TMemorystream; Image_Data := TMemorystream.Create; ... try Image_Data.Position := 0; IdHTTP1.Get(Image_Str, Image_Data); Image_Data.Position := 0; fcImager1.Picture.Graphic.LoadFromStream(Image_Data); fcImager1.Visible := true; finally as you can see, there is no JPegImage specifier. The Picture component of the IDE is supposed to be able to display a variety of image types, but apparently not a .GIF? Rob Kenned Delphi Developer Sat, 16 Jan 2010 10:31:43 GMT Re:JPEG Error #53
procedure TForm1.Button1Click(Sender: TObject); var MemStrm: TMemoryStream; Jpg: TJPEGImage; begin If Table1Foto.IsNull then begin Image1.Picture.Assign(nil); Abort; end; Jpg:=TJPEGImage.Create; try MemStrm:=TMemoryStream.Create; try Table1Foto.SaveToStream(MemStrm); MemStrm.Seek(0,soFromBeginning); with Jpg do begin PixelFormat:=jf24Bit; Scale:=jsEighth; GrayScale:=False; Performance:=jpBestQuality; ProgressiveDisplay:=True; ProgressiveEncoding:=True; LoadFromStream(MemStrm); end; Image1.Picture.Assign(Jpg); finally MemStrm.Free; end; finally Jpg.Free; end; end; When I execute, I always get error message 'Jpeg error #53'. How do I resolve it ? Thanks for your time. Regards, Marcio Dalmolin Dennis Passmore Delphi Developer 2006-08-15 11:26:01 PM http://www.delphigroups.info/2/c9/419766.html Re:Jpeg error #53 Usally this is a simple out of memory error caused by a invalid jpeg image. In your case since you are trying to save it from a table read from a Oracle table I'd think that the problem is in your Table1Foto.SaveToStream(MemStrm); code since you do not specify the field name but are atempting to save http://www.delphigroups.info/2/4/318279.html the whole table to the stream which ends up not being a valid jpeg image. Dennis Passmore "Think it might be a new experience and if you can't Pull then at least Push the job will get done" Igor Raskin Delphi Developer 2006-08-16 01:26:09 AM Re:Jpeg error #53 "Dennis Passmore"
for Help Receive Real-Time Help Create a Freelance Project Hire for a Full Time Job Ways to Get Help Ask a Question Ask for Help https://www.experts-exchange.com/questions/27635099/Delphi-Error-when-loading-96dpi-jpeg-file-into-Image-Picture.html Receive Real-Time Help Create a Freelance Project Hire for a Full http://www.cyberforum.ru/delphi-beginners/thread341022.html Time Job Ways to Get Help Expand Search Submit Close Search Login Join Today Products BackProducts Gigs Live Careers Vendor Services Groups Website Testing Store Headlines Experts Exchange > Questions > Delphi - Error when loading 96dpi jpeg file into Image.Picture Want to Advertise Here? error 53 Solved Delphi - Error when loading 96dpi jpeg file into Image.Picture Posted on 2012-03-16 Delphi 1 Verified Solution 8 Comments 1,771 Views Last Modified: 2012-03-18 I can load a 72dpi jpeg file into TImage using Image.Picture.LoadFromFile(FileName); but not a 96dpi jpeg file. If I change the code to the following, I get the same jpeg error 53 result jpeg:= TJpegImage.Create; jpeg.LoadFromFile(filename); Image.Picture.Graphic := jpeg; What changes do I need to make for 96 dpi images? I use Delphi XE. Thanks 0 Question by:Dennis_Treacy Facebook Twitter LinkedIn Google LVL 22 Active today Best Solution byFerruccio Accalai Well, that's a PNG file renamed to JPG. In fact also Photoshop CS have matters trying to open it. It says "Invalid JPEG marker type is found". Reading the header of the file you can see a PNG marker. Go to Solution 8 Comments LVL 25 Overall: Level 25 Delphi 24 Message Active 1 day ago Expert Comment by:Sinisa Vuk2012-03-16 what error do you get? Try "draw" method to convert jpeg to bitmap and then assign to image. http://www.greatis.com/delphicb/tips/lib/algorithms-jpeg2bmp.html info: http://stackoverflow.com/questions/4001719/getting-jpeg-resolution-without-decoding-the-image 0 LVL 36 Overall: Level 36 Delphi 31 Message Active today Expert Comment by:Geert Gruwez2012-03-16 or attach the jpeg so we can do some troubleshooting 0 Message Author Comment by:Dennis_Treacy2012-03-16 I have
Тесты Блоги Сообщество Поиск Ссылки сообщества Социальные группы Поиск Google по форуму Поиск Yandex по форуму Поиск по форуму Расширенный поиск Тесты Список тестов К странице... 1 из 2 1 2 > » @trest 0 / 0 / 0 Регистрация: 25.06.2011 Сообщений: 67 11.08.2011, 08:18 JPEG error #53 #1 здравствуйте. вылетает ошибка JPEG error #53 , как я понял из за того что подгружается "неправильный" Jpeg файл а можно ли как то отсортировать файла на "правильность" так чтобы если файл не устраивает программу она не закрывалась бы с критичной ошибкой, а просто копировала бы этот файл в отдельную папку Similar Эксперт 41792 / 34177 / 6122 Регистрация: 12.04.2006 Сообщений: 57,940 11.08.2011, 08:18 JPEG error #53 Посмотрите здесь: JPEG in Delphi Delphi Delphi jpeg in delphyDelphi Картиночки jpeg))Delphi JPEG error # 53 В Delphi 7 всё работает, а в 2010 нет. Где я туплю?JPEG error #53 Delphi После регистрации реклама в сообщениях будет скрыта и будут доступны все возможности форума. DenNik 1003 / 694 / 91 Регистрация: 26.07.2011 Сообщений: 4,339 11.08.2011, 09:29 JPEG error #53 #2 может быть, у тебя JPEG2000? @Андрей Борисови 708 / 396 / 16 Регистрация: 04.10.2009 Сообщений: 1,683 11.08.2011, 11:01 JPEG error #53 #3 {$I-} try .... exept ... end; {$I+} @trest 0 / 0 / 0 Регистрация: 25.06.2011 Сообщений: 67 11.08.2011, 12:04 [ТС] JPEG error #53 #4 Сообщение от DenNik может быть, у тебя JPEG2000? незнаю я различия между двумя файлами увидел только глубину цвета на одном 24 на другом 8 вот как раз на котором 8 и вылетает ошибка Добавлено через 41 секунду Сообщение от Андрей Борисови {$I-} try .... exept ... end; {$I+} чето совсем ничего не понял @Arcor 4760 / 1761 / 152 Регистрация: 20.11.2009 Сообщений: 5,553 Записей в блоге: 1 11.08.2011, 12:08 JPEG error #53 #5 Сообщение от trest Цитата Сообщение от Андрей Борисови Посмотреть сообщение {$I-} try .... exept ... end; {$I+} чето совсем ничего не понял Критическая ситуация, если нету ошибки выполнится код который в разделе Try занесен, если ошибка будет то обработается раздел except то есть в except можно занести например сообщение что не может быть загружен этот файл, а в try занести дальнейшую обработку, если файл успешно был загружен DenNik 1003 / 694 / 91 Регистрация: 26.07.2011 Сообщений: 4,339 11.08.2011, 12:34 JPEG error #53 #6 trest, выложи плз свою 8-битную картинку @trest 0 / 0 / 0 Регистрация: 25.06.2011 Сообщений: 67 11.08.2011, 14:54 [ТС] JPEG error #53 #7 Сообщение от DenNik trest, выложи плз свою 8-битную картинку ха сейчас решил выложить файл, а мне вылезло со