mirror of
				https://github.com/Drezil/imgui.git
				synced 2025-10-31 13:11:05 +01:00 
			
		
		
		
	Minor comments
This commit is contained in:
		
							
								
								
									
										10
									
								
								imgui.h
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								imgui.h
									
									
									
									
									
								
							| @@ -864,7 +864,7 @@ struct ImGuiIO | ||||
|     ImVec2      MouseDelta;                 // Mouse delta. Note that this is zero if either current or previous position are negative, so a disappearing/reappearing mouse won't have a huge delta for one frame. | ||||
|  | ||||
|     //------------------------------------------------------------------ | ||||
|     // [Private] ImGui will maintain those fields. Forward compatibility not guaranteed! | ||||
|     // [Internal] ImGui will maintain those fields. Forward compatibility not guaranteed! | ||||
|     //------------------------------------------------------------------ | ||||
|  | ||||
|     ImVec2      MousePosPrev;               // Previous mouse position temporary storage (nb: not for public use, set to MousePos in NewFrame()) | ||||
| @@ -1379,12 +1379,12 @@ struct ImFontAtlas | ||||
|  | ||||
|     // Build atlas, retrieve pixel data. | ||||
|     // User is in charge of copying the pixels into graphics memory (e.g. create a texture with your engine). Then store your texture handle with SetTexID(). | ||||
|     // RGBA32 format is provided for convenience and high compatibility, but note that all RGB pixels are white, so 75% of the memory is wasted. | ||||
|     // RGBA32 format is provided for convenience and compatibility, but note that unless you use CustomRect to draw color data, the RGB pixels emitted from Fonts will all be white (~75% of waste).  | ||||
|     // Pitch = Width * BytesPerPixels | ||||
|     IMGUI_API bool              Build();                    // Build pixels data. This is called automatically for you by the GetTexData*** functions. | ||||
|     IMGUI_API void              GetTexDataAsAlpha8(unsigned char** out_pixels, int* out_width, int* out_height, int* out_bytes_per_pixel = NULL);  // 1 byte per-pixel | ||||
|     IMGUI_API void              GetTexDataAsRGBA32(unsigned char** out_pixels, int* out_width, int* out_height, int* out_bytes_per_pixel = NULL);  // 4 bytes-per-pixel | ||||
|     void                        SetTexID(ImTextureID id)  { TexID = id; } | ||||
|     void                        SetTexID(ImTextureID id)    { TexID = id; } | ||||
|  | ||||
|     //------------------------------------------- | ||||
|     // Glyph Ranges | ||||
| @@ -1434,7 +1434,7 @@ struct ImFontAtlas | ||||
|     int                         TexDesiredWidth;    // Texture width desired by user before Build(). Must be a power-of-two. If have many glyphs your graphics API have texture size restrictions you may want to increase texture width to decrease height. | ||||
|     int                         TexGlyphPadding;    // Padding between glyphs within texture in pixels. Defaults to 1. | ||||
|  | ||||
|     // [Private] | ||||
|     // [Internal] | ||||
|     // NB: Access texture data via GetTexData*() calls! Which will setup a default font for you. | ||||
|     unsigned char*              TexPixelsAlpha8;    // 1 component per pixel, each component is unsigned 8-bit. Total size = TexWidth * TexHeight | ||||
|     unsigned int*               TexPixelsRGBA32;    // 4 component per pixel, each component is unsigned 8-bit. Total size = TexWidth * TexHeight * 4 | ||||
| @@ -1487,7 +1487,7 @@ struct ImFont | ||||
|     IMGUI_API void              RenderChar(ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, unsigned short c) const; | ||||
|     IMGUI_API void              RenderText(ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, const ImVec4& clip_rect, const char* text_begin, const char* text_end, float wrap_width = 0.0f, bool cpu_fine_clip = false) const; | ||||
|  | ||||
|     // [Private] | ||||
|     // [Internal] | ||||
|     IMGUI_API void              GrowIndex(int new_size); | ||||
|     IMGUI_API void              AddGlyph(ImWchar c, float x0, float y0, float x1, float y1, float u0, float v0, float u1, float v1, float advance_x); | ||||
|     IMGUI_API void              AddRemapChar(ImWchar dst, ImWchar src, bool overwrite_dst = true); // Makes 'dst' character/glyph points to 'src' character/glyph. Currently needs to be called AFTER fonts have been built. | ||||
|   | ||||
		Reference in New Issue
	
	Block a user