# Cv2.rectangle() source code

**URL:** <https://forum.opencv.org/t/cv2-rectangle-source-code/2391>\
**Category:** Python\
**Created:** [March 26, 2021, 3:35am UTC](https://forum.opencv.org/t/cv2-rectangle-source-code/2391 "2021-03-26T03:35:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Akash\_Pandey](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.opencv.org/akash_pandey/32/1562_2.png) [@Akash\_Pandey](https://forum.opencv.org/u/Akash_Pandey)\
**Post date:** [March 26, 2021, 3:35am UTC](https://forum.opencv.org/t/cv2-rectangle-source-code/2391/1 "2021-03-26T03:35:27Z")

</div>

Hi Everyone,  
I need to see the exact source code of cv2.rectangle() for python method can anyone suggest me link for this, I have search the github but wasn’t able to find, If anyone can share link.  
Thanks.

---

<div class="post-metadata">

**Author:** ![laurent.berger](https://avatars.discourse-cdn.com/v4/letter/l/ec9cab/32.png) [@laurent.berger](https://forum.opencv.org/u/laurent.berger)\
**Post date:** [March 26, 2021, 4:24am UTC](https://forum.opencv.org/t/cv2-rectangle-source-code/2391/2 "2021-03-26T04:24:50Z")

</div>

Hi,  
there is no source in python (except binding), [it’s only c++](https://github.com/opencv/opencv/blob/master/modules/imgproc/src/drawing.cpp#L1829)

---

<div class="post-metadata">

**Author:** ![Akash\_Pandey](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.opencv.org/akash_pandey/32/1562_2.png) [@Akash\_Pandey](https://forum.opencv.org/u/Akash_Pandey)\
**Post date:** [March 27, 2021, 7:31am UTC](https://forum.opencv.org/t/cv2-rectangle-source-code/2391/3 "2021-03-27T07:31:18Z")

</div>

Thanks @laurent.berger
