Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

the vhdl code for the video processing

Status
Not open for further replies.

aasif

Member level 2
Joined
Sep 17, 2003
Messages
48
Helped
1
Reputation
2
Reaction score
0
Trophy points
1,286
Activity points
405
hdl images

I want to write some Verilog/VHDL code for image processing. Writing simulator to verify the code is a difficult task. Can any image file (e.g. bmp, tiff etc) be the input of Verilog(/VHDL) source code, and after processing the image, the output image be stored as image file (In hardDisk)? So that by seeing the output image, the processing can be verified.
 

xvibe

Member level 5
Joined
Jul 11, 2003
Messages
88
Helped
5
Reputation
10
Reaction score
3
Trophy points
1,288
Location
Portugal
Activity points
783
reading bmp files verilog

I'm using a PCMCIA card with a VirtexII FPGA inside for developing a H.264 CODEC. It's from Annapolis Micro Systems and it's the WILDCARD-II.
https://www.annapmicro.com

With that I can load a video in H.264 stored in the PC and play the video using the decoder inside the FPGA.
Maybe this card can solve your problem, but I don't know how to load an image file to a simulator and then save the result to an image file. I'm also seeking for this....
 

gooodman

Member level 2
Joined
Nov 18, 2004
Messages
42
Helped
4
Reputation
8
Reaction score
3
Trophy points
1,288
Activity points
322
how to read image file in verilog

This is a sample Motion Estimation include testbench in Verilog. FYI
h**p://opencores.org/cvsweb.shtml/macroblock_motion_detection/
 

niuniu

Member level 5
Joined
Jul 23, 2002
Messages
87
Helped
4
Reputation
8
Reaction score
0
Trophy points
1,286
Activity points
691
what is the vhdl code to read an image file input

write a PLI, or use systemc. many simulator now support simple co-simulation of systemc and hdl
 

aasif

Member level 2
Joined
Sep 17, 2003
Messages
48
Helped
1
Reputation
2
Reaction score
0
Trophy points
1,286
Activity points
405
bmp to vhdl

Can u post here any example that uses PLI?
I want to read and write image files with VHDL/Verilog source code, can this be done easily? If you have any example then plz post it.
 

niuniu

Member level 5
Joined
Jul 23, 2002
Messages
87
Helped
4
Reputation
8
Reaction score
0
Trophy points
1,286
Activity points
691
read and display images using vhdl

there is one book on PLI
"The Verilog PLI Handbook", by Stuart Sutherland, published by Kluwer Academic
Publishers, copyright 1999.
i have not find the ebook version. but has example on this book.

if what you want is to just read/write binary files, you can use verilog2k syntax
mainstream simulation now support v2k now.
if your simulator do not support v2k, find the popular fileio PLI on the internet. it is also a good example on how to write PLI.
 

kctang

Member level 1
Joined
Nov 4, 2004
Messages
39
Helped
2
Reputation
4
Reaction score
0
Trophy points
1,286
Activity points
451
reading bmp file in verilog

You can try to use PPM (P3) format for generating pixel output in verilog simulation.
It's a pure text mode format which can be generated by verilog $fdisplay function calls.

I've use this format to generate image outputs in both LCD controller and JPEG deocder project, enjoy!!!
 

king002

Newbie level 4
Joined
Feb 14, 2003
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
62
v2k fileio

Digital signal Proecessing with Field Programmable Gate Arrays

Springer

U.Meyer-Bases
 

aliraza

Newbie level 5
Joined
Nov 3, 2004
Messages
9
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
84
verilog read image file

Dear king002:

I have this book:

Digital Signal Processing with FPGA by Meyer Baese

Do you need it?
 

nand_gates

Advanced Member level 3
Joined
Jul 19, 2004
Messages
893
Helped
175
Reputation
350
Reaction score
51
Trophy points
1,308
Activity points
6,843
reading of bmp image in verilog syntax

Modelsim provides very good integration with tcl/Tk you can use that for
displaying the images directly. For this you dont need any PLI stuff!
 

dddain_bramage

Junior Member level 1
Joined
Mar 1, 2005
Messages
17
Helped
3
Reputation
6
Reaction score
1
Trophy points
1,283
Activity points
1,666
how to read bitmap image in verilog

> Modelsim provides very good integration with tcl/Tk you can use that for
displaying the images directly. For this you dont need any PLI stuff!

How hard is it to display a bitmap image using Tcl/Tk? Can this be done in other simulator-environments (like Cadence's NC-Sim, which also uses Tcl/Tk), or only Modelsim?

I'm guessing the image-display would be a 'post-simulation' activity (after the Verilog-testbench $finish.) You would use Tcl/Tk to read the experimental output-file, then try to display it? Is that correct?
 

jarodz

Full Member level 1
Joined
Mar 12, 2005
Messages
96
Helped
16
Reputation
32
Reaction score
3
Trophy points
1,288
Location
Taiwan
Activity points
2,147
image simulation ppm bmp

I had write a module to read/write bmp by using verilog system task function.
This module can be instance in Testbench to get the pixel value of the bmp.
If you need, I can share it.


Regard,
Jarod
 

jarodz

Full Member level 1
Joined
Mar 12, 2005
Messages
96
Helped
16
Reputation
32
Reaction score
3
Trophy points
1,288
Location
Taiwan
Activity points
2,147
verilog vhdl motion estimation

According to arun_student's request,

Here is the verilog code to read/write bmp format in simulation.
It doesnt support all formats of BMP specification.
I only use it to read/write 24 bit bmp file.
If someone is interested in improving it, please send me a copy.


Sincerely,
Jarod
 

manish12

Advanced Member level 3
Joined
Nov 21, 2006
Messages
982
Helped
66
Reputation
132
Reaction score
33
Trophy points
1,308
Activity points
6,114
display bmp modelsim

any new news regarding the image load on fpga using vhdl .
what i get as
1] convert image file into bin or hex file using some c code or matlab
2] use io file handling for access
3] again for output use matlab or convert file[matrix file] into jpg , bmp
 

shobhitk

Member level 2
Joined
Jun 29, 2006
Messages
47
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,558
images on hdl

In my previous method I used perl model for converting real image but its was in ppm format
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top