@@ -604,22 +604,6 @@ STATIC mp_obj_t _jump(mp_obj_t self, mp_obj_t a0) {
604
604
}
605
605
STATIC MP_DEFINE_CONST_FUN_OBJ_2 (jump_obj , _jump );
606
606
607
- //| def LineWidth(self, width: int) -> None:
608
- //| """Set the width of rasterized lines
609
- //|
610
- //| :param int width: line width in :math:`1/16` pixel. Range 0-4095. The initial value is 16
611
- //|
612
- //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
613
- //| ...
614
- //|
615
-
616
- STATIC mp_obj_t _linewidth (mp_obj_t self , mp_obj_t a0 ) {
617
- uint32_t width = mp_obj_get_int_truncated (a0 );
618
- common_hal__eve_LineWidth (EVEHAL (self ), width );
619
- return mp_const_none ;
620
- }
621
- STATIC MP_DEFINE_CONST_FUN_OBJ_2 (linewidth_obj , _linewidth );
622
-
623
607
//| def Macro(self, m: int) -> None:
624
608
//| """Execute a single command from a macro register
625
609
//|
@@ -662,22 +646,6 @@ STATIC mp_obj_t _palettesource(mp_obj_t self, mp_obj_t a0) {
662
646
}
663
647
STATIC MP_DEFINE_CONST_FUN_OBJ_2 (palettesource_obj , _palettesource );
664
648
665
- //| def PointSize(self, size: int) -> None:
666
- //| """Set the radius of rasterized points
667
- //|
668
- //| :param int size: point radius in :math:`1/16` pixel. Range 0-8191. The initial value is 16
669
- //|
670
- //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
671
- //| ...
672
- //|
673
-
674
- STATIC mp_obj_t _pointsize (mp_obj_t self , mp_obj_t a0 ) {
675
- uint32_t size = mp_obj_get_int_truncated (a0 );
676
- common_hal__eve_PointSize (EVEHAL (self ), size );
677
- return mp_const_none ;
678
- }
679
- STATIC MP_DEFINE_CONST_FUN_OBJ_2 (pointsize_obj , _pointsize );
680
-
681
649
//| def RestoreContext(self) -> None:
682
650
//| """Restore the current graphics context from the context stack"""
683
651
//| ...
@@ -836,48 +804,6 @@ STATIC mp_obj_t _tag(mp_obj_t self, mp_obj_t a0) {
836
804
}
837
805
STATIC MP_DEFINE_CONST_FUN_OBJ_2 (tag_obj , _tag );
838
806
839
- //| def VertexTranslateX(self, x: int) -> None:
840
- //| """Set the vertex transformation's x translation component
841
- //|
842
- //| :param int x: signed x-coordinate in :math:`1/16` pixel. Range 0-131071. The initial value is 0
843
- //|
844
- //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
845
- //| ...
846
- //|
847
-
848
- STATIC mp_obj_t _vertextranslatex (mp_obj_t self , mp_obj_t a0 ) {
849
- uint32_t x = mp_obj_get_int_truncated (a0 );
850
- common_hal__eve_VertexTranslateX (EVEHAL (self ), x );
851
- return mp_const_none ;
852
- }
853
- STATIC MP_DEFINE_CONST_FUN_OBJ_2 (vertextranslatex_obj , _vertextranslatex );
854
-
855
- //| def VertexTranslateY(self, y: int) -> None:
856
- //| """Set the vertex transformation's y translation component
857
- //|
858
- //| :param int y: signed y-coordinate in :math:`1/16` pixel. Range 0-131071. The initial value is 0
859
- //|
860
- //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
861
- //| ...
862
- //|
863
-
864
-
865
- STATIC mp_obj_t _vertextranslatey (mp_obj_t self , mp_obj_t a0 ) {
866
- uint32_t y = mp_obj_get_int_truncated (a0 );
867
- common_hal__eve_VertexTranslateY (EVEHAL (self ), y );
868
- return mp_const_none ;
869
- }
870
- STATIC MP_DEFINE_CONST_FUN_OBJ_2 (vertextranslatey_obj , _vertextranslatey );
871
-
872
- //| def VertexFormat(self, frac: int) -> None:
873
- //| """Set the precision of vertex2f coordinates
874
- //|
875
- //| :param int frac: Number of fractional bits in X,Y coordinates, 0-4. Range 0-7. The initial value is 4
876
- //|
877
- //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
878
- //| ...
879
- //|
880
-
881
807
STATIC mp_obj_t _vertexformat (mp_obj_t self , mp_obj_t a0 ) {
882
808
uint32_t frac = mp_obj_get_int_truncated (a0 );
883
809
common_hal__eve_VertexFormat (EVEHAL (self ), frac );
@@ -975,6 +901,82 @@ STATIC mp_obj_t _vertex2f(mp_obj_t self, mp_obj_t a0, mp_obj_t a1) {
975
901
}
976
902
STATIC MP_DEFINE_CONST_FUN_OBJ_3 (vertex2f_obj , _vertex2f );
977
903
904
+ //| def LineWidth(self, width: float) -> None:
905
+ //| """Set the width of rasterized lines
906
+ //|
907
+ //| :param float width: line width in pixels. Range 0-511. The initial value is 1
908
+ //|
909
+ //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
910
+ //| ...
911
+ //|
912
+
913
+ STATIC mp_obj_t _linewidth (mp_obj_t self , mp_obj_t a0 ) {
914
+ mp_float_t width = mp_obj_get_float (a0 );
915
+ common_hal__eve_LineWidth (EVEHAL (self ), width );
916
+ return mp_const_none ;
917
+ }
918
+ STATIC MP_DEFINE_CONST_FUN_OBJ_2 (linewidth_obj , _linewidth );
919
+
920
+ //| def PointSize(self, size: float) -> None:
921
+ //| """Set the diameter of rasterized points
922
+ //|
923
+ //| :param float size: point diameter in pixels. Range 0-1023. The initial value is 1
924
+ //|
925
+ //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
926
+ //| ...
927
+ //|
928
+
929
+ STATIC mp_obj_t _pointsize (mp_obj_t self , mp_obj_t a0 ) {
930
+ mp_float_t size = mp_obj_get_float (a0 );
931
+ common_hal__eve_PointSize (EVEHAL (self ), size );
932
+ return mp_const_none ;
933
+ }
934
+ STATIC MP_DEFINE_CONST_FUN_OBJ_2 (pointsize_obj , _pointsize );
935
+
936
+ //| def VertexTranslateX(self, x: float) -> None:
937
+ //| """Set the vertex transformation's x translation component
938
+ //|
939
+ //| :param float x: signed x-coordinate in pixels. Range ±4095. The initial value is 0
940
+ //|
941
+ //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
942
+ //| ...
943
+ //|
944
+
945
+ STATIC mp_obj_t _vertextranslatex (mp_obj_t self , mp_obj_t a0 ) {
946
+ mp_float_t x = mp_obj_get_float (a0 );
947
+ common_hal__eve_VertexTranslateX (EVEHAL (self ), x );
948
+ return mp_const_none ;
949
+ }
950
+ STATIC MP_DEFINE_CONST_FUN_OBJ_2 (vertextranslatex_obj , _vertextranslatex );
951
+
952
+ //| def VertexTranslateY(self, y: float) -> None:
953
+ //| """Set the vertex transformation's y translation component
954
+ //|
955
+ //| :param float y: signed y-coordinate in pixels. Range ±4095. The initial value is 0
956
+ //|
957
+ //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
958
+ //| ...
959
+ //|
960
+
961
+
962
+ STATIC mp_obj_t _vertextranslatey (mp_obj_t self , mp_obj_t a0 ) {
963
+ mp_float_t y = mp_obj_get_float (a0 );
964
+ common_hal__eve_VertexTranslateY (EVEHAL (self ), y );
965
+ return mp_const_none ;
966
+ }
967
+ STATIC MP_DEFINE_CONST_FUN_OBJ_2 (vertextranslatey_obj , _vertextranslatey );
968
+
969
+ //| def VertexFormat(self, frac: int) -> None:
970
+ //| """Set the precision of vertex2f coordinates
971
+ //|
972
+ //| :param int frac: Number of fractional bits in X,Y coordinates, 0-4. Range 0-7. The initial value is 4
973
+ //|
974
+ //| This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`."""
975
+ //| ...
976
+ //|
977
+
978
+ //}
979
+
978
980
// Append an object x to the FIFO
979
981
#define ADD_X (self , x ) \
980
982
common_hal__eve_add(EVEHAL(self), sizeof(x), &(x));
0 commit comments