ide на основе vs code
Это ide на основе vs code(code oss), в ней будет встроенный умный апи роутинг, свой маркет с плагинами(агент харнесс, поддержка java/kotlin/мобильной разработки, командная разработка проектов, orca, оркестратор агентов
Это ide на основе vs code(code oss), в ней будет встроенный умный апи роутинг, свой маркет с плагинами(агент харнесс, поддержка java/kotlin/мобильной разработки, командная разработка проектов, orca, оркестратор агентов
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { BugIndicatingError } from '../../../../base/common/errors.js';
import { ensureNonNullable } from '../gpuUtils.js';
import type { IRasterizedGlyph } from '../raster/raster.js';
import { UsagePreviewColors, type ITextureAtlasAllocator, type ITextureAtlasPageGlyph } from './atlas.js';
/**
* The shelf allocator is a simple allocator that places glyphs in rows, starting a new row when the
* current row is full. Due to its simplicity, it can waste space but it is very fast.
*/
export class TextureAtlasShelfAllocator implements ITextureAtlasAllocator {
private readonly _ctx: OffscreenCanvasRenderingContext2D;
_currentRow ITextureAtlasShelf
x
y
h
_allocatedGlyphs SetReadonlyITextureAtlasPageGlyph
_nextIndex
_canvas OffscreenCanvas
_textureIndex
_ctx _canvas
willReadFrequently
rasterizedGlyph IRasterizedGlyph ITextureAtlasPageGlyph
glyphWidth rasterizedGlyphboundingBoxright rasterizedGlyphboundingBoxleft
glyphHeight rasterizedGlyphboundingBoxbottom rasterizedGlyphboundingBoxtop
glyphWidth _canvaswidth glyphHeight _canvasheight
rasterizedGlyphboundingBoxright rasterizedGlyphboundingBoxleft _canvaswidth _currentRowx
_currentRowx
_currentRowy _currentRowh
_currentRowh
_currentRowy rasterizedGlyphboundingBoxbottom rasterizedGlyphboundingBoxtop _canvasheight
_ctx
rasterizedGlyphsource
rasterizedGlyphboundingBoxleft
rasterizedGlyphboundingBoxtop
glyphWidth
glyphHeight
_currentRowx
_currentRowy
glyphWidth
glyphHeight
glyph ITextureAtlasPageGlyph
pageIndex _textureIndex
glyphIndex _nextIndex
x _currentRowx
y _currentRowy
w glyphWidth
h glyphHeight
originOffsetX rasterizedGlyphoriginOffsetx
originOffsetY rasterizedGlyphoriginOffsety
fontBoundingBoxAscent rasterizedGlyphfontBoundingBoxAscent
fontBoundingBoxDescent rasterizedGlyphfontBoundingBoxDescent
_currentRowx glyphWidth
_currentRowh Math_currentRowh glyphHeight
_allocatedGlyphsglyph
glyph
Blob
w _canvaswidth
h _canvasheight
canvas w h
ctx canvas
ctxfillStyle UsagePreviewColorsUnused
ctx w h
rowHeight Map
rowWidth Map
g _allocatedGlyphs
rowHeightgy MathrowHeightgy gh
rowWidthgy MathrowWidthgy gx gw
g _allocatedGlyphs
ctxfillStyle UsagePreviewColorsUsed
ctxgx gy gw gh
ctxfillStyle UsagePreviewColorsWasted
ctxgx gy gh gw rowHeightgy gh
rowY rowW rowWidth
rowY _currentRowy
ctxfillStyle UsagePreviewColorsWasted
ctxrowW rowY w rowW rowHeightrowY
canvas
w _canvaswidth
h _canvasheight
usedPixels
wastedPixels
totalPixels w h
rowHeight Map
rowWidth Map
g _allocatedGlyphs
rowHeightgy MathrowHeightgy gh
rowWidthgy MathrowWidthgy gx gw
g _allocatedGlyphs
usedPixels gw gh
wastedPixels gw rowHeightgy gh
rowY rowW rowWidth
rowY _currentRowy
wastedPixels w rowW rowHeightrowY
x
y
h