MCPcopy Create free account

hub / github.com/ICE27182/Python-3D-renderer / functions

Functions116 in github.com/ICE27182/Python-3D-renderer

↓ 55 callersMethodrotate
(self, axis, degree)
pyrender.py:306
↓ 19 callersMethoddisplay
A pretty basic display function. Would work. Supports rescaling image according to the size of the terminal by skipping some
png.py:482
↓ 18 callersFunctionline
(normal, left, right, y)
pyrender.py:1197
↓ 16 callersMethodrotate_mesh
(self, x_degree=0, y_degree=0, z_degree=0)
v1.0/main.py:161
↓ 15 callersMethodset_position
(self, x, y, z)
pyrender.py:294
↓ 14 callersFunctionadd_line
(M, N)
pyrender.py:1167
↓ 13 callersMethodrender
(self)
pyrender.py:947
↓ 11 callersMethodload_obj
Load mesh(es) from a given obj file
v1.0/main.py:23
↓ 9 callersMethodwrite_as_bmp
Donno how to compress the idat chunk properly without writing the whole function myself and dumping the zlib
png.py:513
↓ 8 callersMethodline
(self, point1, point2, color="\033[38;2;127;127;127m██\033[0m")
v1.0/renderer.py:242
↓ 8 callersMethodline
(self, point1, point2, color="\033[38;2;127;127;127m██\033[0m")
v1.0/main.py:238
↓ 8 callersFunctionrasterize_solid
(A, B, C, normal)
pyrender.py:1196
↓ 7 callersMethodget_width_and_height
(self, width=None, height=None, width_reserved=2,
pyrender.py:895
↓ 7 callersFunctionrender
(objects:list, lights:list, cam:Camera)
pyrender.py:971
↓ 6 callersMethodmove_mesh
(self, destination)
v1.0/main.py:150
↓ 5 callersFunctioncalculate_camera_matrix
(cam, math)
v1.0/main.py:278
↓ 5 callersMethodcalculate_smooth_shading_normals
Check if obj.faces stores normals or not. Calculate the normal values first if it does not include them. Average all normals
pyrender.py:264
↓ 4 callersFunctioncalculate_camera_matrix
(cam)
v1.0/renderer.py:453
↓ 4 callersFunctiondepth
(A, B, C)
pyrender.py:2198
↓ 4 callersMethodget_chunk_length
(image_bytes:bytes, chunk_starting_index:int)
png.py:120
↓ 4 callersMethodget_normal
(self)
v1.0/main.py:130
↓ 4 callersMethodget_rotation_mat
(self)
pyrender.py:809
↓ 4 callersFunctiontexture
(A, B, C)
pyrender.py:1944
↓ 4 callersMethodvec3_minus_vec3
(v, u)
v1.0/main.py:272
↓ 3 callersMethodcalculate_face_normals
Check whether obj.faces stores the normal or not If not, it will go over every face and calculate the normal
pyrender.py:239
↓ 3 callersMethodcheck_crc
Check if the data matches the crc part. Raise Exception if not.
png.py:110
↓ 3 callersMethoddecode
Take the path of the image and then read the binary before decoding it. Store a list of tuples, in form of [[[r, g, b, alpha
png.py:124
↓ 3 callersFunctionnormalize_v3d
(vector)
pyrender.py:16
↓ 3 callersMethodrefresh
(self)
v1.0/main.py:226
↓ 3 callersMethodrender_shadow
(lights, objs)
pyrender.py:591
↓ 2 callersMethodchange_texture
(self, file_path)
pyrender.py:493
↓ 2 callersMethoddraw
frame - dict {y:{x:str}}
v1.0/main.py:255
↓ 2 callersMethodget_image_properties
Get all fundamental properties of the image. Store in the instance.
png.py:156
↓ 2 callersFunctionget_luminance
(normal, x3d, y3d, z3d)
pyrender.py:972
↓ 2 callersMethodget_normal
(self)
v1.0/renderer.py:129
↓ 2 callersMethodget_palette
Get self.palette [[r, g, b, Png.default_alpha], [...], ...]
png.py:182
↓ 2 callersMethodnew_frame
(self)
v1.0/main.py:222
↓ 2 callersFunctionrasterize_full
(A, B, C, normal)
pyrender.py:1556
↓ 2 callersMethodrefresh
(self)
v1.0/renderer.py:230
↓ 2 callersFunctionshadow
(A, B, C)
pyrender.py:2452
↓ 2 callersMethodstat
(self)
pyrender.py:805
↓ 2 callersMethodvec3_plus_vec3
(v, u)
v1.0/main.py:269
↓ 1 callersMethoddefilter
rows = [b'...', ...] Return a list containing bytes. [[int, int, ...], [...], ...]
png.py:245
↓ 1 callersMethodget_all_idat_data
Collect every IDAT chunk, for there may be more than one of them, and then decompress it. After that, separate them by row.
png.py:207
↓ 1 callersMethodget_screen_size
(self)
v1.0/renderer.py:206
↓ 1 callersMethodget_screen_size
(self)
v1.0/main.py:202
↓ 1 callersFunctiongunshot
()
v1.0/example.py:3
↓ 1 callersFunctionin_point_light_shadow
()
pyrender.py:973
↓ 1 callersMethodinterpret_bytes_to_color
rows = [[int, int, ...], [...], ...] return [[[r, g, b, a], [...], ...], [...], ...]
png.py:358
↓ 1 callersMethodload_mtl
(obj:Object, filename:str, dir:str)
pyrender.py:401
↓ 1 callersFunctionmain
()
v1.0/main.py:459
↓ 1 callersFunctionmuzzle_flash
()
v1.0/example.py:14
↓ 1 callersMethodnew_frame
(self)
v1.0/renderer.py:226
↓ 1 callersFunctionorthographic_render_shadow
Only for shadow rendering now, so some features are disabled and others are set for shadow rendering solely
pyrender.py:3021
↓ 1 callersFunctionrender
(meshes, display, cam, min_brightness, max_brightnss, light_dir, culling, faces, edges)
v1.0/main.py:291
↓ 1 callersMethodupdate_rotation
(self, cam)
pyrender.py:679
Method__init__
filename can be with or without ".png". Try to load the image from a pickle file if pickle has been successfully loaded and f
png.py:42
Method__init__
(self, name:str)
pyrender.py:33
Method__init__
(self, name:str)
pyrender.py:393
Method__init__
(self, position, strength=(1, 1, 1), direction=None, size=60, type=1, shadow=True)
pyrender.py:537
Method__init__
(self, x=0, y=0, z=0, yaw=90, pitch=0, roll=0, width=None
pyrender.py:766
Method__init__
(self)
pyrender.py:935
Method__init__
(self, density=10, position=(0, 0, 0), size=1)
particles.py:8
Method__init__
(self, name, v=None, vn=None, vt=None, f=None,)
v1.0/renderer.py:4
Method__init__
(self, fov=40, size=None, z_near=0.01, z_far=100, bottom_bar_info="", bottom_bar_height=None)
v1.0/renderer.py:187
Method__init__
(self, name, v=None, vn=None, vt=None, f=None,)
v1.0/main.py:4
Method__init__
(self, fov=40, size=None, z_near=0.01, z_far=100, bottom_bar_height=0)
v1.0/main.py:188
Method__str__
(self)
png.py:100
Method__str__
(self)
pyrender.py:71
Method__str__
(self)
pyrender.py:585
Method__str__
(self)
pyrender.py:800
Functionadd_lights
For debug use only. Must applied when other rendering process is done
pyrender.py:3390
Functionadd_obj_dir
For debug use only. Must applied when other rendering process is done
pyrender.py:3487
Methodadd_to_frame
(self, frame:list, lights:list, cam)
particles.py:37
Methodaverage_many_vectors_v3d
(vectors)
pyrender.py:270
Functionbytes_to_hex
Take bytes type and return a string of hex in upper case, separated with space by 2 digits
png.py:559
Methodchange_default_loading_dir
(self, dir:str)
pyrender.py:232
Methodcheck_name_collision
(name:str)
v1.0/renderer.py:24
Methodcheck_name_collision
(name:str)
v1.0/main.py:25
Functionclear
()
pyrender.py:3638
Functionconvert_depth_to_frame
(depth, z_near, z_far)
pyrender.py:3311
Functiondisplay
Store the last color(except 12, 12, 12) to fasten the print process
pyrender.py:3603
Methoddisplay
(frame)
pyrender.py:951
Functiondisplay_gs
(frame)
pyrender.py:3623
Methoddraw
frame - dict {y:{x:str}}
v1.0/renderer.py:259
Functionfxaa
Frame post-processing input a frame and it will return a processed one if the sum of different reaches threshold, blur will be applied
pyrender.py:3321
Methodget_digits
(num:int)
png.py:363
Functionkey_capture
()
v1.0/renderer.py:435
Functionkey_control
If you use the keyinput function in the module, which I don't recommend, you can call the function have some basic control on your camera. But sti
v1.0/renderer.py:467
Functionkeyinput
Start a new thread to get key input. Access the string variable key by renderer.key. Bool variable pause can also be accessed by renderer.key. Pr
v1.0/renderer.py:429
Functionkeyinput
()
v1.0/main.py:446
Methodleft_value
return the value of the pixel left to the pixel whose x value is given, 0 if doesn't exist
png.py:254
Functionlen_v
(v)
pyrender.py:21
Functionlen_v
(v)
pymain.py:198
Functionlen_v
(v)
prefinal.py:133
Methodload_img
(self)
pyrender.py:510
Methodload_obj
file can either be the name of the file or the path If path is entered, dir should be None
pyrender.py:80
Methodload_obj
Load mesh(es) from a given obj file
v1.0/renderer.py:22
Methodmainloop
(self)
pyrender.py:965
Methodmove_mesh
(self, destination)
v1.0/renderer.py:149
next →1–100 of 116, ranked by callers