
    <gR                         d dl mZ d dlmZmZmZ d dlmZ d dlm	Z	  e	e       e	d      k  r e
dez         G d de      Zy	)
    )Enum)BytesIOKaitaiStreamKaitaiStruct)__version__)parse_versionz0.7zPIncompatible Kaitai Struct Python API: 0.7 or later is required, but you have %sc                   V    e Zd Zd	dZd Z G d de      Z G d de      Zed        Z	y)
ExifLeNc                 V    || _         || _        |r|n| | _        | j                          y N_io_parent_root_readselfr   r   r   s       r/var/www/html/myenv/lib/python3.12/site-packages/seleniumwire/thirdparty/mitmproxy/contrib/kaitaistruct/exif_le.py__init__zExifLe.__init__   s$    #U


    c                     | j                   j                         | _        | j                   j                         | _        y r   )r   	read_u2leversion	read_u4leifd0_ofsr   s    r   r   zExifLe._read   s*    xx))+**,r   c                   *    e Zd ZddZd Zed        Zy)
ExifLe.IfdNc                 V    || _         || _        |r|n| | _        | j                          y r   r   r   s       r   r   zExifLe.Ifd.__init__   $    DH"DL"'TDJJJLr   c                 Z   | j                   j                         | _        d g| j                  z  | _        t	        | j                        D ]@  }| j
                  j                  | j                   | | j
                        | j                  |<   B | j                   j                         | _        y r   )	r   r   
num_fieldsfieldsranger   IfdFieldr   next_ifd_ofs)r   is     r   r   zExifLe.Ifd._read   s    "hh002DO&DOO4DK4??+ Q!%!4!4TXXtTZZ!PAQ !% 2 2 4Dr   c                    t        | d      rt        | d      r| j                  S d S | j                  dk7  r| j                  j	                         }| j                  j                  | j                         | j                  j                  | j                  | | j                        | _        | j                  j                  |       t        | d      r| j                  S d S )N_m_next_ifdr   )hasattrr)   r&   r   posseekr   Ifdr   _poss     r   next_ifdzExifLe.Ifd.next_ifd&   s    t]++24+Gt''QTQ  A%xx||~d//0#'::>>$((D$**#M d#'.t]'C4##MMr   NN)__name__
__module____qualname__r   r   propertyr0    r   r   r-   r      s"    		5 

	N 

	Nr   r-   c                       e Zd Z G d de      Z G d de      ZddZd Zed        Z	ed	        Z
ed
        Zed        Zy)ExifLe.IfdFieldc                   ,    e Zd ZdZdZdZdZdZdZ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0Z2d1Z3d2Z4d3Z5d4Z6d5Z7d6Z8d7Z9d8Z:d9Z;d:Z<d;Z=d<Z>d=Z?d>Z@d?ZAd@ZBdAZCdBZDdCZEdDZFdEZGdFZHdGZIdHZJdIZKdJZLdKZMdLZNdMZOdNZPdOZQdPZRdQZSdRZTdSZUdTZVdUZWdVZXdWZYdXZZdYZ[dZZ\d[Z]d\Z^d]Z_d^Z`d_Zad`ZbdaZcdbZddcZeddZfdeZgdfZhdgZidhZjdiZkdjZldkZmdlZndmZodnZpdoZqdpZrdqZsdrZtdsZudtZvduZwdvZxdwZydxZzdyZ{dzZ|d{Z}d|Z~d}Zd~ZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZÐdZĐdÐZŐdĐZƐdŐZǐdƐZȐdǐZɐdȐZʐdɐZːdʐZ̐y(  ExifLe.IfdField.TagEnum   i  i  i  i  i  i  i	  i
  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i   i!  i"  i#  i$  i%  i(  i)  i,  i-  i1  i2  i;  i<  i=  i>  i?  i@  iA  iB  iC  iD  iE  iF  iG  iH  iJ  iL  iM  iN  iP  iQ  iR  iS  iT  iU  iV  iW  iX  iY  iZ  i[  i_  i  i  i  i  i  i  i  i  i  i  i   i  i  i  i  i  i  i  i	  i  i  i  i  i/  i  i  i   i  i  iFG  iGG  iHG  iIG  i p  i2p  i5p  i7p  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i}  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i5  i6  i\  i]  i^  i_  i  i~  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  iF  ih  i  iׅ  i؅  i  i  iI  ii  is  i  i  i  i  i  i  i  i  i  i"  i$  i%  i'  i(  i)  i*  i+  i0  i1  i2  i3  i4  i5  i\  i]  i^  iq  i  i   i  i  i	  i  i  i  i  i  i  i  i  i  i  i  i  i  i	  i
  i  i  i  i  i  i  i  i  i  i  i  i  i  i:  i;  i<  i?  i|  i  i  i  i  i/  i0  i1  i\  i   i  i  i  i  i  i  i  i  i  i  i   i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i   i  i  i  i  i  i  i  i  i  i  i	  i
  i  i  i   i0  i1  i2  i3  i4  i5  i  i  i   i  i  i¯  iï  iį  iů  i  i  i  i  i  i  i  i  i  i  i¼  iü  iļ  iż  i'  i(  i)  i*  iO  i  is  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i   i!  i"  i#  i$  i%  i&  i'  i(  i)  i*  i+  i,  i-  i.  i/  i0  i1  i2  i3  i4  i5  i@  iZ  i[  i\  i]  i`  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i%  i&  i@  iA  iN  ia  ic  id  ir  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i  i   iL  iM  iN  iQ  iR  iS  iT  iU  iV  iW  iX  N(  r2   r3   r4   image_widthimage_heightbits_per_samplecompressionphotometric_interpretationthresholding
cell_widthcell_length
fill_orderdocument_nameimage_descriptionmakemodelstrip_offsetsorientationsamples_per_pixelrows_per_stripstrip_byte_countsmin_sample_valuemax_sample_valuex_resolutiony_resolutionplanar_configuration	page_name
x_position
y_positionfree_offsetsfree_byte_countsgray_response_unitgray_response_curve
t4_options
t6_optionsresolution_unitpage_numbercolor_response_unittransfer_functionsoftwaremodify_dateartisthost_computer	predictorwhite_pointprimary_chromaticities	color_maphalftone_hints
tile_widthtile_lengthtile_offsetstile_byte_countsbad_fax_linesclean_fax_dataconsecutive_bad_fax_linessub_ifdink_set	ink_namesnumberof_inks	dot_rangetarget_printerextra_samplessample_formats_min_sample_values_max_sample_valuetransfer_range	clip_pathx_clip_path_unitsy_clip_path_unitsindexedjpeg_tables	opi_proxyglobal_parameters_ifdprofile_typefax_profilecoding_methodsversion_yearmode_numberdecodedefault_image_colort82_optionsjpeg_tables2	jpeg_procthumbnail_offsetthumbnail_lengthjpeg_restart_intervaljpeg_lossless_predictorsjpeg_point_transformsjpegq_tablesjpegdc_tablesjpegac_tablesy_cb_cr_coefficientsy_cb_cr_sub_samplingy_cb_cr_positioningreference_black_whitestrip_row_countsapplication_notesuspto_miscellaneousrelated_image_file_formatrelated_image_widthrelated_image_heightrating
xp_dip_xmlstitch_inforating_percentsony_raw_file_typelight_falloff_params chromatic_aberration_corr_paramsdistortion_corr_paramsimage_id	wang_tag1wang_annotation	wang_tag3	wang_tag4image_reference_pointsregion_xform_tack_pointwarp_quadrilateralaffine_transform_matmatteing	data_typeimage_depth
tile_depthimage_full_widthimage_full_heighttexture_format
wrap_modesfov_cotmatrix_world_to_screenmatrix_world_to_cameramodel2cfa_repeat_pattern_dimcfa_pattern2battery_level	kodak_ifd	copyrightexposure_timef_numbermd_file_tagmd_scale_pixelmd_color_tablemd_lab_namemd_sample_infomd_prep_datemd_prep_timemd_file_unitspixel_scaleadvent_scaleadvent_revisionuic1_taguic2_taguic3_taguic4_tagiptc_naaintergraph_packet_dataintergraph_flag_registersintergraph_matrixingr_reservedmodel_tie_pointsitecolor_sequence
it8_headerraster_paddingbits_per_run_lengthbits_per_extended_run_lengthcolor_tableimage_color_indicatorbackground_color_indicatorimage_color_valuebackground_color_valuepixel_intensity_rangetransparency_indicatorcolor_characterizationhc_usagetrap_indicatorcmyk_equivalentsem_info	afcp_iptcpixel_magic_jbig_optionsjpl_carto_ifdmodel_transformwb_grgb_levels	leaf_dataphotoshop_settingsexif_offseticc_profiletiff_fx_extensionsmulti_profilesshared_datat88_optionsimage_layergeo_tiff_directorygeo_tiff_double_paramsgeo_tiff_ascii_paramsjbig_optionsexposure_programspectral_sensitivitygps_infoisoopto_electric_conv_factor	interlacetime_zone_offsetself_timer_modesensitivity_typestandard_output_sensitivityrecommended_exposure_index	iso_speediso_speed_latitudeyyyiso_speed_latitudezzzfax_recv_paramsfax_sub_addressfax_recv_time	fedex_edrleaf_sub_ifdexif_versiondate_time_originalcreate_dategoogle_plus_upload_codeoffset_timeoffset_time_originaloffset_time_digitizedcomponents_configurationcompressed_bits_per_pixelshutter_speed_valueaperture_valuebrightness_valueexposure_compensationmax_aperture_valuesubject_distancemetering_modelight_sourceflashfocal_lengthflash_energyspatial_frequency_responsenoisefocal_plane_x_resolutionfocal_plane_y_resolutionfocal_plane_resolution_unitimage_numbersecurity_classificationimage_historysubject_areaexposure_indextiff_ep_standard_idsensing_methodcip3_data_file
cip3_sheet	cip3_sidesto_nits
maker_noteuser_commentsub_sec_timesub_sec_time_originalsub_sec_time_digitizedms_document_textms_property_set_storagems_document_text_positionimage_source_dataambient_temperaturehumiditypressurewater_depthaccelerationcamera_elevation_anglexp_title
xp_comment	xp_authorxp_keywords
xp_subjectflashpix_versioncolor_spaceexif_image_widthexif_image_heightrelated_sound_fileinterop_offsetsamsung_raw_pointers_offsetsamsung_raw_pointers_lengthsamsung_raw_byte_ordersamsung_raw_unknownflash_energy2spatial_frequency_response2noise2focal_plane_x_resolution2focal_plane_y_resolution2focal_plane_resolution_unit2image_number2security_classification2image_history2subject_locationexposure_index2tiff_ep_standard_id2sensing_method2file_source
scene_typecfa_patterncustom_renderedexposure_modewhite_balancedigital_zoom_ratiofocal_length_in35mm_formatscene_capture_typegain_controlcontrast
saturation	sharpnessdevice_setting_descriptionsubject_distance_rangeimage_unique_id
owner_nameserial_number	lens_info	lens_make
lens_modellens_serial_numbergdal_metadatagdal_no_datagammaexpand_softwareexpand_lensexpand_filmexpand_filter_lensexpand_scannerexpand_flash_lamppixel_formattransformationuncompressed
image_typeimage_width2image_height2width_resolutionheight_resolutionimage_offsetimage_byte_countalpha_offsetalpha_byte_countimage_data_discardalpha_data_discardoce_scanjob_descoce_application_selectoroce_id_numberoce_image_logicannotationsprint_imoriginal_file_nameuspto_original_content_typedng_versiondng_backward_versionunique_camera_modellocalized_camera_modelcfa_plane_color
cfa_layoutlinearization_tableblack_level_repeat_dimblack_levelblack_level_delta_hblack_level_delta_vwhite_leveldefault_scaledefault_crop_origindefault_crop_sizecolor_matrix1color_matrix2camera_calibration1camera_calibration2reduction_matrix1reduction_matrix2analog_balanceas_shot_neutralas_shot_white_xybaseline_exposurebaseline_noisebaseline_sharpnessbayer_green_splitlinear_response_limitcamera_serial_numberdng_lens_infochroma_blur_radiusanti_alias_strengthshadow_scalesr2_privatemaker_note_safetyraw_image_segmentationcalibration_illuminant1calibration_illuminant2best_quality_scaleraw_data_unique_idalias_layer_metadataoriginal_raw_file_nameoriginal_raw_file_dataactive_areamasked_areasas_shot_icc_profileas_shot_pre_profile_matrixcurrent_icc_profilecurrent_pre_profile_matrixcolorimetric_reference
s_raw_typepanasonic_titlepanasonic_title2camera_calibration_sigprofile_calibration_sigprofile_ifdas_shot_profile_namenoise_reduction_appliedprofile_nameprofile_hue_sat_map_dimsprofile_hue_sat_map_data1profile_hue_sat_map_data2profile_tone_curveprofile_embed_policyprofile_copyrightforward_matrix1forward_matrix2preview_application_namepreview_application_versionpreview_settings_namepreview_settings_digestpreview_color_spacepreview_date_timeraw_image_digestoriginal_raw_file_digestsub_tile_block_sizerow_interleave_factorprofile_look_table_dimsprofile_look_table_dataopcode_list1opcode_list2opcode_list3noise_profile
time_codes
frame_ratet_stop	reel_nameoriginal_default_final_sizeoriginal_best_quality_sizeoriginal_default_crop_sizecamera_labelprofile_hue_sat_map_encodingprofile_look_table_encodingbaseline_exposure_offsetdefault_black_rendernew_raw_image_digestraw_to_preview_gaindefault_user_croppaddingoffset_schemaowner_name2serial_number2lenskdc_ifdraw_file	converterwhite_balance2exposureshadows
brightness	contrast2saturation2
sharpness2
smoothnessmoire_filterr6   r   r   TagEnumrM   @   s	   KL!OK),&LJKJM #DEMK # N #""LL#& IJJL"!$"%JJ!OK"% #HKFMIK%("I NJKL"M N(+%GGIMI NMM!$!$ NI # #GKI$'!LK NLKF"%KLI""$'!'*$$'!LMM#& #& "%$'!" #"%(,%"&#' FJK"N!&#( /4,%*"HI#OII%*"&+#!&#( HIKJ$ %"NJG%*"%*"F%*" L!MII!MHK"N"NK"N L L!MK L#OHHHHH%*"(-% %!M#OD"NJ"N"'+0(K$)!).& %%*"$)!%*"%*"H"N#OHI',$!M#O"NI!&KK!&"NKKK!&%*"$)! L$#( HC(-%I$#O$*/').&I$)!$)!#O#O!MI L L!&K&+#K#( $)!',$(-%"'"N$$)!!&$!M LE L L).&E',$',$*/' L&+#!M L"N"'"N"NJIHJ L L$)!%*"$&+#(-% %"'HHK L%*"HJIKJ$K$ %!&"N*/'*/'%*""'!M*/'F(-%(-%+0(!M',$"N$#O#( #OKJK#O!M!M!&).&!& LHJI).&%*"#OJ!MIIJ!&!M LE#OKK!&"N % L"N LJ L!M$ % L$ L$!&!&$',$!M#OKH!&*/'K#( "'%*"#OJ"'%*"K"'"'K!M"' %!M!M"'"' % %"N#O$ %"N!& %$)!#( !M!&"' LK %%*"&+#&+#!&!&#( %*"%*"K L"').&"').&%*"J#O$%*"&+#K#( &+# L',$(-%(-%!&#(  %#O#O',$*/'$)!&+#"' %$',$"'$)!&+#&+# L L L!MJJFI*/').&).& L+0(*/'',$#( #( "' %G!MK"NDGHI"NHGJIKJJ Lr   r  Nc                 V    || _         || _        |r|n| | _        | j                          y r   r   r   s       r   r   zExifLe.IfdField.__init__  r    r   c                    | j                   j                  j                  | j                  j	                               | _        | j                   j                  j                  | j                  j	                               | _        | j                  j                         | _	        | j                  j                         | _
        y r   )r   r%   r  r   r   tagrK   
field_typer   lengthofs_or_datar   s    r   r   zExifLe.IfdField._read  s}    zz**224883E3E3GHDH"jj11??@R@R@TUDO((,,.DK#xx113Dr   c                 t   t        | d      rt        | d      r| j                  S d S | j                  | j                  j                  j
                  j                  k(  rdn:| j                  | j                  j                  j
                  j                  k(  rdnd| _        t        | d      r| j                  S d S )N_m_type_byte_lengthr<   r>   r;   )r*   r!  r  r   r%   rK   rE   rF   r   s    r   type_byte_lengthz ExifLe.IfdField.type_byte_length  s    t233:4AV3Wt//a]aa-1__

@S@S@a@a@f@f-frv  sB  sB  FJ  FP  FP  FY  FY  Fg  Fg  Fm  Fm  smmn  stD$/6t=R/S4++]Y]]r   c                     t        | d      rt        | d      r| j                  S d S | j                  | j                  z  | _        t        | d      r| j                  S d S )N_m_byte_length)r*   r$  r  r"  r   s    r   byte_lengthzExifLe.IfdField.byte_length  s[    t-..5d<L.Mt**WSWW#';;1F1F#FD*1$8H*I4&&StSr   c                     t        | d      rt        | d      r| j                  S d S | j                  dk  | _        t        | d      r| j                  S d S )N_m_is_immediate_datar>   )r*   r'  r%  r   s    r   is_immediate_dataz!ExifLe.IfdField.is_immediate_data'  sX    t344;DBX4Yt00c_cc(,(8(8A(=D%07>T0U4,,_[__r   c                 ~   t        | d      rt        | d      r| j                  S d S | j                  sr| j                  j                  }|j                         }|j                  | j                         |j                  | j                        | _        |j                  |       t        | d      r| j                  S d S )N_m_data)
r*   r*  r(  r   r   r+   r,   r  
read_bytesr%  )r   ior/   s      r   datazExifLe.IfdField.data/  s    tY''.tY'?t||ITI**ZZ^^vvx(()!}}T-=-=>#*4#;4<<EEr   r1   )r2   r3   r4   r   rK   r  r   r   r5   r"  r%  r(  r-  r6   r   r   r%   r8   4   s    	D 	J	!d J	!V		4 
	^ 
	^ 
	T 
	T 
	` 
	` 
	F 
	Fr   r%   c                    t        | d      rt        | d      r| j                  S d S | j                  j                         }| j                  j	                  | j
                         | j                  j                  | j                  | | j                        | _        | j                  j	                  |       t        | d      r| j                  S d S )N_m_ifd0)r*   r/  r   r+   r,   r   r   r-   r.   s     r   ifd0zExifLe.ifd0>  s    4##*4#;4<<EExx||~dmm$zz~~dhhdjjAd&tY7t||ATAr   r1   )
r2   r3   r4   r   r   r   r-   r%   r5   r0  r6   r   r   r
   r
      sA    -Nl N:GF< GFT B Br   r
   N)enumr   kaitaistructr   r   r   r   
ks_versionpkg_resourcesr   	Exceptionr
   r6   r   r   <module>r6     sJ     < < 2 '}U33
fjtu
vv{B\ {Br   